ENTITY-STATE-MIB.entPhysicalDescr - add description field to allow matching and alerting

Hi, I’m trying to figure out how to trigger alert for Arista switches based on entStateOper value.
It would be good to add a column during discovery with description copied from entPhysicalDescr that would allow to match on the entity description (like PSU).

Also the polling script would need to walk entStateOper tree so the alert rule could cross-match on the operational status from the last polling.

Many thanks, MatK

entPhysicalDescr is already collected so you can probably do that already.

Yep. You can put as many mib file you like in the YAML file.
mib: BLAH1-MIB:BLAH2-MIB

You can even take an OID by specifying the MIB into the OID name, like in includes/definitions/discovery/zynos.yaml or in includes/definitions/discovery/moxa-etherdevice.yaml.

This sounds really promising. For some reason however the entPhysicalDescr values from the second MIB don’t get resolved for me. What I’m trying to achieve is to merge the information from two mibs, using the same $index variable.

mib: ENTITY-STATE-MIB:ENTITY-MIB
modules:
    sensors:
        state:
            data:
                -
                    oid: entStateOper
                    num_oid: '.1.3.6.1.2.1.131.1.1.1.3.{{ $index }}'
                    descr: 'ENTITY-MIB::entPhysicalDescr.{{ $index }}'

Restult:
[sensor_oid] => .1.3.6.1.2.1.131.1.1.1.3.100721000
[sensor_descr] => ENTITY-MIB::entPhysicalDescr.100721000
[sensor_type] => entStateOper

I’d appreciate any hints. I might be overlooking something obvious. Many thanks.

I just found some example using pre-caching to address exactly the same scenario. It worked like a charm. Thank you for your help!

Exactly, that’s the way to go ! You found it.