Loading ...
Sorry, an error occurred while loading the content.
 

Re: SMART monitor interface to AutoFan

Expand Messages
  • Frenchy
    I have installed the SMARTmon suite and dove in all the help files to get my feet wet. I new SMART monitoring was a good idea, now I am conviced it is really a
    Message 1 of 20 , Jun 29, 2005
      I have installed the SMARTmon suite and dove in all the help files
      to get my feet wet. I new SMART monitoring was a good idea, now I am
      conviced it is really a must have for unatended NAS! It is nice to
      know ahead of time if your disk's going to take a dump with your
      data.

      As far as interfacing AutoFan with Smartmon, the best way is to call
      AutoFan from a smartmon output script. I may write an interface
      script at some point once I have tuned smartmon in my test
      environment.

      Implementing smartmon is quite *disk specific*. Everyone interested
      will need to first tune smartmon to match their particular box.


      The good news is you can already implement the temperature
      monitoring and automated shutdown using the smartmon output scripts.
      What that means is you can affect your fan speed based on disk SMART
      parameters like temperature and when temps is too high you can
      shutdown just as easily.

      Example3 in the SM distro is rather clear on how you can affect your
      system:

      #! /bin/bash
      # This is a script from the smartmontools examplescripts/ directory.
      # It can be used as an argument to the -M exec Directive in
      # /etc/smartd.conf, in a line like
      # -m <nomailer> -M exec /path/to/this/file

      # Please see man 8 smartd or man 5 smartd.conf for further
      # information.
      #
      # $Id: Example3,v 1.4 2003/08/17 09:15:56 ballen4705 Exp $

      # Warn all users of a problem
      wall 'Problem detected with disk: ' "$SMARTD_DEVICESTRING"
      wall 'Warning message from smartd is: ' "$SMARTD_MESSAGE"
      wall 'Shutting down machine in 30 seconds... '

      # Wait half a minute
      sleep 30

      # Power down the machine
      /sbin/shutdown -hf now
      ----------------------------------------------------------------
      Right now, the best way to interface AutoFand with smartmon is to
      start it (AutoFand start) and stop it (AutoFand stop) from within a
      script that is based on the smartmon output. That script should
      branch to cycle AutoFan within your temperature range or call
      shutdown if temp shoot above your limit. Does that logic make sense
      to you?

      Between you and me, I don't think cycling a tiny fan to cool down a
      *spinning* disk is such a great idea. It will only make you disk
      warmer than possible. My own logic tells me: disk on = fan on.

      Speaking of disk failures and SMART monitoring: manufacturers
      already point out that higher temperature reduce HDD life span (MTBF)

      -Sam.



      --- In LinkStation_General@yahoogroups.com, "Frenchy "
      <glasseron@y...> wrote:
      > Hi Derek,
      >
      > Got the files, thanks.
      > What disk do you have in your box?
      > The standard LS comes with Samsungs 120Gb ... I see from the
      config
      > file there are SMART firmware issues with these disks:
      >
      > -F TYPE Use firmware bug workaround. Type is one of: none, samsung
      >
      > Do you need to use that option?
      > Can you paste a copy of your config file
      > -Sam.
      >
      > --- In LinkStation_General@yahoogroups.com, Derek Taubert
      > <taubert@g...> wrote:
      > >
      > > I do. See post #544.
      > >
      > > etc/init.d/smartd
      > > etc/smartd.conf
      > > usr/sbin/smartctl
      > > usr/sbin/smartd
      > >
      > > Just uploaded to the files section...
      > >
      > > Derek
      > >
      > >
      > > On Wed, Jun 29, 2005 at 06:52:33PM -0000, Frenchy wrote:
      > > > Great deal. Do you have a smartmon package that runs on LS?
      > > > If so I can use it for testing and build an interface for
      > Smartmon.
      > > > Let me know
      > > > -Sam.
      > > >
      > > > --- In LinkStation_General@yahoogroups.com, "chano22000"
      > > > <philippe.deysine@l...> wrote:
      > > > > --- In LinkStation_General@yahoogroups.com, "Frenchy "
      > > > > <glasseron@y...> wrote:
      > > > >
      > > > > > Question to you: Do you have a source for PPC SMARTmon
      > library?
      > > > > > -Sam.
      > > > >
      > > > > Does the smartmontools sources help you ?
      > > > > http://sourceforge.net/project/showfiles.php?group_id=64297
      > > > >
      > > > > Chano22000
      > > >
      > > >
      > > >
      > > >
      > > >
      > > > Yahoo! Groups Links
      > > >
      > > >
      > > >
    • Derek Taubert
      ... root@HD-HLANA09:~# smartctl -P show /dev/hda smartctl version 5.33 [powerpc-unknown-linux-gnu] Copyright (C) 2002-4 Bruce Allen Home page is
      Message 2 of 20 , Jun 30, 2005
        On Thu, Jun 30, 2005 at 12:23:05AM -0000, Frenchy wrote:
        > Hi Derek,
        >
        > Got the files, thanks.
        > What disk do you have in your box?

        root@HD-HLANA09:~# smartctl -P show /dev/hda
        smartctl version 5.33 [powerpc-unknown-linux-gnu] Copyright (C) 2002-4 Bruce Allen
        Home page is http://smartmontools.sourceforge.net/

        Drive found in smartmontools Database. Drive identity strings:
        MODEL: SAMSUNG SV1203N
        FIRMWARE: TQ100-23
        match smartmontools Drive Database entry:
        MODEL REGEXP: ^SAMSUNG .*$
        FIRMWARE REGEXP: .*-2[34]$
        ATTRIBUTE OPTIONS: 009 Power_On_Half_Minutes
        OTHER PRESETS: Fixes byte order in some SMART data (same as -F samsung2)


        > The standard LS comes with Samsungs 120Gb ... I see from the config
        > file there are SMART firmware issues with these disks:
        >
        > -F TYPE Use firmware bug workaround. Type is one of: none, samsung
        >
        > Do you need to use that option?

        I don't have to add anything to the command line as the smartmontools database
        figures it out.


        > Can you paste a copy of your config file

        I just use one line:

        /dev/hda -a -n standby -I 8 -I 194 -o on -S on -s (S/../.././02|L/../../6/03)

        and then check /var/log/messages every so often. I would like to have
        a simple way to use the e-mail feature...

        Derek


        > -Sam.
        >
        > --- In LinkStation_General@yahoogroups.com, Derek Taubert
        > <taubert@g...> wrote:
        > >
        > > I do. See post #544.
        > >
        > > etc/init.d/smartd
        > > etc/smartd.conf
        > > usr/sbin/smartctl
        > > usr/sbin/smartd
        > >
        > > Just uploaded to the files section...
        > >
        > > Derek
        > >
        > >
        > > On Wed, Jun 29, 2005 at 06:52:33PM -0000, Frenchy wrote:
        > > > Great deal. Do you have a smartmon package that runs on LS?
        > > > If so I can use it for testing and build an interface for
        > Smartmon.
        > > > Let me know
        > > > -Sam.
      • downlalaway
        Just on the earlier note of there mostly being samsungs - I ve got a WD1200BB caviar in my LS1 (seems nice and quite) ... 2002-4 Bruce Allen ... samsung2) ...
        Message 3 of 20 , Jun 30, 2005
          Just on the earlier note of there mostly being samsungs - I've got a
          WD1200BB caviar in my LS1 (seems nice and quite)
          --- In LinkStation_General@yahoogroups.com, Derek Taubert
          <taubert@g...> wrote:
          > On Thu, Jun 30, 2005 at 12:23:05AM -0000, Frenchy wrote:
          > > Hi Derek,
          > >
          > > Got the files, thanks.
          > > What disk do you have in your box?
          >
          > root@HD-HLANA09:~# smartctl -P show /dev/hda
          > smartctl version 5.33 [powerpc-unknown-linux-gnu] Copyright (C)
          2002-4 Bruce Allen
          > Home page is http://smartmontools.sourceforge.net/
          >
          > Drive found in smartmontools Database. Drive identity strings:
          > MODEL: SAMSUNG SV1203N
          > FIRMWARE: TQ100-23
          > match smartmontools Drive Database entry:
          > MODEL REGEXP: ^SAMSUNG .*$
          > FIRMWARE REGEXP: .*-2[34]$
          > ATTRIBUTE OPTIONS: 009 Power_On_Half_Minutes
          > OTHER PRESETS: Fixes byte order in some SMART data (same as -F
          samsung2)
          >
          >
          > > The standard LS comes with Samsungs 120Gb ... I see from the config
          > > file there are SMART firmware issues with these disks:
          > >
          > > -F TYPE Use firmware bug workaround. Type is one of: none, samsung
          > >
          > > Do you need to use that option?
          >
          > I don't have to add anything to the command line as the
          smartmontools database
          > figures it out.
          >
          >
          > > Can you paste a copy of your config file
          >
          > I just use one line:
          >
          > /dev/hda -a -n standby -I 8 -I 194 -o on -S on -s
          (S/../.././02|L/../../6/03)
          >
          > and then check /var/log/messages every so often. I would like to have
          > a simple way to use the e-mail feature...
          >
          > Derek
          >
          >
          > > -Sam.
          > >
          > > --- In LinkStation_General@yahoogroups.com, Derek Taubert
          > > <taubert@g...> wrote:
          > > >
          > > > I do. See post #544.
          > > >
          > > > etc/init.d/smartd
          > > > etc/smartd.conf
          > > > usr/sbin/smartctl
          > > > usr/sbin/smartd
          > > >
          > > > Just uploaded to the files section...
          > > >
          > > > Derek
          > > >
          > > >
          > > > On Wed, Jun 29, 2005 at 06:52:33PM -0000, Frenchy wrote:
          > > > > Great deal. Do you have a smartmon package that runs on LS?
          > > > > If so I can use it for testing and build an interface for
          > > Smartmon.
          > > > > Let me know
          > > > > -Sam.
        • Frenchy
          Derek, If you don t have a runing email service, you best shot is to direct the email output to the linkstation.log file using script example3 -Sam. ...
          Message 4 of 20 , Jun 30, 2005
            Derek,
            If you don't have a runing email service, you best shot is to direct
            the email output to the linkstation.log file using script "example3"
            -Sam.
            --- In LinkStation_General@yahoogroups.com, Derek Taubert
            <taubert@g...> wrote:
            > On Thu, Jun 30, 2005 at 12:23:05AM -0000, Frenchy wrote:
            > > Hi Derek,
            > >
            > > Got the files, thanks.
            > > What disk do you have in your box?
            >
            > root@HD-HLANA09:~# smartctl -P show /dev/hda
            > smartctl version 5.33 [powerpc-unknown-linux-gnu] Copyright (C)
            2002-4 Bruce Allen
            > Home page is http://smartmontools.sourceforge.net/
            >
            > Drive found in smartmontools Database. Drive identity strings:
            > MODEL: SAMSUNG SV1203N
            > FIRMWARE: TQ100-23
            > match smartmontools Drive Database entry:
            > MODEL REGEXP: ^SAMSUNG .*$
            > FIRMWARE REGEXP: .*-2[34]$
            > ATTRIBUTE OPTIONS: 009 Power_On_Half_Minutes
            > OTHER PRESETS: Fixes byte order in some SMART data (same as -
            F samsung2)
            >
            >
            > > The standard LS comes with Samsungs 120Gb ... I see from the
            config
            > > file there are SMART firmware issues with these disks:
            > >
            > > -F TYPE Use firmware bug workaround. Type is one of: none,
            samsung
            > >
            > > Do you need to use that option?
            >
            > I don't have to add anything to the command line as the
            smartmontools database
            > figures it out.
            >
            >
            > > Can you paste a copy of your config file
            >
            > I just use one line:
            >
            > /dev/hda -a -n standby -I 8 -I 194 -o on -S on -s
            (S/../.././02|L/../../6/03)
            >
            > and then check /var/log/messages every so often. I would like to
            have
            > a simple way to use the e-mail feature...
            >
            > Derek
            >
            >
            > > -Sam.
            > >
            > > --- In LinkStation_General@yahoogroups.com, Derek Taubert
            > > <taubert@g...> wrote:
            > > >
            > > > I do. See post #544.
            > > >
            > > > etc/init.d/smartd
            > > > etc/smartd.conf
            > > > usr/sbin/smartctl
            > > > usr/sbin/smartd
            > > >
            > > > Just uploaded to the files section...
            > > >
            > > > Derek
            > > >
            > > >
            > > > On Wed, Jun 29, 2005 at 06:52:33PM -0000, Frenchy wrote:
            > > > > Great deal. Do you have a smartmon package that runs on LS?
            > > > > If so I can use it for testing and build an interface for
            > > Smartmon.
            > > > > Let me know
            > > > > -Sam.
          • Frenchy
            yes I have both WD (newer LS) and Samsung (earlier box) so long they keep our data. My main recommendation would be not to use a 7200rpm disk replacement for
            Message 5 of 20 , Jun 30, 2005
              yes I have both WD (newer LS) and Samsung (earlier box) so long they
              keep our data.
              My main recommendation would be not to use a 7200rpm disk
              replacement for the 120Gb besides 5400rpm are cheaper and cooler so
              you may be able to run the fan silent all the time.

              I am doing some testing with smartmon to get a good handle on
              Attribute ID 194. I am trying to find a way to integrate a
              temperature regulation with AutoFan for 5400rpm disk. 7200rpm are
              too hot not to have the fan high while spinning.
              -Sam.

              --- In LinkStation_General@yahoogroups.com, "downlalaway"
              <downlalaway@y...> wrote:
              > Just on the earlier note of there mostly being samsungs - I've got
              a
              > WD1200BB caviar in my LS1 (seems nice and quite)
              > --- In LinkStation_General@yahoogroups.com, Derek Taubert
              > <taubert@g...> wrote:
              > > On Thu, Jun 30, 2005 at 12:23:05AM -0000, Frenchy wrote:
              > > > Hi Derek,
              > > >
              > > > Got the files, thanks.
              > > > What disk do you have in your box?
              > >
              > > root@HD-HLANA09:~# smartctl -P show /dev/hda
              > > smartctl version 5.33 [powerpc-unknown-linux-gnu] Copyright (C)
              > 2002-4 Bruce Allen
              > > Home page is http://smartmontools.sourceforge.net/
              > >
              > > Drive found in smartmontools Database. Drive identity strings:
              > > MODEL: SAMSUNG SV1203N
              > > FIRMWARE: TQ100-23
              > > match smartmontools Drive Database entry:
              > > MODEL REGEXP: ^SAMSUNG .*$
              > > FIRMWARE REGEXP: .*-2[34]$
              > > ATTRIBUTE OPTIONS: 009 Power_On_Half_Minutes
              > > OTHER PRESETS: Fixes byte order in some SMART data (same
              as -F
              > samsung2)
              > >
              > >
              > > > The standard LS comes with Samsungs 120Gb ... I see from the
              config
              > > > file there are SMART firmware issues with these disks:
              > > >
              > > > -F TYPE Use firmware bug workaround. Type is one of: none,
              samsung
              > > >
              > > > Do you need to use that option?
              > >
              > > I don't have to add anything to the command line as the
              > smartmontools database
              > > figures it out.
              > >
              > >
              > > > Can you paste a copy of your config file
              > >
              > > I just use one line:
              > >
              > > /dev/hda -a -n standby -I 8 -I 194 -o on -S on -s
              > (S/../.././02|L/../../6/03)
              > >
              > > and then check /var/log/messages every so often. I would like
              to have
              > > a simple way to use the e-mail feature...
              > >
              > > Derek
              > >
              > >
              > > > -Sam.
              > > >
              > > > --- In LinkStation_General@yahoogroups.com, Derek Taubert
              > > > <taubert@g...> wrote:
              > > > >
              > > > > I do. See post #544.
              > > > >
              > > > > etc/init.d/smartd
              > > > > etc/smartd.conf
              > > > > usr/sbin/smartctl
              > > > > usr/sbin/smartd
              > > > >
              > > > > Just uploaded to the files section...
              > > > >
              > > > > Derek
              > > > >
              > > > >
              > > > > On Wed, Jun 29, 2005 at 06:52:33PM -0000, Frenchy wrote:
              > > > > > Great deal. Do you have a smartmon package that runs on LS?
              > > > > > If so I can use it for testing and build an interface for
              > > > Smartmon.
              > > > > > Let me know
              > > > > > -Sam.
            • Frenchy
              About regulating fan speed based on disk SMART temperature (SMARTmon)... I am done with the testing. It turns out it is a bad idea to cycle the fan based on
              Message 6 of 20 , Jul 1, 2005
                About regulating fan speed based on disk SMART temperature
                (SMARTmon)...

                I am done with the testing.
                It turns out it is a bad idea to cycle the fan based on disk temp
                while it is spinning!!

                - Temperature tests with SMART AttributeID=194 show it is hard to
                cool down the disk once it has warmed by running the fan at silent
                speed.

                - Cycling fan on/off based on disk temperature is not practical for
                such a small fan with a hot disk inside a small enclosure.

                - The best way to keep the disk cool is what AutoFan
                does "DiskON=FanON".

                - Thus spinning the disk with a low fan is not an option if you like
                to stay on the good side with all your data. Heat is what kills
                HDD's. Cooler means longer life.

                Test results:
                Buffalo 120Gb/7200Rpm: WD1200BB-00GUA0 - Specs: 20W to start. 8W
                idle. 1W Standby.
                Spinning> FanHIGH 30/32C base temp
                FanLOW +6C in 10mn! (36C and up)
                FanHIGH only -1C in 10mn!

                After Market 300Gb/7200Rpm: ST3300831A (hot disk)
                Spinning> FanHIGH 39/40C base temp
                FanLOW +4 in 10mn (43C and up)
                FanHIGH only -1C in 10mn!

                Now if you are crazy like most of us, be my guest. Use these
                smartmon strings for your own testing:
                - - -
                temp_hda="$(/usr/sbin/smartctl -a /dev/hda | /bin/grep 194
                | /bin/awk '{print $10}')"
                echo 'The disk temperature is '"$temp_hda"' Celcius'
                # You **need to have smartmon installed** to use the above!
                - - -
                There are some real interesting things to be done to integrate
                smartmon on the LS but that will be different topic for me perhaps
                later this summer... (watchdogs, shutdown, health test and reports)

                I will not integrate Smartmon temperatures to cycle the fan on/off
                while the disk is spinning.
                Just get your LS to let the disk stop and the fan will go silent. If
                the disk does not stop see my FAQ in the file section to
                troubleshoot why the LS keeps writing to your disk.

                -Sam.
                -------------------------------------------------------

                --- In LinkStation_General@yahoogroups.com, "Frenchy "
                <glasseron@y...> wrote:
                > yes I have both WD (newer LS) and Samsung (earlier box) so long
                they
                > keep our data.
                > My main recommendation would be not to use a 7200rpm disk
                > replacement for the 120Gb besides 5400rpm are cheaper and cooler
                so
                > you may be able to run the fan silent all the time.
                >
                > I am doing some testing with smartmon to get a good handle on
                > Attribute ID 194. I am trying to find a way to integrate a
                > temperature regulation with AutoFan for 5400rpm disk. 7200rpm are
                > too hot not to have the fan high while spinning.
                > -Sam.
                >
                > --- In LinkStation_General@yahoogroups.com, "downlalaway"
                > <downlalaway@y...> wrote:
                > > Just on the earlier note of there mostly being samsungs - I've
                got
                > a
                > > WD1200BB caviar in my LS1 (seems nice and quite)
                > > --- In LinkStation_General@yahoogroups.com, Derek Taubert
                > > <taubert@g...> wrote:
                > > > On Thu, Jun 30, 2005 at 12:23:05AM -0000, Frenchy wrote:
                > > > > Hi Derek,
                > > > >
                > > > > Got the files, thanks.
                > > > > What disk do you have in your box?
                > > >
                > > > root@HD-HLANA09:~# smartctl -P show /dev/hda
                > > > smartctl version 5.33 [powerpc-unknown-linux-gnu] Copyright (C)
                > > 2002-4 Bruce Allen
                > > > Home page is http://smartmontools.sourceforge.net/
                > > >
                > > > Drive found in smartmontools Database. Drive identity strings:
                > > > MODEL: SAMSUNG SV1203N
                > > > FIRMWARE: TQ100-23
                > > > match smartmontools Drive Database entry:
                > > > MODEL REGEXP: ^SAMSUNG .*$
                > > > FIRMWARE REGEXP: .*-2[34]$
                > > > ATTRIBUTE OPTIONS: 009 Power_On_Half_Minutes
                > > > OTHER PRESETS: Fixes byte order in some SMART data (same
                > as -F
                > > samsung2)
                > > >
                > > >
                > > > > The standard LS comes with Samsungs 120Gb ... I see from the
                > config
                > > > > file there are SMART firmware issues with these disks:
                > > > >
                > > > > -F TYPE Use firmware bug workaround. Type is one of: none,
                > samsung
                > > > >
                > > > > Do you need to use that option?
                > > >
                > > > I don't have to add anything to the command line as the
                > > smartmontools database
                > > > figures it out.
                > > >
                > > >
                > > > > Can you paste a copy of your config file
                > > >
                > > > I just use one line:
                > > >
                > > > /dev/hda -a -n standby -I 8 -I 194 -o on -S on -s
                > > (S/../.././02|L/../../6/03)
                > > >
                > > > and then check /var/log/messages every so often. I would like
                > to have
                > > > a simple way to use the e-mail feature...
                > > >
                > > > Derek
                > > >
                > > >
                > > > > -Sam.
                > > > >
                > > > > --- In LinkStation_General@yahoogroups.com, Derek Taubert
                > > > > <taubert@g...> wrote:
                > > > > >
                > > > > > I do. See post #544.
                > > > > >
                > > > > > etc/init.d/smartd
                > > > > > etc/smartd.conf
                > > > > > usr/sbin/smartctl
                > > > > > usr/sbin/smartd
                > > > > >
                > > > > > Just uploaded to the files section...
                > > > > >
                > > > > > Derek
                > > > > >
                > > > > >
                > > > > > On Wed, Jun 29, 2005 at 06:52:33PM -0000, Frenchy wrote:
                > > > > > > Great deal. Do you have a smartmon package that runs on
                LS?
                > > > > > > If so I can use it for testing and build an interface
                for
                > > > > Smartmon.
                > > > > > > Let me know
                > > > > > > -Sam.
              Your message has been successfully submitted and would be delivered to recipients shortly.