I knew I had seen this before: https://github.com/prometheus/snmp_exporter/issues/632
Is there anything in the web UI of the device that would indicate what a third column would be? Also, if you could pastebin a raw snmpwalk of the upper level battery packs OID: 1.3.6.1.4.1.318.1.1.1.2.3.10 That might give me a clue as to what the index should be. Otherwise, the only thing I can figure is the device output is broken in a weird way. On Mon, Nov 27, 2023 at 7:08 PM Neil Stottler <[email protected]> wrote: > So the walk for the working one, Smart-UPS 2200, with that same OID does > not return anything. That might be why that one is working. So now the > question on the newer models is how to get it so they can be working? > Remove that OID? > > root@server# snmpwalk -v1 -c public <ip> > 1.3.6.1.4.1.318.1.1.1.2.3.10.2.1.8 > root@server:# > On Monday, November 27, 2023 at 10:34:38 AM UTC-5 Ben Kochie wrote: > >> Do you have a walk for the working one as well? >> >> It looks like the device is returning more indexes than are valid for the >> MIB. The MIB declares two index values, but the snmpwalk is returning three. >> >> Compare the OIDs: >> >> 1.3.6.1.4.1.318.1.1.1.2.3.10.2.1.8 >> 1.3.6.1.4.1.318.1.1.1.2.3.10.2.1.8.1.1.1 >> >> You can see there are three index values before the string. >> >> Confirming with the MIB, there are only two entries in the INDEX. >> >> upsHighPrecBatteryPackEntry OBJECT-TYPE >> SYNTAX UPSHighPrecBatteryPackEntry >> ACCESS not-accessible >> STATUS mandatory >> DESCRIPTION^M >> "An entry containing information applicable to a >> particular battery pack." >> INDEX { upsHighPrecBatteryPackIndex, >> upsHighPrecBatteryCartridgeIndex } >> ::= { upsHighPrecBatteryPackTable 1 } >> >> Sounds like you will need to complain to APC that their firmware is >> buggy, or the MIB is invalid. They made a breaking change to the data >> definition or data. Can't tell which without asking them. >> >> On Mon, Nov 27, 2023 at 2:56 PM Neil Stottler <[email protected]> wrote: >> >>> According to the MIB in the snmp_exporter generator folder, 4.5.1. >>> >>> It's also worth noting, this isn't just >>> upsHighPrecBatteryPackCartridgeReplaceDate, it's 106 others as well. >>> I was cautious posting the whole thing here at once cause I didn't want >>> to post a wall of text as my first post. Here's the pastebin >>> https://pastebin.com/9trFyUG6 >>> >>> Here's the pastebin for the entire generated snmp.yml >>> https://pastebin.com/grCs0Kgx >>> >>> Here's the manual walk: >>> root@server:# snmpwalk -v1 -c public <IP> >>> 1.3.6.1.4.1.318.1.1.1.2.3.10.2.1.8 >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.1.1.1 = STRING: >>> "11/05/2025" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.1.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.2.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.2.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.3.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.3.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.4.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.4.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.5.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.5.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.6.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.6.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.7.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.7.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.8.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.8.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.9.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.9.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.10.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.10.1.2 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.11.1.1 = STRING: >>> "01/01/2000" >>> SNMPv2-SMI::enterprises.318.1.1.1.2.3.10.2.1.8.11.1.2 = STRING: >>> "01/01/2000" >>> >>> thanks for the help so far. >>> >>> On Wednesday, November 22, 2023 at 5:15:34 PM UTC-5 Ben Kochie wrote: >>> >>>> Can you find upsHighPrecBatteryPackCartridgeReplaceDate in your >>>> snmp.yml? What version of PowerNet-MIB do you have? >>>> >>>> This is what I get when I generate your config: >>>> - name: upsHighPrecBatteryPackCartridgeReplaceDate >>>> oid: 1.3.6.1.4.1.318.1.1.1.2.3.10.2.1.8 >>>> type: DisplayString >>>> help: The battery cartridge estimated battery replace date. - >>>> 1.3.6.1.4.1.318.1.1.1.2.3.10.2.1.8 >>>> indexes: >>>> - labelname: upsHighPrecBatteryPackIndex >>>> type: gauge >>>> - labelname: upsHighPrecBatteryCartridgeIndex >>>> type: gauge >>>> >>>> Can you provide a manual snmpwalk output of that OID >>>> (1.3.6.1.4.1.318.1.1.1.2.3.10.2.1.8`)? >>>> >>>> Since you're not dropping the source index on this, that should not >>>> produce duplicates. >>>> >>>> On Wed, Nov 22, 2023 at 11:06 PM Neil Stottler <[email protected]> >>>> wrote: >>>> >>>>> Hello! I am trying to scrap multiple APC UPS's on my network via >>>>> snmpv1, one works great, one does not work at all with this error. >>>>> 107 error(s) occurred: * collected metric >>>>> "upsHighPrecBatteryPackCartridgeReplaceDate" { >>>>> label:{name:"upsHighPrecBatteryCartridgeIndex" value:"1"} >>>>> label:{name:"upsHighPrecBatteryPackCartridgeReplaceDate" >>>>> value:"01/01/2000"} label:{name:"upsHighPrecBatteryPackIndex" value:"9"} >>>>> gauge:{value:1}} was collected before with the same name and label values >>>>> >>>>> here is my generator.yml config >>>>> --- >>>>> auths: >>>>> public_v1: >>>>> version: 1 >>>>> public_v2: >>>>> version: 2 >>>>> >>>>> modules: >>>>> # Default IF-MIB interfaces table with ifIndex. >>>>> if_mib: >>>>> walk: [sysUpTime, interfaces, ifXTable] >>>>> lookups: >>>>> - source_indexes: [ifIndex] >>>>> lookup: ifAlias >>>>> - source_indexes: [ifIndex] >>>>> # Uis OID to avoid conflict with PaloAlto PAN-COMMON-MIB. >>>>> lookup: 1.3.6.1.2.1.2.2.1.2 # ifDescr >>>>> - source_indexes: [ifIndex] >>>>> # Use OID to avoid conflict with Netscaler NS-ROOT-MIB. >>>>> lookup: 1.3.6.1.2.1.31.1.1.1.1 # ifName >>>>> overrides: >>>>> ifAlias: >>>>> ignore: true # Lookup metric >>>>> ifDescr: >>>>> ignore: true # Lookup metric >>>>> ifName: >>>>> ignore: true # Lookup metric >>>>> ifType: >>>>> type: EnumAsInfo >>>>> # Default IP-MIB with ipv4InterfaceTable for example. >>>>> ip_mib: >>>>> walk: [ipv4InterfaceTable] >>>>> >>>>> #snmpv2 mib >>>>> #hostresoruces mib >>>>> >>>>> # APC/Schneider UPS Network Management Cards >>>>> # >>>>> # Note: older management cards only support SNMP v1 (AP9606 and >>>>> # AP9607, possibly others). Older versions of the firmware may only >>>>> # support v1 as well. If you only have newer cards you can switch to >>>>> # version v2c or v3. >>>>> # >>>>> # The management cards have relatively slow processors so don't poll >>>>> # very often and give a generous timeout to prevent spurious >>>>> # errors. Alternatively you can eliminate the interface polling (OIDs >>>>> # beginning with 1.3.6.1.2.1) to reduce the time taken for polling. >>>>> # >>>>> # MIB: >>>>> https://download.schneider-electric.com/files?p_File_Name=powernet426.mib >>>>> # Guide: >>>>> http://www.apc.com/salestools/ASTE-6Z5QEY/ASTE-6Z5QEY_R0_EN.pdf >>>>> # Download site: http://www.apc.com/us/en/tools/download/index.cfm >>>>> apcups: >>>>> walk: >>>>> - 1.3.6.1.4.1.318.1.1.1.2 # upsBattery >>>>> - 1.3.6.1.4.1.318.1.1.1.3 # upsInput >>>>> - 1.3.6.1.4.1.318.1.1.1.4 # upsOutput >>>>> - 1.3.6.1.4.1.318.1.1.1.7.2 # upsAdvTest >>>>> - 1.3.6.1.4.1.318.1.1.1.8.1 # upsCommStatus >>>>> - 1.3.6.1.4.1.318.1.1.1.12 # upsOutletGroups >>>>> - 1.3.6.1.4.1.318.1.1.10.2.3.2 # iemStatusProbesTable >>>>> - 1.3.6.1.4.1.318.1.1.26.4.3 # rPDU2DeviceStatusTable >>>>> - 1.3.6.1.4.1.318.1.1.26.6.3 # rPDU2PhaseStatusTable >>>>> - 1.3.6.1.4.1.318.1.1.26.8.3 # rPDU2BankStatusTable >>>>> - 1.3.6.1.4.1.318.1.1.26.10.2.2 # >>>>> rPDU2SensorTempHumidityStatusTable >>>>> lookups: >>>>> - source_indexes: [upsOutletGroupStatusIndex] >>>>> lookup: upsOutletGroupStatusName >>>>> drop_source_indexes: true >>>>> - source_indexes: [iemStatusProbeIndex] >>>>> lookup: iemStatusProbeName >>>>> drop_source_indexes: true >>>>> overrides: >>>>> rPDU2BankStatusLoadState: >>>>> type: EnumAsStateSet >>>>> upsAdvBatteryCondition: >>>>> type: EnumAsStateSet >>>>> upsAdvBatteryChargingCurrentRestricted: >>>>> type: EnumAsStateSet >>>>> upsAdvBatteryChargerStatus: >>>>> type: EnumAsStateSet >>>>> >>>>> my snmp.yml is rather long so I can post that later on if someone has >>>>> an idea. >>>>> >>>>> -- >>>>> 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/1cd90fac-c4c2-413b-9509-278385346f51n%40googlegroups.com >>>>> <https://groups.google.com/d/msgid/prometheus-users/1cd90fac-c4c2-413b-9509-278385346f51n%40googlegroups.com?utm_medium=email&utm_source=footer> >>>>> . >>>>> >>>> -- >>> 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/c4c0a9b7-bc88-4495-b409-e4ef5710a067n%40googlegroups.com >>> <https://groups.google.com/d/msgid/prometheus-users/c4c0a9b7-bc88-4495-b409-e4ef5710a067n%40googlegroups.com?utm_medium=email&utm_source=footer> >>> . >>> >> -- > 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/f382c9be-7772-4d00-a0b0-0c0ce08e9cacn%40googlegroups.com > <https://groups.google.com/d/msgid/prometheus-users/f382c9be-7772-4d00-a0b0-0c0ce08e9cacn%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- 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/CABbyFmqG1DzU-B2NEy0-9mXKE-tEzEaSSP3MmQ1iY%2B5vOmaRwQ%40mail.gmail.com.

