bug-parted
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: parted check option


From: Andrew Clausen
Subject: Re: parted check option
Date: Thu, 16 Nov 2000 21:09:19 +1100

Thomas Roelz wrote:
> I can imagine this is not trivial and I think this is nothing that can
> be realized "on the fly". To clamp several disk operations that might
> overlap together to build one single atomic transaction requires to
> image the resulting state after each step as input for the next step.
> All this has to be accomplished without actually doing it. But while
> this will be very useful for automatic installations it is not what I
> meant initially.

Yep, I understand this is what you are saying.  However, I'm saying:
I don't see how these are different problems.

> Imagine the following situation:
> With the SuSE installer YaST2 the user has the ability to configure his
> new system entirely in a virtual state. She works through several
> dialogs each of them specifying certain properties of the system to be
> installed. If, at a later point of this "workflow", he comes to the
> conclusion that something he has done earlier was not what he wants now he
> can go back and change it. Nothing has been really altered up to a specific
> point in this dialog sequence. Then there is the point of no return. The
> user is told that all his prearragements are now made reality if she clicks
> OK. If he does, all the actions necessary to achieve the desired system are
> executed.

Sounds good :-)
 
> Now you may understand that for example resizing an existing partition
> in an early state of this workflow should not be done actually. There should
> be only a check if it _could_ be done. Only after the user has confirmed
> his statements at the end of the dialog sequence the resizing should take
> place in reality.

OK, but do resize operations occur in isolation?  For example: won't
you want to say, shrink a partition, then create a new partition in the
free space?  If so, don't you need to verify that both operations
will succeed?

Perhaps you can assume that:
(a) creating partitions in free space will work
(b) you will only permit operations that would work at both the
"beginning of time" and the "end of time".

Are you making these assumptions?

If so, I can see that a check option would be useful in this case.
However, I think it could mess up the code, and I would rather make
the general case work (and this special case doesn't really help
with the general case, anyway).

Hypothetically speaking, if we were to implement it, we'd do
a "check mode" would fit in a similar way to a hypothetical
"expert mode" would work.

Hmmm.  Well, to tell you the truth, the existing front-end
code is a mess.  I'll hack on it (i.e. separate the parsing
more), and see what it looks like after that...

BTW: you've decided not to write your own front end to
libparted?  I would have thought this would be better for an
installer.

Conectiva use libparted in MI (modular installer):

        $ CVSROOT=:pserver:address@hidden:/home/cvs
        $ cvs get mi
        $ cvs get libconectiva
        $ cvs get newt-cnc

Have you looked at this?

Andrew Clausen



reply via email to

[Prev in Thread] Current Thread [Next in Thread]