Identifying Physical Disks

TAC

Contributor
Joined
Feb 16, 2014
Messages
152
What is the best way to label and keep track of physical disk drives in a FreeNAS server. Specifically when things go wrong, what physical disk(s) need to be dealt with?

I currently have my drives labeled with the FreeNAS drive name (da0, da1, etc.) and serial numbers, but am finding this still causes some confusion.
As shown below, the drive being replaced doesn't show a name, just the gptid (no name and no serial number). The 'glabel status' command doesn't show either of these gptids.

Also it appears the drive name (da0, da1, etc.) isn't permanently tied to the physical drive serial number so my drive labeling scheme needs some work.

1567865838130.png


And from Storage / Disk GUI it doesn't list the drives that are offline.
1567865983242.png
 
Joined
Oct 18, 2018
Messages
969
I've used gpart list to help identify drives. If you label your chassis with the serial numbers of the drives and then label the drives with the /dev/gptid/<hash> it may help connect the dots.
 

TAC

Contributor
Joined
Feb 16, 2014
Messages
152
I've used gpart list to help identify drives. If you label your chassis with the serial numbers of the drives and then label the drives with the /dev/gptid/<hash> it may help connect the dots.
@PhiloEpisteme thanks for the input. So it looks like the drive s/n is tied to the gptid and you better not count on the drive name (dax).

In looking at the first drive from the gparts list it appear ada0p1 is some type of partition used by FreeNAS while ada0p2 is the usable storage name/section. Also the efimedia in ada0p2 is the pgtid reported in glabel status

root@freenas:~ # gpart list
Geom name: ada0
modified: false
state: OK
fwheads: 16
fwsectors: 63
last: 7814037127
first: 40
entries: 152
scheme: GPT
Providers:
1. Name: ada0p1
Mediasize: 2147483648 (2.0G)
Sectorsize: 512
Stripesize: 4096
Stripeoffset: 0
Mode: r0w0e0
efimedia: HD(1,GPT,98a289df-aef0-11e9-9e92-00259046814d,0x80,0x400000)
rawuuid: 98a289df-aef0-11e9-9e92-00259046814d
rawtype: 516e7cb5-6ecf-11d6-8ff8-00022d09712b
label: (null)
length: 2147483648
offset: 65536
type: freebsd-swap
index: 1
end: 4194431
start: 128
2. Name: ada0p2
Mediasize: 3998639460352 (3.6T)
Sectorsize: 512
Stripesize: 4096
Stripeoffset: 0
Mode: r1w1e2
efimedia: HD(2,GPT,98bab322-aef0-11e9-9e92-00259046814d,0x400080,0x1d180be08)
rawuuid: 98bab322-aef0-11e9-9e92-00259046814d
rawtype: 516e7cba-6ecf-11d6-8ff8-00022d09712b
label: (null)
length: 3998639460352
offset: 2147549184
type: freebsd-zfs
index: 2
end: 7814037127
start: 4194432
Consumers:
1. Name: ada0
Mediasize: 4000787030016 (3.6T)
Sectorsize: 512
Stripesize: 4096
Stripeoffset: 0
Mode: r1w1e3
 
Top