zed: Add zedlet to power off slot when drive is faulted
commitd19304ffeec50ebc02cf4496c14e8945c74fb76a
authorTony Hutter <hutter2@llnl.gov>
Thu, 24 Aug 2023 18:59:03 +0000 (24 11:59 -0700)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Fri, 25 Aug 2023 20:33:40 +0000 (25 13:33 -0700)
tree3393af587bd642859bad19a8bc45b1d714ed0b6d
parent92f095a903f8599e76473cdc019e6da64d0b67c4
zed: Add zedlet to power off slot when drive is faulted

If ZED_POWER_OFF_ENCLOUSRE_SLOT_ON_FAULT is enabled in zed.rc, then
power off the drive's slot in the enclosure if it becomes FAULTED.
This can help silence misbehaving drives.  This assumes your drive
enclosure fully supports slot power control via sysfs.

Reviewed-by: @AllKind
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Tony Hutter <hutter2@llnl.gov>
Closes #15200
cmd/zed/zed.d/statechange-slot_off.sh [new file with mode: 0755]
cmd/zed/zed.d/zed.rc