SNMP exporter not working for idrac power consumption OID

621 views
Skip to first unread message

Vinod kumar

unread,
Dec 12, 2019, 4:08:57 PM12/12/19
to Prometheus Users
Hi ,

I am trying to setup a prometheus metric to record the power consumption of dell server but the snmp exporter is not able to generate the metrics. I am able to perform a snmpwalk for this OID without any issue on the server where the exporter is installed.
Any help will be appreciated.


snmpwalk -v1 -c public hostname 1.3.6.1.4.1.674.10892.5.4.600.30.1.6.1.3
SNMPv2-SMI::enterprises.674.10892.5.4.600.30.1.6.1.3 = INTEGER: 198


snmp.yml
----------------------

dell:
  walk:
  - 1.3.6.1.4.1.674.10892.5.4.600.30.1.6.1.3
  metrics:
  - name: SystemPowerConsumption
    oid: 1.3.6.1.4.1.674.10892.5.4.600.30.1.6.1.3
    type: gauge
    help: This attribute defines the overall rollup status of all components in the system being monitored by the remote access card - 1.3.6.1.4.1.674.10892.5.2.1
  auth:
    community: test
    security_level: noAuthNoPriv
    auth_protocol: MD5
    priv_protocol: DES

Brian Candler

unread,
Dec 13, 2019, 4:37:05 AM12/13/19
to Prometheus Users
You are using two different authentication types there.

With snmpwalk you are using -v1 (SNMP version 1) and a community string "public"

In snmp.yml you haven't specified the SNMP version so it defaults to version 2.  You have also set a different community string.  You have also set some SNMP v3 options, although those shouldn't do anything if it's using SNMPv2.

Either way, you're definitely not comparing like with like.

Once you've fixed that, if you still don't get any result then you should run tcpdump or wireshark/tshark to look at the SNMP traffic generated by snmp_exporter and snmpwalk and see what's different between them.

Brian Candler

unread,
Dec 13, 2019, 5:19:34 AM12/13/19
to Prometheus Users
Also, test the exporter manually, before getting prometheus itself involved:


Does this give a response?  It may take 60 seconds before you get an error back.

Ben Kochie

unread,
Dec 13, 2019, 5:44:48 AM12/13/19
to Vinod kumar, Prometheus Users
That snmp.yml looks very funny. The help doesn't match the OID, and the  OID doesn't seem to have the same indexing as the MIB specifies.

When I put the correct data into a generator.yml, like this:

modules:
  dell_idrac:
    walk:
      - amperageProbeReading

I get this for the snmp.yml:

dell_idrac:
  walk:
  - 1.3.6.1.4.1.674.10892.5.4.600.30.1.6
  metrics:
  - name: amperageProbeReading
    oid: 1.3.6.1.4.1.674.10892.5.4.600.30.1.6
    type: gauge
    help: 0600.0030.0001.0006 This attribute defines the reading for an amperage probe
      of type other than amperageProbeTypeIsDiscrete - 1.3.6.1.4.1.674.10892.5.4.600.30.1.6
    indexes:
    - labelname: amperageProbechassisIndex
      type: gauge
    - labelname: amperageProbeIndex
      type: gauge


I highly recommend using the snmp_exporter generator to create your snmp.yml, otherwise it will be very error prone.

--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/dd3cc615-5760-422e-8b5f-a80674021b95%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages