I have a backup script that gets executed daily via a cron job. It's copying from FTP servers, and attached USB harddisks, databases and etc.
At the end of the script, I want to reboot the Linux machine, so I put in the end of the script:
But typing uptime next day reveals that it didn't reboot. The cron job is executed by the root user, so I shouldn't need to put sudo or su infront of the command, afaik. So instead I tried other variants of the command, like:
shutdown -t 10 -r shutdown -r now /sbin/shutdown -t 10 -r /sbin/shutdown -r now /sbin/reboot
One attempt at a time of course, not all the above 5 lines after each other. The PC just doesn't reboot.
Does anyone have any ideas about this?