ses-led-control

Turn the Identify (locate) and Fault LEDs of disk slots on and off, on any Linux box with an SES enclosure - built with TrueNAS SCALE in mind.

It walks every SES enclosure on the host, maps each disk to its physical slot by SAS address, and shows the slot status together with the IDENT and FAULT LED state - including empty slots. Pick a slot to toggle its locate LED, or drive it from a one-shot command.

root@nas: ~ - ses-led-control (interactive demo)

    
>

Browser simulation - no hardware is touched. Try 0, f1, x, r, or click an ON/off cell.

What it does

It never writes to disks and does nothing destructive beyond changing an LED. LED control depends entirely on the backplane's SES support - if the hardware can't do it, neither can this.

IDENT vs. FAULT

IDENT (locate)

The LED you switch on to physically find a drive - "which bay is sdf?". Usually blue or white, steady or blinking.

FAULT

Marks a slot as failed. Sometimes driven automatically (e.g. a ZFS failure); you can also set it by hand to flag a disk for replacement. Typically red or amber.

Requirements

Run

One self-contained script - no install, no clone. Download just the script into any folder and run it with bash. TrueNAS SCALE ships all dependencies out of the box (there is no apt-get there, and /usr is read-only) - just download and run. On plain Debian/Ubuntu, install them first: sudo apt-get install -y sg3-utils util-linux lsscsi.

curl -fsSLO https://raw.githubusercontent.com/nmuellerdo/ses-led-control/main/bin/ses-led-control

sudo bash ses-led-control
bash ses-led-control list
sudo bash ses-led-control ident on sg3:7
bash ses-led-control --dry-run fault on /dev/sdf

Download the script, run it: interactive menu, table only, switch one LED, or preview with --dry-run.

Targets

Every switching command takes a target, which can be a block device (/dev/sdf or sdf), a disk serial number, or an enclosure slot (sgN:slot, e.g. sg3:7).