Don't remember if I already wrote about this. But ran into it tonibhg again. Logwatch as distributed with CentOS expects yum log files in different format. As result, logwatch will not report anything. The patch is really simple (and attached). Hopefully it'll be part of 4.3 (if not sooner). The upstream is not likely to patch it, since they don't distribute yum at all. Maybe upstream's upstream, but than we'd have to wait for upstream to have reason to uply upstream's upstream change ;-) I guess it's kind of bordercase. But since it applies to something where upstream and CentOS are different anyhow, maybe it is OK to introduce this change. -------------- next part -------------- A non-text attachment was scrubbed... Name: logwatch-yum.patch Type: text/x-patch Size: 1502 bytes Desc: not available URL: <http://lists.centos.org/pipermail/centos/attachments/20051224/746bba55/attachment-0001.bin>
Your email got here just a little while after I finished finding the same thing (after several hours of looking) and coming up with a similar solution! Thanks for confirming my understanding of the problem! I had been wondering why I wasn't getting any updates when I keep seeing announcements of updates. I wounder how many other things in logwatch are broken that we aren't seeing? I just installed CentOS a few weeks ago and am still learning about this distros' methods and such, but I vote for sending out a patch or fixed package for it. There is no sense publishing known broken code when it isn't likely that the upstream isn't going to do anything about it. On Saturday 24 December 2005 11:00 pm, Aleksandar Milivojevic wrote:> Don't remember if I already wrote about this. But ran into it tonibhg > again. Logwatch as distributed with CentOS expects yum log files in > different format. As result, logwatch will not report anything. > > The patch is really simple (and attached). Hopefully it'll be part of > 4.3 (if not sooner). The upstream is not likely to patch it, since they > don't distribute yum at all. Maybe upstream's upstream, but than we'd > have to wait for upstream to have reason to uply upstream's upstream > change ;-) > > I guess it's kind of bordercase. But since it applies to something > where upstream and CentOS are different anyhow, maybe it is OK to > introduce this change.
On Sat, 2005-12-24 at 22:00 -0600, Aleksandar Milivojevic wrote:> Don't remember if I already wrote about this. But ran into it tonibhg > again. Logwatch as distributed with CentOS expects yum log files in > different format. As result, logwatch will not report anything. > > The patch is really simple (and attached) ... > <snip>My system, 4.2 i386, fully current AFAIK, does not have scripts/shared/applyyumdate but does have applyusdate. Do I need to worry about this? If so, is there any conversion process needed to get the applyyumdate installed, convert existing logs or such? TIA Bill -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part URL: <http://lists.centos.org/pipermail/centos/attachments/20051225/43938d34/attachment-0001.sig>
scripts/shared/applyyumdate is a new file. The patch is to create it and point to in in the other files. On Sunday 25 December 2005 09:56 am, William L. Maltby wrote:> On Sat, 2005-12-24 at 22:00 -0600, Aleksandar Milivojevic wrote: > > Don't remember if I already wrote about this. But ran into it tonibhg > > again. Logwatch as distributed with CentOS expects yum log files in > > different format. As result, logwatch will not report anything. > > > > The patch is really simple (and attached) ... > > <snip> > > My system, 4.2 i386, fully current AFAIK, does not have > > scripts/shared/applyyumdate > > but does have applyusdate. > > Do I need to worry about this? If so, is there any conversion process > needed to get the applyyumdate installed, convert existing logs or such? > > TIA > > Bill
William L. Maltby wrote:> My system, 4.2 i386, fully current AFAIK, does not have > > scripts/shared/applyyumdate > > but does have applyusdate.The applyyumdate is new file (intriduced by patch). It does not exist in current logwatch. The yum.log logfile has same date format as standard syslog logfiles. However there's some differences after the date (hostname, process name, and PID are missing), so existing applystdate can't be used to process yum.log. I had two options. To patch applystddate to be able to parse yum.log (trivial, just add two lines to it), or to create separate file just for yum.log. I opted for later approach. Patching applystddate was bad choice (IMO) since it might change what gets filtered out from standard logfiles (where it is heavilly used). Reports generated by logwatch in CentOS could differ from logwatch in upstream. Creating new date filter script (applyyumdate) that would be used only for processing yum logfiles isn't going to change how standard logfiles are processed. Except for additonal yum section, the remainder of report would be exactly the same. I don't have any Fedora Core system handy (right now). Fedora Core uses yum (same as CentOS). If the same bug exists in Fedora Core, submitting a patch might be good idea (since Fedora Core is upstream's testing ground). Anybody has FC3 or FC4 at hand, and could check how /var/log/yum.log looks like? Is it the same format as in CentOS 4. I guess it should be. AFAIK (and I could be wrong) yum in CentOS should be yum from FC? Does logwatch works correctly in FC3 and FC4 (as far as parsing yum.log)?
Kai Schaetzl wrote:> Robert Tate wrote on Sun, 25 Dec 2005 01:22:18 -0500: > >> I just installed CentOS a few weeks ago and am still learning about this >> distros' methods and such, but I vote for sending out a patch or fixed >> package for it. > > You should be aware that the Logwatch installed with RHEL and CentOS is > *quite* old. Logwatch current is at 7.1. I installed it two weeks ago or > so and it works fine. I don't remember getting any yum information, > though. I didn't notice that until you mentioned it. I'll check about this > when I'm back from vacation. Maybe it was just a period with no updates. > If you do any tuning and want to have that included in the source you > better patch against a current Logwatch and submit that diff. > All in all the logwatch scripts look very much like catering for RH > products, so I'd be a bit puzzled if a newer Logwatch would miss on this. > I installed it on Suse systems as well and had to tune it heavily to get > some decent reporting because it missed the log files and is very > dependant on applications logging to their own log file. >Becuase of this thread I installed the newest logwatch program and can confirm that it =does= show a yum output of what programs have been installed/removed, and it all works very well. Sharon. -- 11:49:22 up 3 days, 2:12, 1 user, load average: 1.48, 1.49, 1.45 A taste of linux http://www.sharons.org.uk/taste/index.html efever http://www.efever.blogspot.com/ Centos 4.2, KDE 3.5.0-1.7, OpenOffice 2.0.1 Registered Linux user 334501