2

I'm trying to let my backup server have its disks in standby as often as possible. Outside of smartd or actual backup usage, the disks currently spin up once per day (various cron tasks).

smartd, by default, writes attribute logs and state files. This wakes up the disks.

It seems attribute logs are written even when smartd is configured to skip disks in standby (-n standby,48,q in smartd.conf). The man page notes this can be disabled by passing -A '' to smartd. State saving can be disabled by passing -s '' to smartd. (These are parameters to the smartd executable, not in smartd.conf.)

The man page does not note what functionality relies on these saved states or attribute logs. It does mention it uses state files to note, among other things, the last email it sent.

What functionality will I lose by disabling these writes? Will smartd send an email each time it checks attributes because it does not know it already sent one? Or is the state information also cached in memory and will it only resend warning emails when restarting smartd?

Current smartd.conf:

/dev/disk/by-id/scsi-SATA_WDC_WD40EFRX-68_XYZ -n standby,24,q -o on -S on -m root -a -l xerror -I 194 -I 3 -W 0,55,60

3 Answers3

0

Have you considered running smartd with a very large value for -i, and then trigger the checks by sending SIGUSR1 to the daemon when it is okay to do so (say when the crons are running).

This way the daemon will not spin up your disks.

Sorry, this does not actually answer your question.

chutz
  • 8,300
0

You won't lose any functionality of smartd, it's just a csv log of the values of the attributes at that time.

If you want to keep them change the prefix to a tmpfs dir and backup those files with your weekly backup. If you haven't found a need to check by yourself just disable it.

Jorge Nerín
  • 1,138
0

I may not be answering your question directly, but I highly recommend against doing this. Spinning up the disks puts a larger strain on the mechanical components inside the drive (hence why the power cycle count is a good indicator of a drive's age). It's recommended to keep the disks spinning as much as possible to extend drive life.

Nathan C
  • 15,223