The up2date section of the logwatch mailings (RH9) lists everything that happened as undefined, even though the script looks like it's trying to filter out the frivilous stuff. For those of us who run up2date as a cron job, this results in logwatch messages that are *very* long and pointless. To fix it, you have to make changes to the regex in /etc/log.d/scripts/services/up2date Here's what I did, in the while loop: --------------- while (defined($ThisLine = <STDIN>)) { if ( $Debug >= 5 ) { print STDERR "DEBUG($DebugCounter): $ThisLine"; $DebugCounter++; } if ( ( $ThisLine =~ /updating login info/ ) or ( $ThisLine =~ /Opening rpmdb in \/var\/lib\/rpm\/ with option ./ ) or ( $ThisLine =~ /successfully retrieved authentication token from up2date server/ ) or ( $ThisLine =~ /availablePackageList from network/ ) or ( $ThisLine =~ /logging into up2date server/ ) or ( $ThisLine =~ /A socket error occurred/ ) or ( $ThisLine =~ /new up2date run started/ ) or ( $ThisLine =~ /A protocol error occurred/ ) or ( $ThisLine =~ /Error communicating with server\. The message was:/ ) or ( $ThisLine =~ /deleting \/var\/spool\/up2date\// ) ) { # We don't care about these } elsif ( $ThisLine =~ /installing packages/ ) { $PackageInstalled{$ThisLine}++; } elsif ( $ThisLine =~ /Adding packages/ ) { $PackageAddedToProfile{$ThisLine}++; } elsif ( $ThisLine =~ /Removing packages/ ) { $PackageRemovedFromProfile{$ThisLine}++; } else { # Report any unmatched entries... push @OtherList,$ThisLine; } }
Could you send a unified diff, please? Create a new attachment containing the patch. Thanks...
Created attachment 93492 [details] unified diff of update script (for logwatch) Here is the unified diff of the update script (for logwatch)
Created attachment 93600 [details] up2date script for logwatch Another common log entry snuck through and was marked as 'undefined' in logwatch. This updated udiff catches it.
Many thanks - it's in CVS now, should show up in rawhide soon.