boot_mesg "Remount root readonly..."
mount -f -o remount,ro / > /dev/null 2>&1
evaluate_retval
+
boot_mesg "Prepare for halt..."
sleep 2
+
+ #Disable all leds at shutdown
+ for led in $(ls /sys/class/leds); do
+ echo "none" > /sys/class/leds/$led/trigger
+ echo "0" > /sys/class/leds/$led/brightness
+ done
+
halt -d -f -i -p
;;
*)
boot_mesg "Unmounting all other currently mounted file systems..."
umount -a -d -r &>/dev/null
evaluate_retval
- ;;
+ # mount /sys again for led control at halt
+ mount /sys 2>&1 >/dev/null
+ ;;
*)
echo "Usage: ${0} {start|stop}"
exit 1