Re: how to control how often smartd-runner fires.

Ray Andrews <[email protected]> Thu, 19 Jan 2017 07:20:33 -0800
Newsgroups gmane.linux.utilities.smartmontools
Message-ID <[email protected]>
On 19/01/17 01:55 AM, Christian Franke wrote:
> Ray Andrews wrote:
>
> The '-i 30' smartd.conf directive means "ignore Attribute number 30 when
> checking for failure of Usage Attributes" (see smartd.conf man page).
> This is probably not what you want.
>
> The '-i 30' smartd command line(!) option "sets the interval between
> disk checks to 30 seconds" (see smartd man page). Using such short
> intervals is not recommend, except for testing purposes.

Shoot, thanks.  I can't stand that when command line switches are 
contrary to
directives in a config file.  Yeah, it was just for testing tho, I'm 
trying to see an actual
error report, namely my '77 pending sectors', since then I'll be able to 
know
right away if I've fixed it, rather than having to wait about 12 hours 
for the next
report.  Or, some way of getting that report directly from smartd itself.

The usage of 'smartd-runner' suggests that you are using Debian or
> Ubuntu.
Yes.
>   If yes, the smartd command line options could be configured in
> '/etc/default/smartmontools'. Note that both are Debian/Ubuntu specific
> and not part of the upstream source code.

Ok, good to know, I presumed the whole show came from one source. 
Knowing that,
I'd forget smartd-runner and just access error messages directly if I 
knew how.
> This is as expected. The '-M test' directive is only intended to test
> the functionality of  the '-m ... -M exec ...' directives.

Yeah, it's what I expected, still I'd like to be able to fire up an 
actual test at will.

> The '-M exec' script is only run on error conditions which also result
> in a LOG_CRIT syslog message. For LOG_INFO messages issued by smartd,
> see the configured syslog. On Debian/Ubuntu, this is usually
> '/var/log/daemon.log'.

Complicated!  Ok, I'll take a look.  No way of intercepting these LOG_* 
messages?
> By default, pending sectors are considered critical and therefore daily
> reminder LOG_CRIT messages are issued. Try '-C 197+' directive to change
> this.

Ah!  But I very much  want to see it if it increased!  If the pending 
sectors went above 77
that's new information so these blocking directives are not what I want 
per se.
>
> See '-m', '-M'and '-C' sections on smartd.conf man page for further details.
>
> Thanks,
> Christian
>

Thanks, that's more stuff to chew on.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot