bug-parted
[Top][All Lists]
Advanced

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

Re: parted pre9


From: Andrew Clausen
Subject: Re: parted pre9
Date: Sat, 11 Nov 2000 18:47:16 +1100

Ethan Benson wrote:
> > Yes, I know!  I can't think of a good workaround.
> >
> > When we merge with partimage, there should be no need for the
> > bootstrap code (I suspect...), so this will go away, eventually...
> 
> what is the bootstrap code for anyway?  why not leave that to grub or
> lilo?

Mainly for partition imaging.  If you want to use Parted for
partition imaging (for Windows machines, for example), it usually
needs the vanilla M$ boot loader on the MBR.

> > Yes.  s/0.812/0.8125/
> 
> hmm, seems like i tried something like that and parted told me off...

Shouldn't tell you off.  Parted knows nothing about decimal places,
etc.  It just gets the sector number.

> /me can't wait till i can just tell it +800K ;-)

;-)
 
> > When won't it work?
> 
> when you need a type 41 partition so your PReP or RS6000 will boot ;-)
> these don't even use a filesystem, you install the boot loader like
> so:
> 
> dd if=/usr/lib/yaboot/yaboot of=/dev/hda2 bs=512
> 
> or on PReP:
> 
> dd if=/boot/vmlinux-2.2.17 of=/dev/hda2 bs=512
> 
> and set 2 boot on won't work since that just turns the boot flag on.
> since the firmware is what were dealing with the type does matter.  (i
> think anyway, RS6000 folks say you need to make it a type 41)
> 
> it also matters if you need to create a OpenBSD slice which is
> technically not a filesystem.  but i suppose you could do that some
> other way, though im not sure how.

Well, we could add a flag for it.  Eg: rs6000boot, etc.
 
> > BTW: it is based on the file system AND the partition flags.
> 
> yes i agree this is nicer, but it doesn't always work, see PReP boot.

Add a PRePboot flag ;-)
 
> > This support can (and will, if ppl scream/care enough to send in
> > patches) be added.  However, I can't see any reason to move away
> > from the FS & flag system.
> 
> i don't either, the problem is it does not work for all situtations,
> there is always some oddball thing someone wants to do that won't fit
> what you prepared for, thats what makes unix so cool, you can do
> almost anything with few limits set by the original developer.

I'm not completely convinced by this argument.  I mean, you could
say the BIOS doesn't set many limits for future programmers, hehe.

Perhaps you mean "Unix is very expressive / useful AND doesn't impose
limitations".  I guess I agree, except I wouldn't say Unix is very
expressive / useful.  (delete the "very")
 
> > > a way to set arbitrary types on mac
> > > partitions would be useful too IMO.
> >
> > Why?
> 
> if i need to create a partition you don't support, like oh Apple_UFS
> ;-)

Well, we should just add Apple_UFS support, then.
 
> my point is you can't possibly think of every possible situation
> someone might find themselves in, so its useful to have a way to
> control things in detailed way.  furthermore its just the unix way ;-)

Linux only lets you mount file systems it knows about!  It will only
work on hardware it knows about, etc.

Attempting to access low-level structures (i.e. partition table
fields such as flags, names, etc.) direcly with Parted would
complicate things a *LOT*.  libparted would have to communicate
what flags, etc. are available, and what types are acceptable
(string or int?)

This is a very un-unix thing to do (complicate things unnecessarily)

I don't have any personal attachment to unix (other than I use
GNU/Linux, because it's free software), and I guess the unix
philosophy is useful for building software.  Note:  Unix philosophy
!= Unix (or GNU/Linux).  I suspect FreeBSD follows the Unix
Philosophy TM more closely.  I really should install it...

(Timshel: waiting for the new hard disk!)

> > > can you change `set x boot on' to set the partition name to
> > > `bootstrap' for mac partition tables?  i think this is better then
> > > leaving it `untitled'.
> >
> > What if the user (or MacOS) gave it a different name?
> 
> MacOS won't because MacOS does not understand Apple_Bootstrap (thats
> the point!) if the user has given it a name other then untitled leave
> it alone i suppose.  even though the name does not show anyway but
> partitioner i think.  (it has nothing to do with the name a filesystem
> has)

I understand all this.  But what you're proposing is quite complicated.
You're saying:
(a) if the name is "untitled" or "", then change it to "bootstrap"
(b) otherwise, leave it

What if you remove the bootstrap flag?  Should it change it
back to "untitled"?  This sounds complicated (and potentially
confusing to the user because it is complicated)  This is Not Unix TM.

> otoh i would be alot happier if i didn't have to type the silly
> `primary' over and over again for absolutly no reason at all on
> non-x86 tables.  (something i didn't try, can you abbreviate it?  just
> p l or e ?)

p l or e works.

> > hehe, except it's broken when you make a mistake.  You have to start
> > all over again.
> 
> i suppose, not much worse then retyping a command line though (or
> pressing the arrow key a bunch.. something else i didn't try is the
> bash style C-a C-e)

Parted uses the same library as bash (GNU readline).  You even get
a command history!  (I can't really think of any use for it, but
it's cute, and trivial to add!)

> > Ah.  I see.  Hmmm.  If we had a proper lexer / parser, it would
> > be quite cute... One Of These Days TM.
> >
> > Have to think about the interface a bit though.  (Feedback WRT
> > which partition you're up to, etc.)  All you Mac people have to
> > Think Different TM with your UIs, don't you!  :p
> 
> hey i prefer unixy interfaces, i actually *like* the fdisk interface
> ;-)  (yes i am a freak i know) the lack of feedback on what partition
> im on does not bother me since i tend to print the table after
> creating a partition anyway (old fdisk habit)

with your batch mode, would it print after each addition?
 
> as for mac people they won't be happy with anything but a pure GUI
> program with probably far too much hand holding then i can personally
> stand.

Hehe.  I should send in some screenshots of the Conectiva Modular
Installer, with the printf/scanf, newt and gtk front ends to libparted.
Anonymous CVS works now, but you'll need to download lots of weird
versions of things!

        CVSROOT=:pserver:address@hidden:/home/cvs

You need:

        cvs get libconectiva
        cvs get mi
        cvs get newt-cnc
        parted-1.2.12
        lots of other stuff (like kudzu{,-devel}, gtk+, etc.)

I guess I could put some static binaries on my website...

> the thing that has just been bugging me about parted is i can create
> 12 partitions in fdisk in probably 30 seconds, but it takes me several
> minutes in parted...  (partly not being as used to it, but also the
> more verbose commands have alot to do with it)

I'm much quicker with Parted, hehe.  I don't have to remember silly
numbers, etc., it works in megabytes which I personally find more
intuitive.

Andrew Clausen



reply via email to

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