Hi all,
I've got a home server with 12 hard drive slots. I've mapped out on paper the location all of the hard drives I've inserted, what their serial numbers are, and some additional details.
Next I would like to label each of the drives with information like
I know I can do this by hand, but I would like to automate it so as to remove human error - at home I fear I may be sloppy with labelling replaced disks, or make a typo. I'm looking to use camcontrol(8) to grab out the serial number, but I'm not sure of a reliable way to figure out where the drive physically is.
If I map out the device name (e.g.
I've previously mapped out the scbus/target/lun numbers, but these appear to have changed over time even though there have been no hardware changes (the original mappings took place under 12.0-RELEASE a few years ago, and I've recently got the server out of storage and put a fresh install of FreeBSD 13.1-RELEASE on it, if that matters).
Is there a reliable way in FreeBSD to map some information to the physical location of a drive in the chassis?
I've got a home server with 12 hard drive slots. I've mapped out on paper the location all of the hard drives I've inserted, what their serial numbers are, and some additional details.
Next I would like to label each of the drives with information like
<location>-<serial>
e.g. a3-WD-WMAWZ1371366
. I know I can do this by hand, but I would like to automate it so as to remove human error - at home I fear I may be sloppy with labelling replaced disks, or make a typo. I'm looking to use camcontrol(8) to grab out the serial number, but I'm not sure of a reliable way to figure out where the drive physically is.
If I map out the device name (e.g.
da0
) would that be enough? I want to say that this can change depending on the order the loader picks up each drive?I've previously mapped out the scbus/target/lun numbers, but these appear to have changed over time even though there have been no hardware changes (the original mappings took place under 12.0-RELEASE a few years ago, and I've recently got the server out of storage and put a fresh install of FreeBSD 13.1-RELEASE on it, if that matters).
Is there a reliable way in FreeBSD to map some information to the physical location of a drive in the chassis?