cron mystery

Chuck Swiger cswiger at mac.com
Mon Feb 26 16:54:46 UTC 2007


Robin Becker wrote:
[ ... ]
> before
> ##################
> SHELL=/bin/sh
> MAILTO=user
> 
> 13 3 * * *      $HOME/bin/daily
> 19 * * * *      $HOME/bin/hourly
> 
> 
> after
> ##################
> SHELL=/bin/sh
> MAILTO=user
> 
> 13 3 * * *      /home/user/bin/daily
> 41 * * * *      /home/user/bin/hourly
> 
> 
> and at 41 past the hour the hourly job came back.
> 
> Is it the HOME variable or the act of rewriting? User did have home 
> defined in /etc/passwd.

I suspect that $HOME isn't being defined as one might expect-- cron provides a 
very minimal shell environment for scripts it runs.

-- 
-Chuck


More information about the freebsd-questions mailing list