Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 12 Jun 2009 18:39:58 -0500 (CDT)
From:      Wes Morgan <morganw@chemikals.org>
To:        Peter Jones <mlists@pmade.com>
Cc:        freebsd-fs@freebsd.org
Subject:   Re: Logical Disk to Physical Drive Mapping
Message-ID:  <alpine.BSF.2.00.0906121800390.60449@ibyngvyr.purzvxnyf.bet>
In-Reply-To: <86ljnxyy01.fsf@pmade.com>
References:  <86ljnxyy01.fsf@pmade.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, 12 Jun 2009, Peter Jones wrote:

> 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.
>
> What is the de facto way of doing this?  I'll be using FreeBSD-CURRENT
> for this, btw.

Use ATA_STATIC_ID for the ATA subsystem to prevent unit numbers from 
changing when devices are added or removed. For SCSI devices, you can wire 
down the naming scheme with something like this in /boot/device.hints:

hint.scbus.0.at="mpt0"
hint.da.0.at="scbus0"
hint.da.0.target="0"
hint.da.1.at="scbus0"
hint.da.1.target="1"
hint.da.2.at="scbus0"
hint.da.2.target="2"
hint.da.3.at="scbus0"
hint.da.3.target="3"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?alpine.BSF.2.00.0906121800390.60449>