Schedule Computer Wake-Up with DD-WRT - A How-To Guide

Automating Computer Startup with DD-WRT and Wake-on-LAN
For users who don't consistently leave their home computers powered on, Wake-on-LAN provides a method for remote activation. While manual operation can be cumbersome, the DD-WRT firmware allows for the scheduling of automatic computer startup on a daily basis.
The Benefits of Scheduled Startup
Practicing energy conservation is beneficial, and there's no need to maintain powered-on computers when they aren't in use. This is particularly relevant for home theater PCs, which are primarily utilized during viewing sessions.
Manually powering on these systems and waiting for the boot process or waking them from sleep can be inconvenient. Although Wake-on-LAN offers remote power-on functionality, it still necessitates user interaction.
However, by leveraging DD-WRT, a schedule can be established to automatically activate your machine(s), ensuring they are ready when needed.
Prerequisites
This guide assumes that your computer is already properly configured to support Wake-on-LAN within both the BIOS and the operating system.
How DD-WRT Simplifies the Process
DD-WRT offers a built-in scheduling feature that can be utilized to send a Wake-on-LAN magic packet at a specified time. This eliminates the need for manual intervention or remote commands.
The process involves configuring a cron job within the DD-WRT interface, specifying the target computer's MAC address and the desired startup time. This allows for a truly hands-free experience.
By automating this process, you can enjoy the convenience of an instantly available computer without sacrificing energy efficiency or incurring the hassle of manual startup procedures.
Configuring Wake-on-LAN (WOL)
To begin, access your router’s DD-WRT interface through your web browser and navigate to the Administration > WOL section.

Within this area, Wake-on-LAN requests can be dispatched to connected computers by simply enabling the “Enable WOL?” option adjacent to each computer listed in the Available Hosts section.

Should a computer not appear in the list, despite being connected to the network, its details can be manually added in the WOL Addresses section located at the bottom of the page. Activating the “Wake Up” button will then initiate a wake signal to that specific machine.
If you wish to schedule a computer to power on at a designated time each day, ensure it is not already running. Proceed to the Automatic Wake-On-LAN section on the WOL page.

Enable the “WOL daemon” by selecting the “Enable” button.

Specify the wake-up interval for your computer. A value of 86400 seconds corresponds to a daily check. Enter the Broadcast IP address for your network under “Host Name.” For networks utilizing the 192.168.1.X scheme, this will typically be 192.168.1.255.
If your computer employs a “SecureOn” password for Wake-on-LAN functionality, input it into the designated field. Finally, provide the MAC address of the target machine. Multiple computers can be configured by entering each MAC address on a separate line.
After entering all necessary information, click “Save” and then “Apply Settings” to finalize the configuration.
Advanced Configuration – Utilizing Cron
For granular control over your computer's wake-up schedule, DD-WRT provides the functionality to establish cron jobs. Navigate to Administration > Management, and locate the Cron section by scrolling down the page.
Within this section, a new line should be added adhering to the following format:
mm hh dd MM wd root /usr/sbin/wol -p -i
Understanding the Cron Job Format
The provided example utilizes the following parameters:
15 17 * * 1-5 root /usr/sbin/wol -p 7 -i 192.168.1.255 00:30:67:2f:4c:6c
This configuration instructs the system to initiate a Wake-on-LAN (WOL) request at 5:15 PM (17 hours and 15 minutes) every weekday, specifically Monday through Friday. The request is transmitted via port 7 to the broadcast IP address 192.168.1.255, targeting the computer with the MAC address 00:30:67:2f:4c:6c.
Further details regarding the customization of cron syntax can be found in our article, Build a Download Scheduler with Little Programming Skill. Refer to the “Linux Cron” section for comprehensive guidance on tailoring the initial syntax to accommodate specific dates, times, and days of the week.
Multiple cron jobs can be implemented by adding each schedule as a separate line, allowing for the configuration of different wake-up times for various machines.
This method functions seamlessly for computers connected to the router via Ethernet. If Static DHCP is employed to assign IP addresses based on MAC addresses, it's also possible to wake computers connected wirelessly while they are in sleep mode (but not powered off).
Important considerations:
- Ensure the MAC address used corresponds to the wireless network card, not the Ethernet card.
- WOL packets are transmitted internally within the network, meaning remote access configuration is not a prerequisite for this functionality.