http://www.perlmonks.org?node_id=940995


in reply to Re^3: adding wtmp script into logwatch
in thread adding wtmp script into logwatch

Helloooo again Sinistral!! OMG I finally got it to work!!! When I ran logwatch it gave me this error saying something like "logfile not defined" because as you can see I hadn't define a log file to call YET into the script (that's why the script was hanging!) Not very bright u see!! Soooo, anyways what I did was to go to my /etc/logwatch/conf/logfiles directory and added a wtmp.conf file and added this line into it:
my-mnag0:/etc/logwatch/conf/logfiles # ls -lrt total 4 -rwxrwxr-x 1 root sysadm 61 Dec 1 15:11 wtmp.conf my-mnag0:/etc/logwatch/conf/logfiles # more wtmp.conf #Define log file group for wtmp log Logfile = /var/log/wtmp
so then i rerun logwatch again and lo and behold!!! out came the wtmp logs!!!!
Wed Nov 30 14:57:35 2011 Normal my9849 pts/0 191.255 + Wed Nov 30 14:58:11 2011 Normal root pts/1 191.255. + Wed Nov 30 15:04:17 2011 Term pts/0 + Wed Nov 30 15:04:25 2011 Normal my9849 pts/0 191.255. + Wed Nov 30 15:22:33 2011 Term pts/0 + Wed Nov 30 15:23:51 2011 Term pts/1 + Thu Dec 1 06:09:22 2011 Normal my9849 pts/0 191.255. + ---------------------- WTMP logs End -------------------------
OMG Im soo happy!!! This thing has been going on for 2 weeks and I was about to give up until you came along n responded to my distress call!! Thank you soo very much!!! *big hug and kissess