Quote:
Originally Posted by MadeInGermany
ITYM
Code:
(/usr/bin/sleep 2 && reboot) &
2 seconds(!) is enough to ensure that the cronjob is finished when the reboot is run.
|
Correct, as the extra & at the end tells cron NOT to wait for it to finish.
But I still would use
- /sbin/shutdown -r +2m &
- always use a path in front of commands
as to save me the extra sleep command.