SF.net SVN: logwatch:[221] scripts/services/smartd

[email protected] Tue, 9 Sep 2014 09:52:17 +0000
Newsgroups gmane.comp.log.logwatch.devel
Message-ID <[email protected]>
Revision: 221
          http://sourceforge.net/p/logwatch/code/221
Author:   stefjakobs
Date:     2014-09-09 09:52:16 +0000 (Tue, 09 Sep 2014)
Log Message:
-----------
smartd: handle extended raw temp. values (Thanks: Kristian Duus Ostergaard)

Modified Paths:
--------------
    scripts/services/smartd

Modified: scripts/services/smartd
===================================================================
--- scripts/services/smartd	2014-09-09 09:35:36 UTC (rev 220)
+++ scripts/services/smartd	2014-09-09 09:52:16 UTC (rev 221)
@@ -146,7 +146,7 @@
 #      $ParamChanges{$Device}{$Msg}++;
    } elsif ( ($Device) = ($ThisLine =~ /^Device: ([^,]+), not found in smartd database./ )) {
       $NotInDatabase{$Device}++;
-   } elsif ( my ($Device,$AttribType,$Code,$Name,undef,undef,undef,$RawVal) = ($ThisLine =~ /^Device: ([^,]+), SMART ([A-Za-z]+) Attribute: ([0-9]+) (Temperature_Celsius) changed from ([0-9]+) (\[Raw [0-9]+\]) to ([0-9]+) \[Raw ([0-9]+)\]/)) {
+	 } elsif ( my ($Device,$AttribType,$Code,$Name,undef,undef,undef,$RawVal) = ($ThisLine =~ /^Device: ([^,]+), SMART ([A-Za-z]+) Attribute: ([0-9]+) (Temperature_Celsius) changed from ([0-9]+) (\[Raw [0-9]+(?: \([0-9]+\s[0-9]+\s[0-9]+\s[0-9]+(?:\s[0-9])?\))?\]) to ([0-9]+) \[Raw ([0-9]+)(?: \([0-9]+\s[0-9]+\s[0-9]+\s[0-9]+(?:\s[0-9])?\))?\]/)) {
       push @{$TempChanges{$Device}}, $RawVal;
    # smartd reports temperature changes this way only for SCSI disks
    } elsif ( my ($Device,$AttribType,$Code,$Name,undef,undef,$NewVal) = ($ThisLine =~ /^Device: ([^,]+), SMART ([A-Za-z]+) Attribute: ([0-9]+) ([A-Za-z_]+) changed from ([0-9]+) (\[Raw [0-9]+\] )?to ([0-9]+)/)) {

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


------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce.
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk