notes:zabbix-apcupsd-without-snmp
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
notes:zabbix-apcupsd-without-snmp [2014/08/29 10:48] – created admin | notes:zabbix-apcupsd-without-snmp [2014/09/06 17:37] (current) – admin | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Zabbix: Monitor an APC UPS with apcupsd (no SNMP required) | ====== Zabbix: Monitor an APC UPS with apcupsd (no SNMP required) | ||
- | UserParameter | + | Monitoring an APC UPS without snmp is not so difficult. If you are already using the '' |
- | /etc/zabbix/zabbix_agentd.conf | + | This is my configuration of '' |
- | UserParameter=apcupsd.linev,awk < / | + | ## apcupsd.conf v1.1 ## |
- | UserParameter=apcupsd.loadpct,awk < / | + | |
- | UserParameter=apcupsd.battcharge, | + | UPSCABLE ether |
- | UserParameter=apcupsd.timeleft,awk < / | + | UPSTYPE pcnet 1.2.3.4:apc |
- | UserParameter=apcupsd.battv, | + | DEVICE |
+ | | ||
+ | UPSCLASS standalone | ||
+ | | ||
+ | |||
+ | POLLTIME 60 | ||
+ | ONBATTERYDELAY 15 | ||
+ | |||
+ | # BATTERYLEVEL, MINUTES, and TIMEOUT work in conjunction, | ||
+ | # the first that occurs will cause the initation of a shutdown. | ||
+ | | ||
+ | MINUTES 5 | ||
+ | TIMEOUT 0 #set it to 0 for SmartUPS devices | ||
+ | |||
+ | STATTIME 50 | ||
+ | STATFILE | ||
+ | LOGSTATS off | ||
+ | DATATIME 0 | ||
+ | As you can see in the config file, the UPS status is dumped every 50 seconds within the ''/ | ||
+ | The status of the UPS can be seen with the '' | ||
- | / | + | APC : 001, |
- | ## apcupsd.conf v1.1 ## | + | |
- | UPSNAME SmartUPS5000 | + | HOSTNAME : faxserver |
- | UPSCABLE ether | + | VERSION |
- | UPSTYPE pcnet 192.168.0.220:apc | + | UPSNAME |
- | DEVICE | + | |
- | LOCKFILE | + | |
- | UPSCLASS standalone | + | UPSMODE |
- | UPSMODE disable | + | STARTTIME: 2014-04-23 10:14:44 +0200 |
+ | STATUS | ||
+ | LINEV : 229.3 Volts | ||
+ | LOADPCT | ||
+ | BCHARGE | ||
+ | TIMELEFT : 37.0 Minutes | ||
+ | MBATTCHG | ||
+ | | ||
+ | | ||
+ | MAXLINEV : 229.3 Volts | ||
+ | MINLINEV : 229.3 Volts | ||
+ | OUTPUTV | ||
+ | DWAKE : 010 Seconds | ||
+ | DSHUTD | ||
+ | DLOWBATT : 02 Minutes | ||
+ | LOTRANS | ||
+ | HITRANS | ||
+ | RETPCT | ||
+ | ITEMP : 23.0 C Internal | ||
+ | ALARMDEL : Always | ||
+ | BATTV : 218.4 Volts | ||
+ | LINEFREQ : 50.0 Hz | ||
+ | LASTXFER : Automatic or explicit self test | ||
+ | NUMXFERS : 30 | ||
+ | XONBATT | ||
+ | TONBATT | ||
+ | CUMONBATT: 174 seconds | ||
+ | XOFFBATT : 2014-08-23 15:11:43 +0200 | ||
+ | LASTSTEST: 2014-08-23 15:11:35 +0200 | ||
+ | SELFTEST : OK | ||
+ | STESTI | ||
+ | STATFLAG : 0x07000008 Status Flag | ||
+ | REG1 : 0x00 Register 1 | ||
+ | REG2 : 0x00 Register 2 | ||
+ | REG3 : 0x00 Register 3 | ||
+ | MANDATE | ||
+ | | ||
+ | | ||
+ | NOMOUTV | ||
+ | EXTBATTS : 0 | ||
+ | FIRMWARE : 5.1 (ID5) | ||
+ | APCMODEL : Smart-UPS RT-5000 XL-1 | ||
+ | END APC : 2014-08-29 13:49:30 +0200 | ||
- | POLLTIME 60 | + | We are interested in line/ |
- | ONBATTERYDELAY 15 | + | With '' |
+ | On the host that runs zabbix_agentd, | ||
- | # BATTERYLEVEL, MINUTES, and TIMEOUT work in conjunction, so | + | UserParameter=apcupsd.linev,awk < / |
- | # the first that occurs will cause the initation of a shutdown. | + | UserParameter=apcupsd.loadpct,awk < / |
- | BATTERYLEVEL 10 | + | UserParameter=apcupsd.battcharge,awk < / |
- | MINUTES 5 | + | |
- | TIMEOUT 0 #set it to 0 for SmartUPS devices | + | |
- | STATTIME 50 | + | and restart the zabbix_agent. |
- | STATFILE | + | |
- | LOGSTATS off | + | In the Zabbix web interface |
- | DATATIME 0 | + | - Install the zbx_apcupsd_template.xml (it has 5 items and 2 triggers for generating Power Down and Low Battery alerts) ([[http://pastebin.com/raw.php? |
+ | - Add the " |
notes/zabbix-apcupsd-without-snmp.1409309292.txt.gz · Last modified: 2014/08/29 10:48 by admin