[parted-devel] Interface to set partition type

Karel Zak kzak at redhat.com
Mon Nov 9 22:11:07 UTC 2009


On Mon, Nov 09, 2009 at 11:17:58AM +0100, Jim Meyering wrote:
> Robert Millan wrote:
> > On Sun, Nov 08, 2009 at 04:42:47PM +0100, Jim Meyering wrote:
> >> Robert Millan wrote:
> >> > On Mon, Oct 19, 2009 at 02:56:08PM +0200, Jim Meyering wrote:
> >> >> In the longer term, we'll probably deprecate
> >> >> it and instead add an interface to set a partition's type independent
> >> >> of mkpart's "type" argument.
> >> >
> >> > I'd like to work on adding that interface.  I propose:
> >> >
> >> >   # GPT
> >> >   $ parted /dev/sda type 1 00000000-0000-0000-0000-000000000000
> >> >
> >> >   # MSDOS
> >> >   $ parted /dev/sda type 1 00
> >> >
> >> > Is that appropiate?
> >>
> >> Thanks for volunteering.
> >>
> >> Good timing.
> ...
> 
> It seems like it'd be useful to be able to extract existing types,
> too, so how about making the string argument optional.
> Then, this would print the type of the first partition:
> 
>     $ parted /dev/sda part-type 1

 This reminds me ...

 ... it would be also nice to have a way how set partition UUID.
 Currently GPT UUID is always generated. Maybe we will use the UUID
 for some userspace operations (DevKits, udev, mount, ...) and then
 people will look for a way how to control this identifier.

 (Yes, I know that UUID should be unique, but sometimes is it very
 useful to create a new disk layout with the same UUIDs.)

     $ parted /dev/sda part-uuid 89ec2a20-ab3a-4105-b5e8-b141666fbd0c

 ?

    Karel

> 
> _______________________________________________
> parted-devel mailing list
> parted-devel at lists.alioth.debian.org
> http://lists.alioth.debian.org/mailman/listinfo/parted-devel
> 

-- 
 Karel Zak  <kzak at redhat.com>



More information about the parted-devel mailing list