SF.net SVN: logwatch:[318] trunk/scripts/services/systemd

[email protected] Wed, 17 Feb 2016 17:29:59 +0000
Newsgroups gmane.comp.log.logwatch.devel
Message-ID <[email protected]>
Revision: 318
          http://sourceforge.net/p/logwatch/code/318
Author:   opoplawski
Date:     2016-02-17 17:29:58 +0000 (Wed, 17 Feb 2016)
Log Message:
-----------
[system] Add a couple more ignored lines; Collect Reexecuting; Fix session collection

Modified Paths:
--------------
    trunk/scripts/services/systemd

Modified: trunk/scripts/services/systemd
===================================================================
--- trunk/scripts/services/systemd	2016-02-16 22:49:22 UTC (rev 317)
+++ trunk/scripts/services/systemd	2016-02-17 17:29:58 UTC (rev 318)
@@ -18,6 +18,7 @@
 my $Detail = $ENV{'LOGWATCH_DETAIL_LEVEL'} || 0;
 my %Activated;
 my %Failed;
+my $Reexecuted = 0;
 my %Reloaded;
 my %Slice;
 my %Started;
@@ -41,8 +42,9 @@
        $ThisLine =~ / failed\.$/ or
        $ThisLine =~ /: (control|main) process exited, code=(exited|killed),? status=/ or
        # Informational
+       $ThisLine =~ /^Closed .* socket\.$/ or
        $ThisLine =~ /^Closed udev / or
-       $ThisLine =~ /^Detected architecture / or
+       $ThisLine =~ /^Detected (architecture|virtualization) / or
        $ThisLine =~ /^Found device / or
        $ThisLine =~ /^Got automount request for \/proc\// or
        $ThisLine =~ /^Inserted module / or
@@ -59,6 +61,8 @@
        $ThisLine =~ /^systemd (\d+) running in system mode/ or
        # Units can depend on files that do not exist
        $ThisLine =~ /^Cannot add dependency job for unit .*, ignoring: Unit .* failed to load: No such file or directory\.$/ or
+       # https://bugs.freedesktop.org/show_bug.cgi?id=90386
+       $ThisLine =~ /^Device .* appeared twice with different sysfs paths .* and / or
        # Inactive units are sometimes reloaded
        $ThisLine =~ /^Unit .* cannot be reloaded because it is inactive\.$/ or
        # https://bugzilla.redhat.com/show_bug.cgi?id=1293941
@@ -77,16 +81,18 @@
    } elsif (my ($target) = ($ThisLine =~ /^Reached target (.*)\.$/)) {
       $Target{$target}++;
       $LastTarget = $target;
+   } elsif (my ($session, $user) = ($ThisLine =~ /^Started Session (\d+) of user (.*)\.$/)) {
+      $UserSession{$user}->{$session}++;
    } elsif (my ($service) = ($ThisLine =~ /^Activated (.*)\.$/)) {
       $Activated{$service}++;
    } elsif (my ($service) = ($ThisLine =~ /^Started (.*)\.$/)) {
       $Started{$service}++;
    } elsif (my ($service) = ($ThisLine =~ /^Reloaded (.*)\.$/)) {
       $Reloaded{$service}++;
+   } elsif ($ThisLine eq "Reexecuting.") {
+      $Reexecuted++;
    } elsif ($ThisLine =~ /^Time has been changed$/) {
       $TimeChanged++;
-   } elsif (my ($session, $user) = ($ThisLine =~ /^Started Session (\d+) of user (.*)\.$/)) {
-      $UserSession{$user}->{$session}++;
    } elsif (my ($slice) = ($ThisLine =~ /^Created slice (.*)\.$/)) {
       $Slice{$slice}++;
    } else {
@@ -102,6 +108,10 @@
    print "\n";
 }
 
+if ($Reexecuted && $Detail) {
+   print "Reexecuted systemd: $Reexecuted Time(s)\n\n";
+}
+
 if (keys %Target && $Detail > 3) {
    print "Reached target $LastTarget: $Target{$LastTarget} Time(s)";
    if ($Detail > 10) {

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.


------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140