Forum Discussion
I would use `apcaccess` from a collector via our Groovy Expect functionality. You'll of course have to also configure apcupsd to listen on something other than localhost.
You'll get a list of values like this:
DATE : Fri Dec 03 12:34:26 CET 1999
HOSTNAME : matou
RELEASE : 3.7.0-beta-1
CABLE : Custom Cable Smart
MODEL : SMART-UPS 1000
UPSMODE : Stand Alone
UPSNAME : UPS_IDEN
LINEV : 232.7 Volts
MAXLINEV : 236.6 Volts
MINLINEV : 231.4 Volts
LINEFREQ : 50.0 Hz
OUTPUTV : 232.7 Volts
LOADPCT : 11.4 Percent Load Capacity
BATTV : 27.7 Volts
BCHARGE : 100.0 Percent
MBATTCHG : 5 Percent
TIMELEFT : 112.0 Minutes
MINTIMEL : 3 Minutes
SENSE : Low
DWAKE : 060 Seconds
DSHUTD : 180 Seconds
LOTRANS : 204.0 Volts
HITRANS : 253.0 Volts
RETPCT : 050.0 Percent
STATFLAG : 0x08 Status Flag
STATUS : ONLINE
ITEMP : 29.2 C Internal
ALARMDEL : Low Battery
LASTXFER : U command or Self Test
SELFTEST : NO
STESTI : 336
DLOWBATT : 02 Minutes
DIPSW : 0x00 Dip Switch
REG1 : 0x00 Register 1
REG2 : 0x00 Register 2
REG3 : 0x00 Register 3
MANDATE : 01/05/99
SERIALNO : GS9902009459
BATTDATE : 01/05/99
NOMOUTV : 230.0
NOMBATTV : 24.0
HUMIDITY : N/A
AMBTEMP : N/A
EXTBATTS : 0
BADBATTS : N/A
FIRMWARE : 60.11.I
APCMODEL : IWI
END APC : Fri Dec 03 12:34:33 CET 1999
From there you can transform the values to pull out the extraneous text ("Volts", "Register 1", etc) and reprint it all to our Key/Value output standard, or you can write a few regexes for your datapoints to only pick out the good stuff (less clean, but less code).
http://www.apcupsd.org/manual/manual.html#monitoring-and-tuning-your-ups
I'm happy to put this in as an official DataSource request, but I won't have a timeline for you.
You might also checkout the output from the PowerShell script. It could be just a few simple tweaks to getting it working with LM.
Related Content
- 4 months ago
- 12 months ago
- 4 months ago
- 3 months ago