Application DHCP Stats Client Agent is deprecated

Hello, I am trying to setup DHCP polling per the configuration guide, using the snmp extend capabilities as listed here:
https://docs.librenms.org/Extensions/Applications/
upon enabling the application, I get a notification that: Application enabled by user: dhcp-stats
However, upon a page refresh, it states that:
Application DHCP Stats Client Agent is deprecated, and all graphs produce a draw error. I;m looking to see if it’s truly deprecated, and I should get info, or if it’s deprecated, and I should not be attempting the application with extend snmp? What does LibreNMS suggest for getting dhcp-stats out of CentOS 8 Server running ISC-dhcpd? Thank you

hi and welcome to community,
are you using dhcp.py or the deprecated dhcp agent shell script?

Hi! Thank you for the warm welcome! I am using the dhcp.py script

I am getting the same message, and I am also using the dhcp.py as per the documentation here.

Any solution to this?

Hi SourceDoctor,
Do you have any ideas or suggestions about the dhcp.py script? Thank you for the help!

is the dhcp shellscript still present? If so, delete it and adjust your snmp configuration to use dhcp.py

I ran into this issue on my opnsense box and it was a combination of a few different problems:

  1. opnsense doesn’t have dhcpd-pools installed, I had to install it manually from ports
  2. Scripts run as snmp extensions not including /usr/local/{bin,sbin} in PATH so /usr/bin/env wasn’t finding python3 (this had silently broken the unbound script as well because it couldn’t find unbound-control)
  3. Bug: dhcp.py ignores the leasefile in dhcp.py when constructing the dhcpd-pools command: https://github.com/librenms/librenms-agent/blob/master/snmp/dhcp.py#L68

I didn’t dig into the php to understand why it was giving the wrong error because I don’t really know php, but my guess is that the json parsing isn’t strict enough so $dhcp_data[‘version’]; grabbed a version from something else in the snmp response

This topic was automatically closed 730 days after the last reply. New replies are no longer allowed.