Schedule multiple wake up times for Mac

cronsleep-wake

I have systems running Mac OS X 10.5.8 and 10.6.8 that I would like to schedule some cron jobs for with the Cronnix GUI application.

I prefer those computers be asleep until the scheduled jobs start. I know the Energy Saver System Preferences pane lets me schedule daily wake up times for the computer, but my cron jobs run at different times in the day.

Is there a way to set up more than one wake up time per day on these Macs? I prefer a GUI based approach but any ideas you have would be great, thanks!

Best Answer

Sorry, I only know command-line tools to do the job.

You can use pmset for that (like in pmset schedule wake "02/12/2012 12:42:00").

More explanations here and, of course, man pmset.

Setting Multiple "Power On" & Power Off" Events

Currently, it appears that pmset will NOT allow you to set more than one pair of "power on" & "power off" events when using a repeating schedule.

For example...

# pmset repeat shutdown MTWRFSU 02:00:00 wakeorpoweron MTWRFSU 06:45:00

The above command would set a repeating schedule that would shutdown the Mac nightly at 2 AM in the morning and startup daily at 6:45 AM.

But, if you want to set multiple "power on" & "power off" events, you could specify a specific date/time and with a little scripting you could setup a schedule for a month.

# pmset schedule wakeorpoweron "06/07/2007 07:00:00"
# pmset schedule shutdown "06/07/2007 22:00:00"
# pmset schedule wakeorpoweron "06/07/2007 00:00:00"
# pmset schedule shutdown "06/07/2007 01:00:00"