Name/label/id metadata: how do I make it go away

Freddie Cash fjwcash at gmail.com
Mon Sep 21 18:58:44 UTC 2015


On Mon, Sep 21, 2015 at 11:28 AM, Chris Stankevitz <chris at stankevitz.com>
wrote:

> Hi,
>
>
> For those wanting to teach me to fish:
>
> In the context of naming a disk that has no partitions, can you explain to
> me the difference among these terms:
> - gpt label
> - gpt id
> - glabel
> - gpart
> - /dev/diskid/*
> - disk_ident
> - geom
> - bsdlabel
>
> For those wanting to give me a fish:
>
> I have a zfs pool of "entire disks".  "zpool status" shows some disks with
> their daX name (which I prefer) and some with a hideously ugly name such as
> DISK-%20%20%20%20%20-WD-WMC4NOH1ASDF
>
> I can make the hideously ugly names temporarily go away with:
>
> zpool export foo
> glabel stop diskid/DISK-%20%20%20%20%20-WD-WMC4NOH1ASDF
> zpool import foo
>
> However I cannot make them permanently go away:
> zpool export foo
> glabel clear da6
> > Can't clear metadata on da6: Invalid argument.
>
> In a prior life these drives were in a FreeNAS setup which presumably
> added the labels.  I did not erase the labels before I recommissioned the
> drives in my new FreeBSD setup.  I'm happy to use dd to erase the metadata
> but I do not know how the labels were added.  Presumably when I understand
> that I will know which blocks need to be zero-ed out.  I need to
> "surgically" dd to avoid data loss from my zfs disks.  I have backups....
> actually the problem pool is a backup pool.
>
> Thank you,
>
> Chris
> _______________________________________________
> freebsd-fs at freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-fs
> To unsubscribe, send any mail to "freebsd-fs-unsubscribe at freebsd.org"
>

​Add the following to /boot/loader.conf to make the diskid/* labels
disappear forever:

​kern.geom.label.gptid.enable="0" # Disable the auto-generated GPT UUIDs
for disks

kern.geom.label.ufsid.enable="0" # Disable the auto-generated UFS UUIDs for
filesystems

-- 
Freddie Cash
fjwcash at gmail.com


More information about the freebsd-fs mailing list