IEEE-754 numbers in SNMP

32 views
Skip to first unread message

Elliott Balsley

unread,
May 6, 2025, 3:28:31 AMMay 6
to Prometheus Users
I have a new device that reports its SNMP values as hex byte strings encoded using IEEE-754.
For example the value "423ce042" means 47.219.

This was proposed as a textual convention in RFC6340 but it’s the first time I’ve come across it.

As far as I can tell, snmp-exporter cannot decode this format. Would this be a worthwhile feature to add, or would I be better off writing a custom exporter for this device?

If you’re curious, the device is a cinema calibration tool from HSG Labs.


Brian Candler

unread,
May 6, 2025, 8:10:44 AMMay 6
to Prometheus Users
Just a thought, have you tried overriding "type: Float" or "type: Double"?  There are some examples in snmp.yml of this (but not generator.yml AFAICS)

    - name: upsInfoTemperature
      oid: 1.3.6.1.4.1.6574.4.2.11
      type: Float
      help: UPS temperature (degrees C) - 1.3.6.1.4.1.6574.4.2.11
Reply all
Reply to author
Forward
0 new messages