I tryed to setup an cron.daily for an automated reboot of my server. I want it to reboot every day at 05:00 AM local time. Does anyone know whats the proper script for this? Or should I do it only once a week?
Yes I know that part. But i'm using mandriva an have to create an file within the cron.daily folder. But what must be in the file. So the cron is already running daily, but now I want to specifiy the time or am I incorrect here?
I setup root crons as followed: 1) make a file in /root named cron.txt 2) add stuff there Code: 0 5 * * * reboot 3) save the file 4) add it to as cron: Code: crontab cron.txt 5) check whether it's added Code: crontab -l
You could create a file /etc/cron.daily/reboot which looks like this: Code: #/bin/bash PATH=/sbin:/usr/sbin:/bin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/X11R6/bin shutdown -r now exit 0 Don't forget to make it executable: Code: chmod 755 /etc/cron.daily/reboot