cron problems
James Gray
james at grayonline.id.au
Mon Mar 6 02:20:16 UTC 2006
On Monday 06 March 2006 10:24, Patrick Siglin wrote:
> cron is still looking for sendmail even though it is gone. What is the best
> way to make sure that an uninstall is a full one?
apt-get --purge remove <package>
This will remove <package> and all its configuration files etc. You can go
further with various "--force" options, but I've left that side of the
argument out as you can do more harm than good with them unless you really
know what you're doing.
Why is cron looking for sendmail? Probably because it hasn't been told NOT
to. "man 5 crontab" states:
"...cron(8) will look at MAILTO if it has any reason to send mail as a result
of running commands in ‘this’ crontab. If MAILTO is defined (and non-empty),
mail is sent to the user so named. If MAILTO is defined but empty
(MAILTO=""), no mail will be sent. Otherwise mail is sent to the owner of
the crontab."
In other words, add MAILTO="" to /etc/crontab under the SHELL=/bin/sh line and
cron will no longer attempt to send mail to anyone :)
However I can't think of a good reason why a sysadmin would want to configure
a system to not even be able to send mail to itself - how do you notify
anyone of a problem? At least if you send mail to user at localhost you get the
mail when you log into the machine again. Most MTA's (exim/postfix/sendmail)
can be configured to only handle local mail and never accept or initiate a
network mail session.
Cheers,
James
--
With clothes the new are best, with friends the old are best.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20060306/f2351746/attachment.sig>
More information about the ubuntu-users
mailing list