Agree. Turning on and off can be a challenge especially to make it fully automated.
I have found that using a relay and a timer can be effective but usually leads to problems down the road as most machines do not like this.
I have found a new way using Processing to d that actually shutdown and have a thread on that here.