On Friday, February 27, 2015 7:05 AM, David Hauck wrote:
> Hi,
> 
> I'd like to leverage the agent's "override" configuration directive to
> implement custom control of the IP-MIB::ifAlias values. The agent
> target has its own "aliases" for the standard interface names, for e.g., 
> "Interface 1"
> might be an alias for "eth0". It's easy to hardcode this information
> in the agent's configuration file:
> 
> # IF-MIB::ifAlias.4
> override override 1.3.6.1.2.1.31.1.1.1.18.4 octet_str "Interface 1"
> 
> The issue I'm having is how to dynamically determine the ifAlias
> instances and then to add these to the configuration file. Ideally,
> I'd like to determine this from my AgentX sub-agent that's running on
> the agent target, but I don't believe there's any equivalent to a
> programmatic get request from the sub to the master (i.e., to retrieve
> ifNumber and then to query the set of ifAlias.x values). Is this
> correct? I can't rely on running any of the client-based shell
> applications (snmpget, snmpwalk, etc.) on the target (to retrieve this
> information) as there may be no known MIB access available to these
> clients (i.e., no community based access and no access to any v3 user 
> passphrases).
> 
> Of course I could try to mimic the heuristic that the master uses to
> enumerate the interfaces and construct the if[X]Table, but that seems
> like cheating (and also results in far too much coupling for my liking).
> 
> I'm hoping someone might have some ideas for how to do this?

Just a quick follow-up on this in case anyone was wondering where this landed. 
I ended up going the "duplicate the implementation of the agent's interface 
enumeration logic" route and this works fine for now. Unfortunately I wasn't 
able to come up with a more interactive approach between the agent and it's sub 
to provide this information more dynamically (conversations of this type are 
just not supported via the agentx protocol).

The only somewhat unsettling side effect is the presence of the following error 
messages in the log whenever the agent is restarted (via -HUP) and the 
"override IF-MIB::ifAlias.3 octet_str "Interface 0"" lines (there are six of 
these in my current case) are present in the snmpd.conf file:

duplicate registration: MIB modules IF-MIB::ifAlias.1 and IF-MIB::ifAlias.1 
(oid .1.3.6.1.2.1.31.1.1.1.18.1).
/etc/snmp/snmpd.conf: line 69: Error: oid registration failed within the agent
duplicate registration: MIB modules IF-MIB::ifAlias.2 and IF-MIB::ifAlias.2 
(oid .1.3.6.1.2.1.31.1.1.1.18.2).
/etc/snmp/snmpd.conf: line 70: Error: oid registration failed within the agent
duplicate registration: MIB modules IF-MIB::ifAlias.3 and IF-MIB::ifAlias.3 
(oid .1.3.6.1.2.1.31.1.1.1.18.3).
/etc/snmp/snmpd.conf: line 71: Error: oid registration failed within the agent
duplicate registration: MIB modules IF-MIB::ifAlias.4 and IF-MIB::ifAlias.4 
(oid .1.3.6.1.2.1.31.1.1.1.18.4).
/etc/snmp/snmpd.conf: line 72: Error: oid registration failed within the agent
duplicate registration: MIB modules IF-MIB::ifAlias.5 and IF-MIB::ifAlias.5 
(oid .1.3.6.1.2.1.31.1.1.1.18.5).
/etc/snmp/snmpd.conf: line 73: Error: oid registration failed within the agent
duplicate registration: MIB modules IF-MIB::ifAlias.6 and IF-MIB::ifAlias.6 
(oid .1.3.6.1.2.1.31.1.1.1.18.6).
 
I'm assuming these are benign?

-David

------------------------------------------------------------------------------
BPM Camp - Free Virtual Workshop May 6th at 10am PDT/1PM EDT
Develop your own process in accordance with the BPMN 2 standard
Learn Process modeling best practices with Bonita BPM through live exercises
http://www.bonitasoft.com/be-part-of-it/events/bpm-camp-virtual- event?utm_
source=Sourceforge_BPM_Camp_5_6_15&utm_medium=email&utm_campaign=VA_SF
_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to