- Login to your server with SSH
- Type
crontab -l
to display list of cron jobs, - Type
crontab -e
to edit your crontab, - Add
0 4 * * * /etc/init.d/mysqld restart
to restart Mysql everyday at 4 AM, - Add
0 5 * * * /etc/init.d/httpd restart
to restart Apache everyday at 5 AM and - Add
0 24 * * * /etc/init.d/httpd restart
to restart Apache everyday at 12 AM - Save your file,
- Recheck with
crontab -l
Thanks for this information I hope it will help.