# cron is not sending mail for freebsd-update



## ghostcorps (Sep 16, 2011)

Hi all

 I have been slowly getting up to speed with FreeBSDs system of keeping up to date but I am having trouble receiving the output of [CMD=]freebsd-update[/CMD] by mail when I use it in [CMD=]crontab -e[/CMD].

 Currently I have DutchDaemons portupdater.sh in /usr/sbin and the following lines in [CMD=]crontab -e[/CMD].


```
1       3       *       *       *       freebsd-update cron
1       3       *       *       *       portupdater cron
```

 I am forwarding mail intended for root to my external address.

/etc/aliases

```
root: me@mail.com
```

 The way it is I am able to receive mail generated by [CMD=]portupdater cron[/CMD] but not from [CMD=]freebsd-update cron[/CMD].

 Can anyone see what am I missing?


----------



## Dies_Irae (Sep 16, 2011)

This may be a silly question, but did freebsd-update found something new to download?

I don't use freebsd-update, but if i understand correctly from the man page freebsd-update(8):


```
cron	  Sleep a random amount of time between 1 and 3600 seconds,
	  then download updates as if the fetch command was used.  If
	  updates are downloaded, an email will be sent (to root or a
	  different address if specified via the -t option or in the
	  configuration file).	As the name suggests, this command is
	  designed for running from cron(8); the random delay serves
	  to minimize the probability that a large number of machines
	  will simultaneously attempt to fetch updates.
```

it sends an email only if it has downloaded something.


----------



## ghostcorps (Sep 16, 2011)

Dies_Irae said:
			
		

> it sends an email only if it has downloaded something.



That would make sense. 


Thanks!


----------



## Yacki (Sep 16, 2011)

Yes, like he said it is true. 

You can only receive an e-Mail if you have downloaded the update you wanted.

# But note!

- If you update, you should always get informated about the new update, cause sometimes it may crash your system if you have self-compiled your own kernel. It already happened to me, so take care of your lovely linux distributation, FreeBSD


----------

