Add support for a new "smartctl" config option

This option allows to configure custom smartctl
commands for devices that cannot be autodetected.
This commit is contained in:
Andrea Mazzoleni 2015-04-08 22:56:44 +02:00
parent 024b3f80fa
commit 214070dc4d
14 changed files with 315 additions and 57 deletions

View file

@ -394,6 +394,10 @@ Commands
This command uses the "smartctl" tool, and it's equivalent to run
"smartctl -a" on all the devices.
If your devices are not autodetected correctly, you can configure
a custom command using the "smartctl" option in the configuration
file.
Nothing is modified.
up
@ -1001,6 +1005,23 @@ Configuration
This option is only required for Windows.
smartctl DISK/PARITY OPTIONS...
Defines a custom smartctl command to obtain the SMART attributes
for each disk. This may be required for RAID controllers and for
some USB disk that cannot be autodetected.
DISK is the same disk name specified in the "disk" option.
PARITY is one of the parity name as "parity,[1,2,3,4,5,6,z]-parity".
In the specified OPTIONS, the "%s" string is replaced by the
device name. Note that in case of RAID controllers the device is likely
fixed, and you don't have to use "%s".
Refers at the smartmontools documentation about the possible options:
:https://www.smartmontools.org/wiki/Supported_RAID-Controllers
:https://www.smartmontools.org/wiki/Supported_USB-Devices
Examples
An example of a typical configuration for Unix is:
@ -1012,6 +1033,9 @@ Configuration
:disk d3 /mnt/disk3/
:exclude /lost+found/
:exclude /tmp/
:smartctl d1 -d sat %s
:smartctl d2 -d usbjmicron %s
:smartctl parity -d areca,1/1 /dev/sg0
An example of a typical configuration for Windows is:
@ -1024,6 +1048,9 @@ Configuration
:exclude Thumbs.db
:exclude \$RECYCLE.BIN
:exclude \System Volume Information
:smartctl d1 -d sat %s
:smartctl d2 -d usbjmicron %s
:smartctl parity -d areca,1/1 /dev/arcmsr0
Pattern
Patterns are used to select a subset of files to exclude or include in