NUT tools and APC network management card - integration [SOLVED]

Hi All

I have an APC Smart 3000 with an AP9631 network card. I can access the webUI of the card and would now like to integrate this UPS into NUT tools on HA.

I tried adding to my config (below), changing the driver type to “snmp-ups”. The add-on starts but there appears to be lots of connecting/dis-connecting in the logs

Log

2916.067396	[D1] mainloop: UPS [Network-UPS] is now connected as FD -1
2916.067420	[D1] mainloop: UPS [Network-UPS] is not currently connected
2915.556170	Poll UPS [Network-UPS@localhost] failed - Driver not connected
2916.067437	[D1] mainloop: UPS [Network-UPS] is now connected as FD -1

When I try to “add a device” in the integration, I used “a0d7b954-nut” as the host
but get the following error when I select the “Network-UPS” device I want to add.

Connection error: Error running: LIST VAR Network-UPS: ERR DRIVER-NOT-CONNECTED

If I enter the IP address of the UPS in the host field, I get this error instead

Connection error: [Errno 111] Connect call failed ('192.168.20.81', 3493)

Config

- name: HA-CCTV-UPS
  driver: usbhid-ups
  port: auto
  config:
    - desc = HA-CCTV-UPS
    - serial = AS10XXXXXXXX
- name: NAS-UPS
  driver: usbhid-ups
  port: auto
  config:
    - desc = NAS-UPS
    - serial = 3S15XXXXXXXX
- name: Network-UPS
  driver: snmp-ups
  port: auto
  config:
    - desc = Network-UPS
    - serial = ZA18XXXXXXXX

Has anyone got this working and are there any changes I need to make on the management card to make this work?

Any help appreciated.

I have not used a network card, but from what I have read, it has its own IP address using SNMP, and doesn’t use USB. Your config will need to be more oriented to IP and SNMP version dependent parameters. Here is another Forum User’s config that may help.

@wmaker, thanks for the link, I had previously read that but for some reason it seemed to sink in better this time.

Think i’ve now managed to get all UPSs connected with a mixture of USB and Network card

For future readers

  • 2xSMT1000 APC (usb)
  • 1xSMT3000 APC (nmc)

Few things to note

  • Multiple USB connected UPss needs to have the serial number included and the port set to auto
  • Network card doesn’t like the serial number (YMMV) and the port is set to the IP address of the network card
  • Set a “desc”, it helps when choosing the UPS from the integration list
  • All UPSs had a hosst of a0d7b954-nut

Working config

- name: HA-CCTV-UPS
  driver: usbhid-ups
  port: auto
  config:
    - desc = HA-CCTV-UPS
    - serial = AS10XXXXXXXX

- name: NAS-UPS
  driver: usbhid-ups
  port: auto
  config:
    - desc = NAS-UPS
    - serial = 3S15XXXXXXXX

- name: Network-UPS
  driver: snmp-ups
  port: 192.168.20.81
  snmp_version: v3
  config:
    - desc = Network-UPS

Hi @sygad1

Tried your configuration but it looks like the snmp_version: v3 has been moved to the config section. For anyone else trying this with an APC NMC card (AP9630 - 9640 - 9617 for example) please take a look. I have the APC SURT1000RMXLI

To use the snmp v3 version at all we need the following attributes:

      - snmp_version = v3
      - secName = REPLACE_WITH_USERNAME

I recommend running it with MD5 and AES protocols with different passwords. Even though you probably have it running in a separate vlan locked down. You can also run this without password, just keep secName and snmp_version

For the SNMP driver references please see detailed documentation here: SNMP-UPS(8)

Here is my working config going directly to the APC NMC3 card AP9630 using SNMP v3

Working config

  - name: APC UPS
    driver: snmp-ups
    port: REPLACE_WITH_IP_ADDRESS
    config:
      - desc = APC NMC
      - snmp_version = v3
      - secName = REPLACE_WITH_USERNAME
      - authPassword = REPLACE_WITH_AUTHPASSWORD
      - privPassword = REPLACE_WITH_PRIVPASSWORD
      - authProtocol = MD5
      - privProtocol = AES
      - secLevel = authPriv