On Tue, 10 Nov 2020 at 00:37, BenB <[email protected]> wrote: > Hi everyone, > > I'm trying to setup the snmp-exporter to poll a Checkpoint Maestro > appliance for system stats. I'm starting small, hitting a single OID, > asgCoreIndex OID which returns a string index with the name of each cpu > core. I can do a walk on this OID with snmpwalk and it returns the > following: > > snmpwalk -On -v3 -u <redacted> -l authPriv -a SHA -A <redacted> -x AES -X > <redacted> 1.2.3.4 asgCoreIndex > .1.3.6.1.4.1.2620.1.48.29.1.1.1.0 = STRING: Blade ID > .1.3.6.1.4.1.2620.1.48.29.1.1.2.0 = STRING: cpu0 > .1.3.6.1.4.1.2620.1.48.29.1.1.3.0 = STRING: cpu1 > .1.3.6.1.4.1.2620.1.48.29.1.1.4.0 = STRING: cpu2 > .1.3.6.1.4.1.2620.1.48.29.1.1.5.0 = STRING: cpu3 > .1.3.6.1.4.1.2620.1.48.29.1.1.6.0 = STRING: cpu4 > .1.3.6.1.4.1.2620.1.48.29.1.1.7.0 = STRING: cpu5 > .1.3.6.1.4.1.2620.1.48.29.1.1.8.0 = STRING: cpu6 > .1.3.6.1.4.1.2620.1.48.29.1.1.9.0 = STRING: cpu7 > .1.3.6.1.4.1.2620.1.48.29.1.1.10.0 = STRING: cpu8 > .1.3.6.1.4.1.2620.1.48.29.1.1.11.0 = STRING: cpu9 > .1.3.6.1.4.1.2620.1.48.29.1.1.12.0 = STRING: cpu10 > .1.3.6.1.4.1.2620.1.48.29.1.1.13.0 = STRING: cpu11 > .1.3.6.1.4.1.2620.1.48.29.1.1.14.0 = STRING: cpu12 > .1.3.6.1.4.1.2620.1.48.29.1.1.15.0 = STRING: cpu13 > .1.3.6.1.4.1.2620.1.48.29.1.1.16.0 = STRING: cpu14 > .1.3.6.1.4.1.2620.1.48.29.1.1.17.0 = STRING: cpu15 > .1.3.6.1.4.1.2620.1.48.29.1.1.18.0 = STRING: cpu16 > .1.3.6.1.4.1.2620.1.48.29.1.1.19.0 = STRING: cpu17 > .1.3.6.1.4.1.2620.1.48.29.1.1.20.0 = STRING: cpu18 > .1.3.6.1.4.1.2620.1.48.29.1.1.21.0 = STRING: cpu19 > > > Hitting the same OID with snmp-exporter shows what I assume are > non-printable characters in the label for asgCoreIndex: > > # HELP asgCoreIndex - 1.3.6.1.4.1.2620.1.48.29.1.1 > # TYPE asgCoreIndex gauge > asgCoreIndex{asgCoreIndex="�"} 1 > asgCoreIndex{asgCoreIndex="��"} 1 > asgCoreIndex{asgCoreIndex="���"} 1 > asgCoreIndex{asgCoreIndex="����"} 1 > asgCoreIndex{asgCoreIndex="�����"} 1 > asgCoreIndex{asgCoreIndex="������"} 1 > asgCoreIndex{asgCoreIndex="�������"} 1 > asgCoreIndex{asgCoreIndex="��������"} 1 > asgCoreIndex{asgCoreIndex="���������"} 1 > asgCoreIndex{asgCoreIndex="����������"} 1 > asgCoreIndex{asgCoreIndex="�����������"} 1 > asgCoreIndex{asgCoreIndex="������������"} 1 > asgCoreIndex{asgCoreIndex="�������������"} 1 > asgCoreIndex{asgCoreIndex="��������������"} 1 > asgCoreIndex{asgCoreIndex="���������������"} 1 > asgCoreIndex{asgCoreIndex="����������������"} 1 > asgCoreIndex{asgCoreIndex="�����������������"} 1 > asgCoreIndex{asgCoreIndex="������������������"} 1 > asgCoreIndex{asgCoreIndex="�������������������"} 1 > asgCoreIndex{asgCoreIndex="��������������������"} 1 > asgCoreIndex{asgCoreIndex="���������������������"} 1 > # HELP snmp_scrape_duration_seconds Total SNMP time scrape took (walk and > processing). > # TYPE snmp_scrape_duration_seconds gauge > snmp_scrape_duration_seconds 0.097737986 > # HELP snmp_scrape_pdus_returned PDUs returned from walk. > # TYPE snmp_scrape_pdus_returned gauge > snmp_scrape_pdus_returned 21 > # HELP snmp_scrape_walk_duration_seconds Time SNMP walk/bulkwalk took. > # TYPE snmp_scrape_walk_duration_seconds gauge > snmp_scrape_walk_duration_seconds 0.097562665 > > my generator.yml file : > > modules: > # Maestro CPU > maestro_cpu: > auth: > username: <redacted> > security_level: authPriv > password : <redacted> > auth_protocol: SHA > priv_protocol: AES > priv_password: <redacted> > version: 3 > walk: > - asgCoreIndex > > produces the following snmp.yml file: > > # WARNING: This file was auto-generated using snmp_exporter generator, > manual changes will be lost. > maestro_cpu: > walk: > - 1.3.6.1.4.1.2620.1.48.29.1.1 > metrics: > - name: asgCoreIndex > oid: 1.3.6.1.4.1.2620.1.48.29.1.1 > type: DisplayString > help: ' - 1.3.6.1.4.1.2620.1.48.29.1.1' > indexes: > - labelname: asgCoreIndex > type: DisplayString > version: 3 > auth: > security_level: authPriv > username: <redacted> > password: <redacted> > auth_protocol: SHA > priv_protocol: AES > priv_password: <redacted> > > the debug logs don't appear to indicate any issues: > level=debug ts=2020-11-10T00:19:37.688Z caller=main.go:99 > module=maestro_cpu target=1.2.3.4 msg="Starting scrape" > level=debug ts=2020-11-10T00:19:37.688Z caller=collector.go:164 > module=maestro_cpu target=1.2.3.4 msg="Walking subtree" > oid=1.3.6.1.4.1.2620.1.48.29.1.1 > level=debug ts=2020-11-10T00:19:37.783Z caller=collector.go:177 > module=maestro_cpu target=1.2.3.4 msg="Walk of subtree completed" > oid=1.3.6.1.4.1.2620.1.48.29.1.1 duration_seconds=94.396128ms > level=debug ts=2020-11-10T00:19:37.788Z caller=main.go:110 > module=maestro_cpu target=1.2.3.4 msg="Finished scrape" > duration_seconds=0.099797031 > > I'm a newbie when it comes to prometheus - any ideas why I'm not getting > the expected response? >
Can you share the MIB? Based on the output I'd guess the index is wrong. -- Brian Brazil www.robustperception.io -- 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 [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/CAHJKeLqsaA-tJzCtEb3sddYPoM1pugS%2BUk_Hrh75%3D-r%2B3pXkjg%40mail.gmail.com.

