[Logwatch] logwatch not sending emails to alternate email address

Mike Tremaine mgt at stellarcore.net
Thu Feb 14 08:41:02 MST 2008

Asrai khn wrote:
> On Wed, Feb 13, 2008 at 11:26 PM, Mike Tremaine <mgt at stellarcore.net 
> <mailto:mgt at stellarcore.net>> wrote:
>     Asrai khn wrote:
>      >
>      >
>     Under Fedora 8 to fix this issue the logwatch.pl script must be
>     modified. This should be reported back up to Fedora. Basically you need
>     to move the ENV kludge forward. Line 63 is about right and it should
>     look like this
>     #Honor ENV MAILTO as default if exists -mgt
>     if ($ENV{'MAILTO'}) {
>         $Config{'mailto'} = $ENV{'MAILTO'};
>     } else {
>         $Config{'mailto'} = "root";
>     }
>     Then remove the other ENV setting at around line 362 just remove the
>     whole conditional.
>     After that it should work right. I'm going to fix what we have in
>     CVS also.
> Hi Mike,
> I  check out the  updated logwatch.pl from  cvs and  still  its only  
> sending emails to 'root' coz of "MAILTO=root" in /etc/crontab and 
> ignoring /etc/logwatch/conf/logwatch.conf where we have using ....
> # Local configuration options go here (defaults are in 
> /usr/share/logwatch/default.conf/logwatch.conf)
> MailTo = root,logwatch-analyser at email-monitor.abc.com 
> <mailto:logwatch-analyser at email-monitor.abc.com>

You should probably not being using the CVS version on Fedora 8 yet. The 
differences between CVS and 7.3.6 are pretty huge. Yes it should work 
but it makes debuging your setup much much harder.

Go back to a stock FC8 and then try making the change I suggested. I 
have Fedora Core 8 and with that change I was able to send to 2 email 
addresses that where in the /etc/logwatch/conf/logwatch.conf file. So 
all I can say is with a stock Fedora Core 8 setup and the change I stock 
into logwatch.pl it does work.


More information about the Logwatch mailing list