Hi Bruce,
              thank you :o)
You've solved my doubts.
I would to receive an alarm/email if ever my hard disk worked over some temperature thresholds, but I can always use awk to get this.
 
The -M test directive works fine to me.
 
Unfortunately I lost an hard disk last week because a not detected failure by Activesmart (under windows) and I wouldn't have a such problem  under linux (this hosts a raid 1 configuration).
 
Even if I read all the man pages what I don't understand yet is how smartctl and smartd interact among them.
 
 
Thank you Bruce,
 Ciao
 
Fabrizio
 
 


Bruce Allen <ballen@gravity.phys.uwm.edu> wrote:
Ciao Fabrizio,

The script is only run if a problem is detected. It's NOT run when an
Attribute value changes, since this is generally not a sign of a problem.
If an Attribute fails (meaning that it's normalized value is less than or
equal to the threshold value) THEN the script will be run. But it WON'T
be run if the Attribute value simply changes, but does not fail.

To test that your script runs, please add:
-M test
to your list of Directives.

Please let us know if this works OK.

Also, you might want to update your copy of smartmontools to the most
recent 5.1-14 release.

A presto,
Bruce

On Wed, 9 Jul 2003, Fabrizio Di Meo wrote:

> Hi,
> I'm trying to use the -M directive of smartmontools, but nothing happens (also in case of pre-fail or usage).
>
> Below there's the script smartd.conf:
>
>
> #/etc/smartd.conf
>
> /dev/hda -H -o on -f -l error -l selftest -m fabriziodimeo@yahoo.it,root@localhost -t \
> -R 1 -R 3 -R 4 -R 5 -R 7 -R 11 -R 13 -M exec /usr/test/run
>
> # Monitor SMART status, ATA Error Log, Self-test log, and track
> # changes in all attributes except for attribute 194 (-I 194)
>
> /dev/hdd -H -o on -f -l error -l selftest -m fabriziodimeo@yahoo.it,root@localhost -t \
> -R 1 -R 3 -R 4 -R 5 -R 7 -R 11 -R 13 -R 194 -M exec /usr/test/run
>
>
> during a temperature changing (and using smartd -d -i 30) I get these messages:
>
> obiwan:/usr/test # smartd -d -i 10
> smartd version 5.1-9 Copyright (C) 2002-3 Bruce Allen
> Home page is http://smartmontools.sourceforge.net/
> Using configuration file /etc/smartd.conf
> Device: /dev/hda, opened
> Device: /dev/hda, enabled SMART Automatic Offline Testing.
> Device: /dev/hda, is SMART capable. Adding to "monitor" list.
> Device: /dev/hdd, opened
> Device: /dev/hdd, enabled SMART Automatic Offline Testing.
> Device: /dev/hdd, is SMART capable. Adding to "monitor" list.
> Started monitoring 2 ATA and 0 SCSI devices
> Device: /dev/hdd, SMART Usage Attribute: 194 Temperature_Celsius changed from 253 [Raw 44] to 253 [Raw 42]
> Device: /dev/hdd, SMART Usage Attribute: 194 Temperature_Celsius changed from 253 [Raw 42] to 253 [Raw 44]
>
> but the script "run" isn't executed.
>
> Is there something wrong?
>
> Thank you,
> Fabrizio
>
>
>
>
> ---------------------------------
> Yahoo! Mail: 6MB di spazio gratuito, 30MB per i tuoi allegati, l'antivirus, il filtro Anti-spam



Yahoo! Mail: 6MB di spazio gratuito, 30MB per i tuoi allegati, l'antivirus, il filtro Anti-spam