A new user interface for you! Read more...

File smartmontools-scsi-suppress-no-temperature.patch of Package smartmontools

Index: smartmontools-6.5/ChangeLog
===================================================================
--- smartmontools-6.5.orig/ChangeLog
+++ smartmontools-6.5/ChangeLog
@@ -1,5 +1,10 @@
 $Id: ChangeLog 4318 2016-05-07 11:18:20Z chrfranke $
 
+2017-03-27  Christian Franke  <franke@computer.org>
+
+	smartd.cpp: Always suppress "failed to read Temperature" message
+	if SCSI device does not support temperature (ticket #817).
+
 2016-05-07  Christian Franke  <franke@computer.org>
 
 	smartmontools 6.5
Index: smartmontools-6.5/smartd.cpp
===================================================================
--- smartmontools-6.5.orig/smartd.cpp
+++ smartmontools-6.5/smartd.cpp
@@ -3448,7 +3448,7 @@ static int SCSICheckDevice(const dev_con
         PrintOut(LOG_INFO,"Device: %s, SMART health: passed\n", name);  
 
     // check temperature limits
-    if (cfg.tempdiff || cfg.tempinfo || cfg.tempcrit || !cfg.attrlog_file.empty())
+    if (cfg.tempdiff || cfg.tempinfo || cfg.tempcrit)
       CheckTemperature(cfg, state, currenttemp, triptemp);
 
     // check if number of selftest errors has increased (note: may also DECREASE)
@@ -3483,6 +3483,9 @@ static int SCSICheckDevice(const dev_con
           scsiDecodeNonMediumErrPage(tBuf, &state.scsi_nonmedium_error.nme);
           state.scsi_nonmedium_error.found=1;
       }
+      // store temperature if not done by CheckTemperature() above
+      if (!(cfg.tempdiff || cfg.tempinfo || cfg.tempcrit))
+        state.temperature = currenttemp;
     }
     CloseDevice(scsidev, name);
     return 0;