TPMWatch is a support program designed to poll RAID subsystems and report their health to an output file. The file can then be used by a user-supplied program or shell script to provide notification in the event a component fails or goes offline. The program works by issuing commands to the controller to report status information for all LUNS, disk drives, and enclosure components (fans, power supplies, batteries, and so on).
To minimize performance impact, provide the greatest amount of flexibility to incorporate TPMWatch in external routines, the program is designed with the following considerations:
User-defined polling period (in seconds).
Generates only 11 I/Os.
User supplies the status file name upon invocation.
User supplies the optional history file name upon invocation.
The status file is pure ASCII text, so the result can easily be interpreted by a shell script.
To run TPMWatch, make sure the $DAM_HOME environment variable is set, and you invoke the program from root. The syntax is:
tpmwatch [-P Freq] [-C Freq] [-d] [-e] [-i] [-s] [-w] [-c] [-z] [-F HistFile] [-H HistFile] [-T LogFile] [-S StatusFile] -D DeviceFile [-M Addresses] [-L] [-N Name] [-Z [Hours]] (or) TPMWATCH -Z -D Device File |
Where:
-P Freq: Frequency in seconds between each poll
-C Freq: Frequency in hours to autosave configuration
-d: Enable debug mode to stderr
-Z Hours: Set the controller's clock and exit (requires -D option). If Hours is specified, set the controller's clock and exit every interval of Hours. For example, to set the clock and exit every four hours on a direct attached device on controller number 7, execute ./tpmwatch -Z 4 -D /hw/scsi/sc7d010
-z: Do NOT set the real time clock every polling interval
-e: Log and optionally e-mail error messages (requires 6.x FW or later)
-i: Log and optionally e-mail informational messages (requires 6.x FW or later)
-s: Log and optionally e-mail severe messages (requires 6.x FW or later)
-w: Log and optionally e-mail warning messages (requires 6.x FW or later)
-c: Log and optionally e-mail critical messages (requires 6.x FW or later)
-H HistFile: Optional event history file (obsolete in 7.x FW and later)
-F HistFile: Optional controller event log raw dump (requires 7.x FW or later)
-L: Send events to system log file.
-T LogFile: Sends error text to user-specified log file
-S StatusFile: Status file (obsolete in 7.x FW and later)
-N Name: For E-mail subject to distinguish between invocations.
-D DeviceFile: Raw device driver for a LUN on the subsystem
-M Addresses: E-mail addresses used to send alarm messages, separated by commas (for example: -M [email protected],[email protected]); the comma is required
-V: Display version number and exit
| Note: A minimum of two parameters must be specified, one of which must be DeviceFile. If only the DeviceFile parameter is specified, TPMWATCH will not start, and the syntax usage message will be reported. |