Conteg PDU power sensors divisor resets to 100 after rediscover

Hi,

I have Conteg PDUs monitored as OS “conteg-pdu”.
The power sensors show wrong values (0.9W instead of 90W) because
LibreNMS sets sensor_divisor=100 automatically during discovery.

LibreNMS version: 26.4.1-dev
DB Schema: 376
PHP: 8.3.6
Database: MariaDB 10.11.14

What I have already tried:

  1. Created /opt/librenms/includes/definitions/discovery/conteg-pdu/sensors.yaml
    with divisor: 1 - but resets to 100 after every rediscover.

  2. Manual SQL update:
    UPDATE sensors SET sensor_divisor=1 WHERE sensor_class=‘power’;
    This works but resets after every rediscover.

The divisor=100 seems to come from the CONTEG-DATABUS-MIB during
generic MIB discovery. How can I permanently override this?

Discovery debug output:
https://paste.rs/duFc0

You should just send a pull request to make the change for everyone, then you don’t have to worry about local changes.

Hi, I submitted a pull request: Fix incorrect power sensor divisor for Conteg PDU devices. by CCAkoutsio · Pull Request #19355 · librenms/librenms · GitHub, thanks