envd.1m (2010 09)
e
envd(1M) envd(1M)
NAME
envd - system physical environment daemon
SYNOPSIS
/usr/sbin/envd
[-f configfile ]
DESCRIPTION
The
envd daemon provides a means for the system to respond to environmental conditions detected by
hardware. Such responses are typically designed to maintain file system integrity and prevent data loss.
The environmental conditions currently recognized by
envd are over-temperature and chassis fan
failure.
envd logs messages and then executes actions when a supported environmental event is detected.
Whether to do message logging and what actions to perform for a given environmental event are deter-
mined by configfile (default is
/etc/envd.conf). If no
-f option was specified and the default
configfile
/etc/envd.conf
does not exist, envd fails. A recommended default configfile is available
in
/usr/newconfig/etc/envd.conf
. The configfile (or /etc/envd.conf
) is only examined
when the daemon is started or when it receives a
SIGHUP signal to restart and re-initialize the daemon
itself.
envd uses the syslog message logging facility to log warning messages. If configfile specifies messages
to be logged, the destination of the warning messages is determined by the configuration of the
LOG_DAEMON facility of the syslogd daemon (see syslogd (1M) and syslog (3C) for details) and various
syslog priorities defined below for the corresponding environmental events. Warning messages are
written to the console if envd is unable to send to syslogd.
The configfile is composed of event lines, each of which followed by zero or more action lines. Comment
lines can be interspersed at any point. No more than one event line can be specified for a given event.
Event Event lines consist of an event keyword and a message indicator, separated by a
colon (
:). Valid event keywords are OVERTEMP_CRIT
, OVERTEMP_EMERG,
FANFAIL_CRIT, and FANFAIL_EMERG
. Valid message indicators are y and n.
An example is
OVERTEMP_EMERG:y
, indicating that warning messages are to be
sent for the
OVERTEMP_EMERG
event.
Event keywords must start in the first column, and only one event and one message
indicator are allowed on a given line.
Action Action lines can consist of a sequence of any valid
/usr/bin/sh commands or
pipelines. Lines from one event line to the next event line, or to the end of the file,
are part of the action lines for the preceding event, and are passed intact to the
shell to execute upon detecting the event. The action for an event can span across
several lines, but the syntax of every line must be understood by /usr/bin/sh.
There are no default actions for any events if no action lines are specified.
No parsing or syntax checking is performed on the action lines; system administra-
tors are responsible for verifying the correctness of the action syntax.
Comments Lines beginning with the
# character in the first column are comment lines, and all
characters up to the subsequent new-line character are ignored.
Blank lines are ignored as comment lines.
Here is an example
/etc/envd.conf file:
# The example below configures envd to log the warning message and
# to rcp critical applications to a remote machine at OVERTEMP_CRIT
# or FANFAIL_CRIT. It configures envd to log emergency messages
# and to perform system shutdown at OVERTEMP_EMERG or FANFAIL_CRIT,
# in order to reserve data integrity.
OVERTEMP_CRIT:y
/usr/bin/rcp critical_appl_files \
remote_machine:/backup
OVERTEMP_EMERG:y
/usr/sbin/reboot -qh
HP-UX 11i Version 3: September 2010 − 1 − Hewlett-Packard Company 1