[Nut-upsdev] New snmp-ups subdriver for Huawei
clepple at gmail.com
Sun Mar 29 00:02:35 UTC 2015
On Mar 25, 2015, at 9:21 PM, Stuart Henderson <stu at spacehopper.org> wrote:
> Hi, the diff inline below adds a new subdriver for snmp-ups to support
> Huawei UPS, based on an observed walk from a UPS5000-E with a few bits
> filled in from the MIBs (copy at http://junkpile.org/HUAWEI_UPS_MIB/).
> Sample output from upsc follows the diff.
Thanks for the patch. It builds cleanly for me, so I have no problems merging it.
The only two things that jump out at me could probably be addressed with documentation. Is there a low battery alarm? If not, we should probably mention somewhere that people will need to either synthesize a LB status with one or both of 'override.battery.charge.low' and 'override.battery.runtime.low'. (Or they can shut down when it first transfers to battery, but this sounds like the sort of UPS that would keep going for a while.)
There also seem to be a few commands in the MIB, but none are implemented here. The only ones that people might be expecting are the shutdown.reboot and shutdown.stayoff, although I haven't used the SNMP driver to see how well those work in general. Not strictly necessary to implement, but we should probably take this opportunity to point out in the snmp-ups man page that if there are no shutdown.* commands listed in the upscmd output, there is a potential for a race condition if the power comes back early.
Arnaud, as maintainer of snmp-ups, any thoughts here?
clepple at gmail
More information about the Nut-upsdev