The NSLU2 has a hardware power on-/power off-button.
As any other hardware button, its function can be configured in OpenWrt. In order to use the hardware button of the NSLU2 to shut it down/ switch if off, follow the steps below:
add the following line to the /etc/inittab
The file /etc/inittab (running 8.09.2 without having made manual adoptions) should then look like this:
::sysinit:/etc/init.d/rcS S boot
::shutdown:/etc/init.d/rcS K stop
on the console type
root@nslu2:~# touch /bin/shutdown.sh
and enter the following lines of code
/etc/init.d/rcS K stop
These lines first stop all running services and then shut the NSLU2 down.
Finally, make the file /bin/shutdown.sh executable by
chmod 750 /bin/shutdown.sh
You are done. After a reboot you should be able to use the power off-button.
http://www.artanis.info/blog/?p=98 (in german)
Further information on the NSLU2 can be found here: Linksys NSLU2