gpart, glabel and newfs --> what am I doing wrong

Warren Block wblock at wonkity.com
Sun Jan 13 15:45:34 UTC 2013


On Sun, 13 Jan 2013, Warren Block wrote:

> On Sun, 13 Jan 2013, kpneal at pobox.com wrote:
>
>> On Sun, Jan 13, 2013 at 08:09:00AM +0700, Erich Dollansky wrote:
>>> For what is glabel then still good?
>> 
>> It is still useful for partition schemes that don't have labels (eg, MBR)
>> AND the filesystem used doesn't support labels itself AND the end of the
>> partition does not get touched by the filesystem.
>
> But it doesn't matter what the filesystem does.  Access to the last block is 
> not allowed by the label device.  The filesystem does not even see it.  See 
> my reply in -fs:
> http://lists.freebsd.org/pipermail/freebsd-fs/2013-January/016113.html

Sorry, forgot to mention that one possible use for glabel is to label a 
swap partition on an MBR drive.

   # glabel label myswap /dev/ada0s1b

And then in /etc/fstab:

   /dev/label/myswap	none	swap	sw	0	0

One block is used for metadata at the end of ada0s1b, but it's safe from 
overwriting because /dev/label/myswap does not include that block.


More information about the freebsd-questions mailing list