[CentOS] how to control Hard Drive light from Linux?

Mon Jan 24 00:55:45 UTC 2011
John R Pierce <pierce at hogranch.com>

On 01/23/11 3:24 PM, Jure Pečar wrote:
> There's no real standard in hardware to play with leds. For example, you
> can play witch num/caps/scrol lock leds on your keyboard easily, but
> there's no such standard for cheap generic drive enclosures. Fancier ones
> use saf-te, as others already mentioned.

if this is an external SAS/SATA array, its highly likely it uses SES2, 
the successor to SAF-TE, or SGPIO (the successor to SES2) and again, 
SES2 usually appears as another 'scsi' device on the backplane, it 
should show up if you list all devices on the HBA.  alternately, SES2 is 
accessed via SMbus i2c commands.     SGPIO however, uses a special iPass 
connector and is only supported by specific HBAs that have the ipass 
interface which combines SAS and the SGPIO signals.

I believe there are packages for both SES (sg-ses) and sgpio, and if you 
setup this stuff and properly configure it to match your enclosure, 
dmraid/mdraid should automatically set the LEDs.   the problem is, 
there's a lot to configure.  for instance, if your HBA has in fact this 
sgpio support, there's no standards for how the host talks to that.

having never actually done this (we buy packaged storage from vendors 
who take care of this stuff for us), thats about all I can suggest.