SOLVED how to find physical hard disk

qq8554650

Dabbler
Joined
Feb 7, 2022
Messages
23
translation from google
As shown in the picture.
If it is reported that sda S4D0GVF2 is broken, how to know which physical hard disk it corresponds to
(In addition to shutting down to see the number)
dell r720xd ,h310 it mode
1671074039282.png
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
As shown in the picture.
If it is reported that sda S4D0GVF2 is broken, how to know which physical hard disk it corresponds to

If you have drive activity LED's, you can generate artificial activity, either on the specified disk (if it isn't totally dead) or on all other disks.

Hard drives are generally marked on the top label with their serial number. Because of how most NAS units are built, it is a good idea to use a labelmaker to make a copy of the serial number on the front of the drive or drive tray for each disk. This allows you to visually identify the drive by serial number easily.

Drive error lights are dependent on the presence of sideband signaling, SGPIO/I2C/SES2, which is an esoteric area of discussion. When properly configured, these can be used to identify drive location with the sas2ircu or sas3ircu LOCATE subcommand.

Otherwise you're left to having to trace out cables.
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,703
If you have drive activity LED's, you can generate artificial activity,
Just to elaborate that poor-man's solution:

dd if=/dev/sda of=/dev/null bs=1M count=5000 CTRL + C to stop it when you're done.
 

shadofall

Contributor
Joined
Jun 2, 2020
Messages
100
This may work, i know it works on my SC846 chassis with my HBA card
sas2ircu for a sas2 hba sas3ircu for a sas3

sas2ircu list
identify hba number (probably 0)
sas2ircu 0 display
find drive in list note enclosure and slot number. if its enclosure 2 slot 21
sas2ircu 0 locate 2:21 ON
and that should flash the "issue light"

sas2ircu 0 locate 2:21 OFF
to turn it back off
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
Maybe we could implement this into Scale as feature?

Doesn't work reliably, it is dependent on various factors being set up correctly in the chassis (SGPIO, I2C, sideband, SES, etc). People have asked for it for years. Developers have said that they don't want to provide access to a feature like this that is rarely used but when it is used it is "life or death" because it could lead to people disconnecting an incorrect drive. TrueNAS Enterprise has tested verified support for this in the commercial product, of course.
 

sretalla

Powered by Neutrality
Moderator
Joined
Jan 1, 2016
Messages
9,703
I guess there's no reason why iX couldn't provide a GUI option to launch the dd method, but that too would not work in 100% of cases and doesn't help where no activity LED exists (or works).
 
Joined
Jul 3, 2015
Messages
926
Its a bit old school but you could just offline it and then its the one that doesn't blink anymore :wink:
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
As you can see, there are ways to identify a hard drive other than reading the serial number off the drive label, however normally those other methods may or maynot work for a given hardware setup. If I had a lot of hard drives to go through and the LED thing didn't work (I don't have an Activity LED for each drive, but that would be nice), I'd mark the drives so you can read the serial number without removing them drive.

One other preemptive option is to mark the location in the GUI in the drive notes/comments. For example you could say "Slot 5" to indicate the fifth drive spot. I use to do this when I had six HDD's but now that I have only four drives, I can read the serial numbers on the label without removing the drives.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
Sorry, I was guessing from my work office, I wasn't home. In the GUI it's called "Description" and can be edited to whatever you want.
 

Zedicus

Explorer
Joined
Aug 1, 2014
Messages
51
8 years later and this is still the best way to locate a drive when you do not have a spreadsheet with drive locations. (and a lot of white label drives do not have the serial on the label, especially SSDs)

sas2ircu
AND OR
diskinfo -ctv 'device'

i had to look up my own old post for the diskinfo command to trip a dead drives activity light.

commands with examples
 
Top