Linode default CentOS 6.5 64bit deployment does not include Crontab or Cron Job. Here is a reference for the people like me.
Install the package and dependencies
#yum install vixie-cron
Enable the package on boot and start
# /sbin/chkconfig crond on
# /etc/init.d/crond start
crontab command option:
crontab: usage error: unrecognized option
usage: crontab [-u user] file
crontab [-u user] [ -e | -l | -r ]
(default operation is replace, per 1003.2)
-e (edit user’s crontab)
-l (list user’s crontab)
-r (delete user’s crontab)
-i (prompt before deleting user’s crontab)
-s (selinux context)
I have some site on the Dreamhost. To monitor the traffic and performance, I have Awstats on site and runing many cron jobs every day. I have the experience of how to install AwStats on the Ubuntu server.
The cron job is runing well on the Dreamhost server. The problem is I will receive tons of email about the job status.
Actually, I don’t need these emails. If the job is completed successfully, the Awstats report should be updated. I checked the report often. So the fail of job is not my concern.
To disable cron emails, just add one line code as shown below:
First SSH server.
$ crontab -e
add this line to the top of your cron file:
That’s simple. No more cron emails coming.