I have been messing with lm-sensors on one of my Linux boxes - to change the names to be a bit more descriptive / useful (e.g. in2 => +12V), and also to change the scaling factor … as some power supplies, like +12V and +5V, need a scaling factor (i.e. it87xx limits to ~ 3V input range). This all works fine, but … it’s not seen by LibreNMS. Is there a way to have the name change carry over (or at least be able to customize in LibreNMS), and also read across the scaling factor (as the voltages in LibreNMS are not correct - again, at least the ability to customize them in LibreNMS, on a per-client basis)?
One step even further would be for LibreNMS to use the custom alarm limits set up in lm-sensors.
Yep, that makes sense - and I’m guessing the same … it’s sending back values without the scaling / corrections from lm-sensors. I admin, not real sure of the interface that LibreNMS is using (not lm-sensors I assume?). Is there any info on this anywhere? I’m happy to dig into this more, see what I can do - but so far no real luck finding any info in it.
OK, I just checked this node (part of voltage in the MIB file),
.iso.org.dod.internet.private.enterprises.ucdavis.ucdExperimental.lmSensors.lmVoltSensorsTable
And the names and scaled voltages are there! So we have a chance … ;-). Could it be that I have to wipe out my sensor data, re-discover / re-load?
What do you mean it’s misaligned now? Any sensors which aren’t sent back by snmp will be removed so I expect the device is still sending all this data.
If you mean that you have two sensors then either the device is sending both sets of data or the OID and index is the same so the DB isn’t clearing out. SELECT * FROM sensors WHERE device_id=X; then just DELETE FROM SENSORS WHERE sensor_id=y; for duplicates.