[PATCH] Teach geom_label to recognise gpt labels and uuids
Marcel Moolenaar
xcllnt at mac.com
Thu Oct 23 16:35:03 UTC 2008
On Oct 23, 2008, at 9:21 AM, Marius Nünnerich wrote:
>> Something to think about: A system can have multiple disks,
>> and therefore multiple GPT tables. Each table has its own
>> UUID (hdr_uuid). This is the UUID of the disk itself in a
>> way. It's probably a good idea to expose that as well:
>> /dev/gpt/${hdr_uuid}/${ent_uuid}
>> /dev/gpt/${hdr_uuid}/${ent_name}
>
> I tried something like this but decided against it, no other g_label
> is like this. If ent_name is not unique on the system only the first
> one is shown, that's consistent with the normal FS labels.
The consistency seems forced, based on a limitation then.
It's quite valuable to have a label for your disk.
>> ese are too long filenames imo. For my taste the ent_uuid is unique
> enough as a filename, but there should probably be a way to show which
> partition has which ent_uuid with `gpart show`.
gpart show has 3 forms:
o standard partition type (gpart show
ns1% gpart show ad5
=> 34 976773101 ad5 GPT (500.1GB)
34 976773101 1 freebsd-zfs (500.1GB)
o raw (scheme-specific) type (gpart show -r)
ns1% gpart show -r ad5
=> 34 976773101 ad5 GPT (500.1GB)
34 976773101 1 516e7cba-6ecf-11d6-8ff8-00022d09712b
(500.1GB)
o partition label (gpart show -l)
ns1% gpart show -l ad5
=> 34 976773101 ad5 GPT (500.1GB)
34 976773101 1 (null) (500.1GB)
There's currently no form for showing a partition ID.
> I know that you try to
> keep the interface consistent and the other partition types don't have
> such a field. Anyway, what do you think about that?
It can be added if deemed useful, but it only really
applies to GPT...
--
Marcel Moolenaar
xcllnt at mac.com
More information about the freebsd-geom
mailing list