Logical Disk to Physical Drive Mapping

Wes Morgan morganw at chemikals.org
Sun Jun 14 12:21:58 UTC 2009


On Sat, 13 Jun 2009, Stanislav Sedov wrote:

> On Fri, 12 Jun 2009 14:53:50 -0600
> Peter Jones <mlists at pmade.com> mentioned:
>
>> Given the situation where you have several identical physical drives,
>> what is the best way to turn logical labels such as da5 into a physical
>> identifier like "the drive in slot 4"?
>>
>> It looks like I could use dmesg, some assumptions, and glabel to label
>> the logical disks.  However, I plan to use ZFS and as far as I can tell
>> glabel doesn't support ZFS.
>>
>
> If you're using ZFS you probably don't need labels at all. AFAIK, ZFS
> stores all of its information in the on-disk metadata, and you always
> access data via ZFS volume labels.

It does, but even in -current I have to export/import a pool if the device 
numbering shifts, and "zpool status" output could make your heart skip a 
beat if you didn't know how to fix it :)

It might be kludgy (a chicken/egg type problem), but couldn't glabel be 
extended to read ZFS labels and create something like /dev/zpools/<uuid>, 
and then zfs look there first for devices to import?


More information about the freebsd-fs mailing list