DESCRIPTION
diskcheckd is a daemon which runs in the background, reading entire disks
to find any read errors on those disks. The disks which should be
scanned, and the rates at which they should be scanned, must be specified
in the configuration file, which is /usr/local/etc/diskcheckd.conf by
default.
Any blank lines or lines starting with a `#' character in this file are
ignored. Each non-comment line of this file must be in one of two for-
mats. The first format is `!xx', and specifies that device names match-
ing /dev/xx* should not be included in expansion of wildcards (see
below). The second format consists of four white space separated fields,
which are the full pathname of the disk device, the size of that disk,
the frequency in days at which to check that disk, and the rate in kilo-
bytes per second at which to check this disk. Naturally, it would be
contradictory to specify both the frequency and the rate, so only one of
these should be specified. Additionally, the size of the disk should not
be specified if the rate is specified, as this information is unneces-
sary.
If the disk is specified as ``*'', then diskcheckd will apply the given
settings to all disks in the system, obtained using the kern.disks sysctl
variable. If the size is specified as ``*'' (recommended), then the size
of the disk will be automatically determined from the disklabel, if pos-
sible. Fields which are not specified should contain a single ``*''
character.
Note that diskcheckd always reads data from the disk in 64KB blocks, so
the rate your specify may not be the exact rate at which the disk is
actually checked. Similarly, if you specify the third field (days for
complete scan) it is unlikely that a complete scan will actually take
exactly this many days.
To run diskcheckd automatically at boot time, the diskcheckd_enable vari-
able in rc.conf(5) should be set to ``YES''.
When diskcheckd receives a SIGTERM or SIGINT signal, it saves its current
state information to a file, so that after a reboot diskcheckd can resume
reading from where it left off, rather than starting from the beginning
of the disk again. The information saved to this file consists of the
device filename and the current offset into that device.
diskcheckd can be instructed to reload the configuration file by sending
it a SIGHUP signal.
diskcheckd accepts the following command line options:
-d If this flag is specified, diskcheckd will not fork into the
background and detach from its controlling terminal to become
a daemon. This flag is primarily used for debugging.
/dev/ad0 * 14 *
To check the first SCSI disk for errors at approximately 64KB/s, use the
following entry:
/dev/da0 * * 64
To check all disks once every four weeks:
* * 28 *
DIAGNOSTICS
If any errors occur, they will be written to syslogd(8).
HISTORY
diskcheckd first appeared in FreeBSD 5.0.
AUTHORS
diskcheckd and this manual page were written by Ben Smithurst
<ben@FreeBSD.org>, with input from Poul-Henning Kamp <phk@FreeBSD.org>.
BUGS
diskcheckd assumes all disks have 512 byte sectors.
BSD July 4, 2001 BSD
Man(1) output converted with
man2html