[SOLVED] Need some help with logwatch.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Fri, October 23, 2009 14:22, James B. Byrne wrote:
>
> I am trying to get a logwatch summary emailed to a central address
> from a cron job.  The tasd was copied verbatim from a system which
> does this already.  Both are shown below.
>
>
> host1 crontab -l as root
>
> 45 7 * * * /usr/sbin/logwatch --service http --service imapd
> --service pop3 --service sshd --service vsftpd --service
> zz-disk_space --service zz-network --service zz-sys --mailto
> support@xxxxxxxxxxxxx
>
> host2 crontab -l as root
>
> 45 7 * * * /usr/sbin/logwatch --service http --service imapd
> --service pop3 --service sshd --service vsftpd --service
> zz-disk_space -- service zz-network --service zz-sys --mailto
> support@xxxxxxxxxxxxx   #Logwatch summary
>
>
> My problem is that only the first gets delivered to
> support@xxxxxxxxxxxxxx  The second gets delivered to
> root@xxxxxxxxxxxxxxxxxxx and not to support. It has been a
> considerable time since I dealt with logwatch on the first machine
> and I cannot remember is there was any special configuration of
> logwatch itself to enable this to happen.  Does anyone know what I
> might be overlooking?

I thought after the pain I went through finding the solution for
this that some here might be amused to learn what the problem turned
out to be. Note this portion of the second, misbehaving, cron entry
example:

> zz-disk_space -- service zz-network --service zz-sys --mailto

There is an errant space between -- and service for the --service
flag to the zz-network argument; and this caused all the difficulty.


-- 
***          E-Mail is NOT a SECURE channel          ***
James B. Byrne                mailto:ByrneJB@xxxxxxxxxxxxx
Harte & Lyne Limited          http://www.harte-lyne.ca
9 Brockley Drive              vox: +1 905 561 1241
Hamilton, Ontario             fax: +1 905 561 0757
Canada  L8E 3C3

_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux