UPS monitoring with collectd
Well, since the UPS was hooked up yesterday, after work today I decided to see about configuring the Network Management Card I bought for it properly. I still had it set up on the temporary VLAN so I could connect to it, so I switched it onto the home VLAN and power-cycled the NMC to force it to pick up the correct IP, and made sure it had DNS.
Next, I set up the credentials on it, as it was set to the default admin/admin which is less than fortunate. I configured ntp, snmp (read-only), and had a look at SSL but I couldn’t work out how to make it work without risking locking myself out. Hmm, I can use SSH as a backup right? Nope, this thing is so old that the modern OpenSSH client on my Mac refuses to negotiate with it. That’s easily fixed with a small config change:
Host ups.fwaggle.org
KexAlgorithms diffie-hellman-group1-sha1
Ciphers aes128-cbc
Now I can connect to it two ways, so I can have a go at setting up SSL on it, but I haven’t yet.
Instead, I got sidetracked by adding the SNMP configuration to my collectd container. It seems I can’t actually monitor the current (which sucks, I was very interested to see what the whole rack draws), but I can monitor the load, the battery, and the input voltage which is good enough for me.
Spent a little time adding a new entry to the configuration for my rrdraw
program et voila, I have a nice shiny graph showing the input AC, the battery voltage, battery percent, and load percent.
I then decided to test this, and the highly suspect “estimated run time”, so I switched the power off at the wall and waited. I watched the graph for about 40 minutes, and the battery got as low as 66%, or 73VDC. That’s good enough for me, I don’t need to run the battery all the way down to guess it’s still got some juice in it.