DD-WRT: Shutdown script using Optware the Right Way
Ever want to shutdown your home router running DD-WRT with Optware the Right Way and correctly unmount any USB drives. Well DD-WRT doesn’t have a halt or a shutdown command, only reboot, but you could easily put the router a state that is safe to just pull-the-plug. Just create a shutdown script, say called /opt/local/bin/shutdown and put the following inside:
#!/bin/sh /opt/etc/init.d/optK
Then make the script executable my changing the permissions.
chmod 755 /opt/local/bin/shutdown
Now as long as /opt/local/bin is in your current path, you can just type shutdown to cause Optware to initiate its shutdown sequence. When it finishes, you can simply power down the router without worry about your filesystems on your external disks.
This entry was posted on Saturday, April 17th, 2010 at 12:38 am and is filed under Howtos. You can follow any responses to this entry through the RSS 2.0 feed. You can skip to the end and leave a response. Pinging is currently not allowed.