cron email freebsd-update: not found

This is a very simple question! I put that command in crontab -e:
Code:
@daily freebsd-update cron
and here is the email I received each morning
Code:
freebsd-update: not found
 
I suggest that section 25.2.2 of the handbook be modified to reflect the correct way of using freebsd-update cron with crontab -e.
 
srivo said:
I suggest that section 25.2.2 of the handbook be modified to reflect the correct way of using freebsd-update cron with crontab -e.

Well, now still the same:

Code:
     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.

Thanks to all.
 
SirDice said:
Cron has a very limited $PATH. Use the full path to the binary.

But what is in it:

Code:
SHELL=/bin/sh
PATH=/etc:/bin:/sbin:/usr/bin:/usr/sbin
And freebsd-update are in:

Code:
/usr/sbin/freebsd-update

So, why are mistake here?
Code:
freebsd-update: not found
 
If nobody files a PR it's not going to change all by itself.
 
setevoy said:
Yes, but here is from Handbook:

Code:
An entry in /etc/crontab would be sufficient to accomplish this task:

@daily                                  root    freebsd-update cron

That is different from crontab -e. Note the path settings in /etc/crontab.
 
Back
Top