I have a SCSI enclosure (supermicro BPN-SAS-825TQ) residing on Ubuntu 16.04.
Is there an sg_ses
(or sg_senddiag
or other) command I can send to the enclosure, that will make the Rear LEDs blink, even if there's no disk in the enclosure?
I have a SCSI enclosure (supermicro BPN-SAS-825TQ) residing on Ubuntu 16.04.
Is there an sg_ses
(or sg_senddiag
or other) command I can send to the enclosure, that will make the Rear LEDs blink, even if there's no disk in the enclosure?
After having spent an hour trying to figure out how to get the correct indices for sg_ses
command to work, I ended up using encled
utility from this project https://github.com/amarao/sdled which has much more intuitive interface. It's a python script, so no compilation required, you can just download it and use right away.
Encled - utility to change location / fault LED for enclosure.
"location" and "fault" is just how LEDs are named. They both may actually be represented by a single LED, but locate
would make it blink, while fault
would just turn it on continuously.
Note: the project has both sdled
and encled
utilities — you want the latter.
Examples:
./encled
./encled sdbe locate
./encled all off
That depends on your particular backplane being visible to the host system (it should be visible as SCSCI device under lsscsi -g
). In general, to turn on ID LED in a slot 1 of the /dev/sg4 enclosure you should issue
sg_ses --dsn=1 --set=ident /dev/sg4
and, alike, to turn it off
sg_ses --dsn=1 --clear=ident /dev/sg4