Cronjob disable email

Status
Not open for further replies.

DarkerTimes

Cadet
Joined
Apr 27, 2014
Messages
3
I added a cronjob to auto shutdown with: "shutdown -p now"

Everytime the cronjob shuts down the machine i get an email:
Cron <root@freenas> PATH="/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:/root/bin" shutdown -p now > /dev/null
shutdown: [pid 27330]

The user is root. In the settings "Redirect Stdout:" is enabled. But it doesn't disable email? Maybe if i take another user that has no email to do the shutdowns, it might work?

I only want to get emails when something is wrong! This is pretty annoying, because everyday i get a new email with a shutdown notification :(
 

SweetAndLow

Sweet'NASty
Joined
Nov 6, 2013
Messages
6,421
IMO if a server shuts down something is really wrong and should be fixes immediately. So that is why you are getting those emails. I'm not sure if there is a way to prevent them.
 

DarkerTimes

Cadet
Joined
Apr 27, 2014
Messages
3
Yes thats right, if my server shuts down for some unexpected reason i want to know that.
But if i decide to shut it down i dont need an extra notification.

Didn't find anything related to that. Only the older version with the email everyday issue.
 
Status
Not open for further replies.
Top