Home / VPS & Dedicated / Getting rid of crontab emails

Getting rid of crontab emails

cron
Question: How do I stop crontab from sending me emails after a cron job finishes?

Answer: In Linux the default setting for crontab is to send an email to the owner after a cron job finishes. An easy way to change this is to reroute those emails into nothingness, which in Linux is a directory called /dev/null.

Just append a pipe to it at the end of your command like so:

/usr/bin/command >/dev/null 2>&1

That will do the trick. You can enter it from the command line or through a control panel, if it supports cron jobs.

Photo: Flickr

Check Also

servers

Importance of web hosting to business

The world of business is very ruthless and unfair in some cases. It is a …

Powered by Namesco
© Copyright InternetBlog.Org.Uk 2024, All Rights Reserved