.ig
Copyright (C) 2002-10 Bruce Allen <smartmontools-support@lists.sourceforge.net>
-Copyright (C) 2004-13 Christian Franke <smartmontools-support@lists.sourceforge.net>
+Copyright (C) 2004-14 Christian Franke <smartmontools-support@lists.sourceforge.net>
-$Id: smartd.conf.5.in 3741 2013-01-02 17:06:54Z chrfranke $
+$Id: smartd.conf.5.in 3965 2014-07-20 14:46:41Z chrfranke $
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
.SH NAME
\fBsmartd.conf\fP \- SMART Disk Monitoring Daemon Configuration File\fP
-.\" %IF NOT OS Windows
-.SH FULL PATH
-.B /usr/local/etc/smartd.conf
-
-.\" %ENDIF NOT OS Windows
.SH PACKAGE VERSION
CURRENT_SVN_VERSION CURRENT_SVN_DATE CURRENT_SVN_REV
Note: a line whose first character is a hash sign \'#\' is treated as
a white-space blank line, \fBnot\fP as a non-existent line, and will
\fBend\fP a continuation line.
-.PP 0
-.fi
+.PP
+
Here is an example configuration file. It\'s for illustrative purposes
only; please don\'t copy it onto your system without reading to the end
of the
.B # device, four SATA disks connected to an Areca
.B # RAID controller, and one SATA disk.
.B #
-.nf
.B # First ATA disk on two different interfaces. On
.B # the second disk, start a long self-test every
.B # Sunday between 3 and 4 am.
.B \ \ /dev/hda -a -m admin@example.com,root@localhost
.B \ \ /dev/hdc -a -I 194 -I 5 -i 12 -s L/../../7/03
.B #
-.nf
.B # SCSI disks. Send a TEST warning email to admin on
.B # startup.
.B #
.B \ \ /dev/sda
.B \ \ /dev/sdb -m admin@example.com -M test
.B #
-.nf
.B # Strange device. It\'s SCSI. Start a scheduled
.B # long self test between 5 and 6 am Monday/Thursday
.B \ \ /dev/weird -d scsi -s L/../../(1|4)/05
.B #
-.nf
.B # An ATA disk may appear as a SCSI device to the
.B # OS. If a SCSI to ATA Translation (SAT) layer
.B # is between the OS and the device then this can be
.B # environments.
.B \ \ /dev/sda -a -d sat
.B #
-.nf
.\" %IF OS Linux
.B # Three disks connected to a MegaRAID controller
.B # Start short self-tests daily between 1-2, 2-3, and
.B \ \ /dev/sda -d megaraid,1 -a -s S/../.././02
.B \ \ /dev/sda -d megaraid,2 -a -s S/../.././03
.B \ \ /dev/bus/0 -d megaraid,2 -a -s S/../.././03
-.B
+.B #
+.B # Three disks connected to an AacRaid controller
+.B # Start short self-tests daily between 1-2, 2-3, and
+.B # 3-4 am.
+.B \ \ /dev/sda -d aacraid,0,0,66 -a -s S/../.././01
+.B \ \ /dev/sda -d aacraid,0,0,67 -a -s S/../.././02
+.B \ \ /dev/sda -d aacraid,0,0,68 -a -s S/../.././03
.B #
.\" %ENDIF OS Linux
-.nf
.B # Four ATA disks on a 3ware 6/7/8000 controller.
.B # Start short self-tests daily between midnight and 1am,
.B # 1-2, 2-3, and 3-4 am. Starting with the Linux 2.6
.B \ \ /dev/sdd -d 3ware,2 -a -s S/../.././02
.B \ \ /dev/sdd -d 3ware,3 -a -s S/../.././03
.B #
-.nf
.B # Two ATA disks on a 3ware 9000 controller.
.B # Start long self-tests Sundays between midnight and
.B # 1am and 2-3 am
.B \ \ /dev/twa0 -d 3ware,0 -a -s L/../../7/00
.B \ \ /dev/twa0 -d 3ware,1 -a -s L/../../7/02
.B #
-.nf
.B # Two SATA (not SAS) disks on a 3ware 9750 controller.
.B # Start long self-tests Sundays between midnight and
.B # 1am and 2-3 am
.B \ \ /dev/tws0 -d 3ware,1 -a -s L/../../7/02
.\" %ENDIF OS FreeBSD
.B #
-.nf
.B # Three SATA disks on a HighPoint RocketRAID controller.
.B # Start short self-tests daily between 1-2, 2-3, and
.B # 3-4 am.
.B /dev/hptrr -d hpt,1/3 -a -s S/../.././03
.\" %ENDIF OS FreeBSD
.B #
-.nf
.B # Two SATA disks connected to a HighPoint RocketRAID
.B # via a pmport device. Start long self-tests Sundays
.B # between midnight and 1am and 2-3 am.
.B \ \ /dev/hptrr -d hpt,1/4/2 -a -s L/../../7/02
.B #
.\" %ENDIF OS FreeBSD
-.nf
.B # Three SATA disks connected to an Areca
.B # RAID controller. Start long self-tests Sundays
.B # between midnight and 3 am.
.B \ \ /dev/arcmsr0 -d areca,3 -a -s L/../../7/02
.\" %ENDIF OS FreeBSD
.B #
-.nf
.B # The following line enables monitoring of the
.B # ATA Error Log and the Self-Test Error Log.
.B # It also tracks changes in both Prefailure
.B ################################################
.fi
-.PP
.SH CONFIGURATION FILE DIRECTIVES
-.PP
-
If a non-comment entry in the configuration file is the text string
.B DEVICESCAN
in capital letters, then
devices that are found in the scan. Please see below for additional
details.
-[NEW EXPERIMENTAL SMARTD FEATURE] If an entry in the configuration file
-starts with
+If an entry in the configuration file starts with
.B DEFAULT
instead of a device name, then all directives in this entry are set
as defaults for the next device entries.
-
+.PP
This configuration:
-
+.PP
.nf
\ \ DEFAULT -a -R5! -W 2,40,45 -I 194 -s L/../../7/00 -m admin@example.com
\ \ /dev/sda
\ \ /dev/sdd
\ \ /dev/sde -d removable
.fi
-
+.PP
has the same effect as:
-
+.PP
.nf
\ \ /dev/sda -a -R5! -W 2,40,45 -I 194 -s L/../../7/00 -m admin@example.com
\ \ /dev/sdb -a -R5! -W 2,40,45 -I 194 -s L/../../7/00 -m admin@example.com
\ \ /dev/sde -d removable -H -m admin@example.com
.fi
-.sp 2
+
The following are the Directives that may appear following the device
name or
.B DEVICESCAN
number.
Please see the \fBsmartctl\fP(8) man page for further details.
+.I aacraid,H,L,ID
+\- [Linux only] [NEW EXPERIMENTAL SMARTD FEATURE]
+the device consists of one or more SCSI/SAS disks connected to an AacRaid controller.
+The non-negative integers H,L,ID (Host number, Lun, ID) denote which disk
+on the controller is monitored.
+In log files and email messages this disk will be identified as aacraid_disk_HH_LL_ID.
+Please see the \fBsmartctl\fP(8) man page for further details.
+
.\" %ENDIF OS Linux
.\" %IF OS FreeBSD Linux
.I 3ware,N
connected to a HighPoint RocketRAID controller. The integer L is the
controller id, the integer M is the channel number, and the integer N
is the PMPort number if it is available. The allowed values of L are
-from 1 to 4 inclusive, M are from 1 to 16 inclusive and N from 1 to 4
+from 1 to 4 inclusive, M are from 1 to 128 inclusive and N from 1 to 4
if PMPort available. And also these values are limited by the model
of the HighPoint RocketRAID controller.
In log files and email messages this disk will be identified as
not supported. For RAID configurations, this is typically set to
70,70 deciseconds.
[Please see the \fBsmartctl \-l scterc\fP command-line option.]
-
.TP
.B \-e NAME[,VALUE]
Sets non-SMART device settings when \fBsmartd\fP starts up and has no
.I wcache,[on|off]
\- [ATA only] Sets the volatile write cache feature.
-
.TP
.B \-s REGEXP
Run Self-Tests or Offline Immediate Tests, at scheduled times. A
power cycles. If state persistence (\'\-s\' option) is enabled, the last
test span is preserved by smartd and used if (and only if) the selective
self test log is empty.
-
.IP \fBMM\fP 4
is the month of the year, expressed with two decimal digits. The
range is from 01 (January) to 12 (December) inclusive. Do \fBnot\fP
disk is active again.
Unix users: please beware that the rules for extended regular
-expressions [regex(7)] are \fBnot\fP the same as the rules for
-file-name pattern matching by the shell [glob(7)]. \fBsmartd\fP will
+expressions [\fBregex\fP(7)] are \fBnot\fP the same as the rules for
+file-name pattern matching by the shell [\fBglob\fP(7)]. \fBsmartd\fP will
issue harmless informational warning messages if it detects characters
in \fBREGEXP\fP that appear to indicate that you have made this
mistake.
\fBsmartd\fP
startup.
-By default, email is sent using the system
-.B mail
-command. In order that
-\fBsmartd\fP
-find the mail command (normally /bin/mail) an executable named
-.B \'mail\'
-must be in the path of the shell or environment from which
+By default, email is sent using the system \fBmail\fP(1) command.
+In order that \fBsmartd\fP find this command (normally /usr/bin/mail) the
+executable must be in the path of the shell or environment from which
\fBsmartd\fP
was started. If you wish to specify an explicit path to the mail
executable (for example /usr/local/bin/mail) or a custom script to
run, please use the \'\-M exec\' Directive below.
-.\" %IF OS Solaris
-Note that by default under Solaris, in the previous paragraph,
-\'\fBmailx\fP\' and \'\fB/bin/mailx\fP\' are used, since Solaris
-\'/bin/mail\' does not accept a \'\-s\' (Subject) command-line
-argument.
-
-.\" %ENDIF OS Solaris
.\" %IF OS Windows
On Windows, the \'\fBBlat\fP\' mailer
(\fBhttp://blat.sourceforge.net/\fP) is used by default.
you have mail problems, we recommend running \fBsmartd\fP in debug
mode with the \'-d\' flag, using the \'-M test\' Directive described
below.
+.\" %IF ENABLE_SMARTDPLUGINDIR
.\" %IF NOT OS Windows
[NEW EXPERIMENTAL SMARTD FEATURE]
This is handled by the script /usr/local/etc/smartd_warning.sh
(see also \'\-M exec\' below).
.\" %ENDIF NOT OS Windows
+.\" %ENDIF ENABLE_SMARTDPLUGINDIR
.\" %IF OS Windows
[Windows only] [NEW EXPERIMENTAL SMARTD FEATURE]
.RS 7
.IP \fBSMARTD_MAILER\fP 4
is set to the argument of \-M exec, if present or else to \'mail\'
-(examples: /bin/mail, mail).
+(examples: /usr/local/bin/mail, mail).
.IP \fBSMARTD_DEVICE\fP 4
is set to the device path (examples: /dev/hda, /dev/sdb).
.IP \fBSMARTD_DEVICETYPE\fP 4
or \'/dev/hptrr [hpt_1/1/1]\' under FreeBSD. For Areca controllers, the
form is \'/dev/sg2 [areca_disk_09]\' on Linux or \'/dev/arcmsr0 [areca_disk_09]\' on FreeBSD. In these cases the device string
contains a space and is NOT quoted. So to use $SMARTD_DEVICESTRING in a
-bash script you should probably enclose it in double quotes.
+shell script you should probably enclose it in double quotes.
.IP \fBSMARTD_DEVICEINFO\fP 4
is set to device identify information. It includes most of the info printed
by \fBsmartctl \-i\fP but uses a brief single line format.
.IP \fBSMARTD_FAILTYPE\fP 4
gives the reason for the warning or message email. The possible values that
it takes and their meanings are:
-.nf
-.fi
+.br
\fIEmailTest\fP: this is an email test message.
-.nf
-.fi
+.br
\fIHealth\fP: the SMART health status indicates imminent failure.
-.nf
-.fi
+.br
\fIUsage\fP: a usage Attribute has failed.
-.nf
-.fi
+.br
\fISelfTest\fP: the number of self-test failures has increased.
-.nf
-.fi
+.br
\fIErrorCount\fP: the number of errors in the ATA error log has increased.
-.nf
-.fi
+.br
\fICurrentPendingSector\fP: one of more disk sectors could not be
read and are marked to be reallocated (replaced with spare sectors).
-.nf
-.fi
+.br
\fIOfflineUncorrectableSector\fP: during off-line testing, or self-testing,
one or more disk sectors could not be read.
-.nf
-.fi
+.br
\fITemperature\fP: Temperature reached critical limit (see \-W directive).
-.nf
-.fi
+.br
\fIFailedHealthCheck\fP: the SMART health status command failed.
-.nf
-.fi
+.br
\fIFailedReadSmartData\fP: the command to read SMART Attribute data failed.
-.nf
-.fi
+.br
\fIFailedReadSmartErrorLog\fP: the command to read the SMART error log failed.
-.nf
-.fi
+.br
\fIFailedReadSmartSelfTestLog\fP: the command to read the SMART self-test log failed.
-.nf
-.fi
+.br
\fIFailedOpenDevice\fP: the open() command to the device failed.
.IP \fBSMARTD_ADDRESS\fP 4
is determined by the address argument ADD of the \'\-m\' Directive.
given by the argument ADD, with the commas replaced by spaces
(example:admin@example.com root). If more than one email address is
given, then this string will contain space characters and is NOT
-quoted, so to use it in a bash script you may want to enclose it in
+quoted, so to use it in a shell script you may want to enclose it in
double quotes.
.\" %IF OS Windows
.IP \fBSMARTD_ADDRCSV\fP 4
is set to the one sentence summary warning email message string from
\fBsmartd\fP.
This message string contains space characters and is NOT quoted. So to
-use $SMARTD_MESSAGE in a bash script you should probably enclose it in
+use $SMARTD_MESSAGE in a shell script you should probably enclose it in
double quotes.
.\" %IF NOT OS Windows
.IP \fBSMARTD_FULLMESSAGE\fP 4
is set to the contents of the entire email warning message string from
\fBsmartd\fP.
This message string contains space and return characters and is NOT quoted. So to
-use $SMARTD_FULLMESSAGE in a bash script you should probably enclose it in
+use $SMARTD_FULLMESSAGE in a shell script you should probably enclose it in
double quotes.
.\" %ENDIF NOT OS Windows
.\" %IF OS Windows
is a text string giving the time and date at which the first problem
of this type was reported. This text string contains space characters
and no newlines, and is NOT quoted. For example:
-.nf
-.fi
+.br
Sun Feb 9 14:58:19 2003 CST
.IP \fBSMARTD_TFIRSTEPOCH\fP 4
is an integer, which is the unix epoch (number of seconds since Jan 1,
.fi
that would normally be provided to \'mail\'. Examples include:
.nf
-.B -m user@home -M exec /bin/mail
+.B -m user@home -M exec /usr/bin/mail
.B -m admin@work -M exec /usr/local/bin/mailto
-.B -m root -M exec /Example_1/bash/script/below
+.B -m root -M exec /Example_1/shell/script/below
.fi
.\" %IF OS Windows
.B no
command-line arguments, for example:
.nf
-.B -m <nomailer> -M exec /Example_2/bash/script/below
+.B -m <nomailer> -M exec /Example_2/shell/script/below
.fi
If the executable produces any STDERR/STDOUT output, then \fBsmartd\fP
assumes that something is going wrong, and a snippet of that output
.\"! SMARTD_SUBJECT, SMARTD_FULLMSGFILE and SMARTD_ADDRCSV
.\" %ENDIF OS Windows
are set by the script before running the executable.
-
.TP
.B \-f
[ATA only] Check for \'failure\' of any Usage Attributes. If these
.I none
\- Assume that the device firmware obeys the ATA specifications. This
is the default, unless the device has presets for \'\-F\' in the
-drive database. Using this directive will over-ride any preset values.
+drive database. Using this directive will override any preset values.
.I nologdir
\- Suppresses read attempts of SMART or GP Log Directory.
.I 198,increasing
\- Raw Attribute number 198 (Offline Uncorrectable Sector Count) is not
-reset if uncorrectable sector are reallocated. This sets \'-U 198+\'
+reset if uncorrectable sectors are reallocated. This sets \'-U 198+\'
if no other \'-U\' directive is specified.
.TP
.B \-P TYPE
.nf
\fB
-#! /bin/bash
+#! /bin/sh
# Save the email message (STDIN) to a file:
cat > /root/msg
/usr/local/sbin/smartctl -a -d $SMART_DEVICETYPE $SMARTD_DEVICE >> /root/msg
# Now email the message to the user at address ADD:
-/bin/mail -s "$SMARTD_SUBJECT" $SMARTD_ADDRESS < /root/msg
+/usr/bin/mail -s "$SMARTD_SUBJECT" $SMARTD_ADDRESS < /root/msg
\fP
.fi
.nf
\fB
-#! /bin/bash
+#! /bin/sh
# 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... \'
-
+wall <<EOF
+Problem detected with disk: $SMARTD_DEVICESTRING
+Warning message from smartd is: $SMARTD_MESSAGE
+Shutting down machine in 30 seconds...
+EOF
+
# Wait half a minute
sleep 30
-
+
# Power down the machine
/sbin/shutdown -hf now
\fP
within the script, and a snippet of STDOUT/STDERR is logged to SYSLOG.
The remainder is flushed.
-.PP
-.SH AUTHORS
-\fBBruce Allen\fP
-.br
-University of Wisconsin \- Milwaukee Physics Department
-.br
-\fBChristian Franke\fP (Windows interface, C++ redesign, most enhancements
-since 2009)
-.br
-\fBsmartmontools\-support@lists.sourceforge.net\fP
-
-.PP
-.SH CONTRIBUTORS
-The following have made large contributions to smartmontools:
-.nf
-\fBCasper Dik\fP (Solaris SCSI interface)
-\fBDouglas Gilbert\fP (SCSI subsystem)
-\fBGuido Guenther\fP (Autoconf/Automake packaging)
-\fBGeoffrey Keating\fP (Darwin ATA interface)
-\fBEduard Martinescu\fP (FreeBSD interface)
-\fBFr\['e]d\['e]ric L. W. Meunier\fP (Web site and Mailing list)
-\fBGabriele Pohl\fP (Web site and Wiki, conversion from CVS to SVN)
-\fBKeiji Sawada\fP (Solaris ATA interface)
-\fBManfred Schwarb\fP (Drive database)
-\fBSergey Svishchev\fP (NetBSD interface)
-\fBDavid Snyder and Sergey Svishchev\fP (OpenBSD interface)
-\fBPhil Williams\fP (User interface and drive database)
-\fBShengfeng Zhou\fP (Linux/FreeBSD HighPoint RocketRAID interface)
-.fi
-Many other individuals have made smaller contributions and corrections.
-
-.PP
-.SH CREDITS
-.fi
-This code was derived from the smartsuite package, written by Michael
-Cornwell, and from the previous UCSC smartsuite package. It extends
-these to cover ATA-5 disks. This code was originally developed as a
-Senior Thesis by Michael Cornwell at the Concurrent Systems Laboratory
-(now part of the Storage Systems Research Center), Jack Baskin School
-of Engineering, University of California, Santa
-Cruz. \fBhttp://ssrc.soe.ucsc.edu/\fP .
-.SH
-HOME PAGE FOR SMARTMONTOOLS:
-.fi
-Please see the following web site for updates, further documentation, bug
-reports and patches: \fBhttp://smartmontools.sourceforge.net/\fP
+.\" %IF NOT OS Windows
+.SH FILES
+.TP
+.B /usr/local/etc/smartd.conf
+full path of this file.
-.SH
-SEE ALSO:
-\fBsmartd\fP(8), \fBsmartctl\fP(8), \fBsyslogd\fP(8),
-\fBsyslog.conf\fP(5), \fBbadblocks\fP(8), \fBide\-smart\fP(8), \fBregex\fP(7).
+.\" %ENDIF NOT OS Windows
+.SH SEE ALSO
+\fBsmartd\fP(8), \fBsmartctl\fP(8),
+\fBmail\fP(1), \fBregex\fP(7).
-.SH
-SVN ID OF THIS PAGE:
-$Id: smartd.conf.5.in 3741 2013-01-02 17:06:54Z chrfranke $
+.SH SVN ID OF THIS PAGE
+$Id: smartd.conf.5.in 3965 2014-07-20 14:46:41Z chrfranke $