querying two different SNMP agents at port 161 - SNMP

This is a discussion on querying two different SNMP agents at port 161 - SNMP ; Hello SNMP-newsgrouper, We are currently faced to the following problem. We have two (master) agents: a standard agent delivered with Tru64, and our own agent (starting at .enterprises.16455). Both agents are working on a set of disjunct OIDs. For some ...

+ Reply to Thread
Results 1 to 13 of 13

Thread: querying two different SNMP agents at port 161

  1. querying two different SNMP agents at port 161

    Hello SNMP-newsgrouper,

    We are currently faced to the following problem. We have two (master)
    agents: a standard agent delivered with Tru64, and our own agent
    (starting at .enterprises.16455). Both agents are working on a set of
    disjunct OIDs. For some reason I won't detail here, we would need to
    query both agents on the standard 161 port. Of course, we can't run
    both agents at port 161 simultaneously...

    I have the following idea: we could be to have a kind of "proxy" (I
    don't know if the term is appropriate) running at port 161. The
    standard agent would run for instance at port 1161, and our agent at
    port 2161. When a request is received for .enterprises.16455, the proxy
    would forward the request to our agent (running at port 2161), and
    forward its answer back to the issuer of the snmp command. Otherwise,
    it would forward the request to the standard agent (running at port
    1161), and forward its answer back.

    Before I re-invent the (possibly broken) wheel, are such kind of "SNMP
    proxy" already available?

    Or perhaps, there are simpler solutions to the problem?


    regards,
    Loic.


  2. Re: querying two different SNMP agents at port 161

    I wouldnt think quite in terms of a "SNMP proxy" what you should think
    is a UDP proxy. i.e. something like this:
    http://www.geocities.com/SiliconVall...a/8155/uproxy/, that is for
    windows but you get the idea. There might also be a solution with some
    fancy *nix connection tricks but I would not know what they are off the
    top of my head. When you say "our" agent do you mean your company
    coded it? If so why dont you have somebody redevlop it and add the
    ability to listen on another port? From a coding perspective this in
    most circumstances would be relatively easy.

    -Ryan

    loic-dev@gmx.net wrote:
    > Hello SNMP-newsgrouper,
    >
    > We are currently faced to the following problem. We have two (master)
    > agents: a standard agent delivered with Tru64, and our own agent
    > (starting at .enterprises.16455). Both agents are working on a set of
    > disjunct OIDs. For some reason I won't detail here, we would need to
    > query both agents on the standard 161 port. Of course, we can't run
    > both agents at port 161 simultaneously...
    >
    > I have the following idea: we could be to have a kind of "proxy" (I
    > don't know if the term is appropriate) running at port 161. The
    > standard agent would run for instance at port 1161, and our agent at
    > port 2161. When a request is received for .enterprises.16455, the

    proxy
    > would forward the request to our agent (running at port 2161), and
    > forward its answer back to the issuer of the snmp command. Otherwise,
    > it would forward the request to the standard agent (running at port
    > 1161), and forward its answer back.
    >
    > Before I re-invent the (possibly broken) wheel, are such kind of

    "SNMP
    > proxy" already available?
    >
    > Or perhaps, there are simpler solutions to the problem?
    >
    >
    > regards,
    > Loic.



  3. Re: querying two different SNMP agents at port 161

    Hi Ryan,

    > I wouldnt think quite in terms of a "SNMP proxy" what you should
    > think is a UDP proxy. i.e. something like this:
    > http://www.geocities.com/SiliconVall...a/8155/uproxy/,
    > that is for windows but you get the idea.


    UDP proxy won't do it here. It has to understand the SNMP protocol,
    because depending on the OID accessed, it must forward to the
    appropriate agent.


    > When you say "our" agent do you mean your company coded it?


    Yes.


    > If so why dont you have somebody redevlop it and add the ability
    > to listen on another port? From a coding perspective this in
    > most circumstances would be relatively easy.


    We can already listen to any port we like (or at least, any port that
    is free). That's not the problem.

    The problem is that the two agents are two different UNIX processes
    written in two different languages. The department that coded the SNMP
    manager is unable (or doesn't want) to query on another port that the
    standard port 161. The SNMP manager must query information provided by
    the Tru64 Agent (like FDDI interface status), as well information
    provided by our Agent.

    Of course, we could rewrite our agent from scratch and integrate it in
    the Tru64 agent. Or rewrite the Tru64 agent from scratch and integrate
    in our agent. But that's not an option for us.


    Cheers,
    Loic.


  4. Re: querying two different SNMP agents at port 161

    Ok I see, so you have inflexibility in your agent and your manager, eg.
    both poor coding and bad planning, not the first time I have seen it...
    I am not sure if there is an easy solution for that. A process that
    translates the udp octets to oid information and decides what port to
    hit based on value... It is for sure in the "can be done" category
    however it would have to be custom coded.

    You could also do like I have previsously stated, just change the Tru64
    snmp port (assuming they were smart and put the ability in like most
    snmp agents) and setup the UDP proxy either on another box or on
    another ip/nic and push queries from there, it would be a funky manager
    setup but it would work, as you would need to configure multiple ips
    per box, pain... It is a solution albeit not an elegant one.

    Best,
    Ryan


  5. Re: querying two different SNMP agents at port 161

    Hello Ryan,

    > Ok I see, so you have inflexibility in your agent and your manager,

    eg.
    > both poor coding and bad planning, not the first time I have seen

    it...

    Oh, the truth is even worse, actually...

    > You could also do like I have previsously stated, just change the

    Tru64
    > snmp port (assuming they were smart and put the ability in like most
    > snmp agents) and setup the UDP proxy either on another box or on
    > another ip/nic and push queries from there, it would be a funky

    manager
    > setup but it would work, as you would need to configure multiple ips
    > per box, pain... It is a solution albeit not an elegant one.


    This won't work, I am afraid... The SNMP Manager queries multiple
    systems (hence, effectively multiple IP-Address). But each system must
    have an unique entry point. That is, an unique IP-Address to talk to.
    Having multiple IP-Address per system is prohibited.

    I know that's weierd. But it is unfortunately the reality we're faced
    to.


    Regards,
    Loic.


  6. Re: querying two different SNMP agents at port 161

    loic-dev@gmx.net wrote:
    > I have the following idea: we could be to have a kind of "proxy"


    > Before I re-invent the (possibly broken) wheel, are such kind of "SNMP
    > proxy" already available?


    The Net-SNMP agent should be able to do this.
    See the 'snmpd.conf' man page, under "PROXY SUPPORT".

    Dave

  7. Re: querying two different SNMP agents at port 161

    Hi Dave,

    > > I have the following idea: we could be to have a kind of "proxy"

    >
    > > Before I re-invent the (possibly broken) wheel, are such kind of

    "SNMP
    > > proxy" already available?

    >
    > The Net-SNMP agent should be able to do this.
    > See the 'snmpd.conf' man page, under "PROXY SUPPORT".


    It looks indeed very good.
    I'll check in a very near feature if it solves our problem...

    Many thanks!
    Loic.


  8. Re: querying two different SNMP agents at port 161

    Hi Loic,

    I am familiar with the Tru64 snmpd daemon and extensions available.

    The Tru64 SNMP Master Agent, snmpd supports AgentX. The Tru64 SNMP
    toolset includes a library implementing AgentX.

    So, if you can make your ...enterprises.16455 code into a subagent to
    the Tru64 Master using AgentX, this is your cleanest solution. You can
    use either the Net-Snmp or the Tru64 SNMP libraries for AgentX support.

    Regards,

    Mark


    loic-dev@gmx.net wrote:
    > Hello SNMP-newsgrouper,
    >
    > We are currently faced to the following problem. We have two (master)
    > agents: a standard agent delivered with Tru64, and our own agent
    > (starting at .enterprises.16455). Both agents are working on a set of
    > disjunct OIDs. For some reason I won't detail here, we would need to
    > query both agents on the standard 161 port. Of course, we can't run
    > both agents at port 161 simultaneously...
    >
    > I have the following idea: we could be to have a kind of "proxy" (I
    > don't know if the term is appropriate) running at port 161. The
    > standard agent would run for instance at port 1161, and our agent at
    > port 2161. When a request is received for .enterprises.16455, the proxy
    > would forward the request to our agent (running at port 2161), and
    > forward its answer back to the issuer of the snmp command. Otherwise,
    > it would forward the request to the standard agent (running at port
    > 1161), and forward its answer back.
    >
    > Before I re-invent the (possibly broken) wheel, are such kind of "SNMP
    > proxy" already available?
    >
    > Or perhaps, there are simpler solutions to the problem?
    >
    >
    > regards,
    > Loic.
    >


  9. Re: querying two different SNMP agents at port 161

    Salut Mark,

    > I am familiar with the Tru64 snmpd daemon and extensions available.
    >
    > The Tru64 SNMP Master Agent, snmpd supports AgentX. The Tru64 SNMP
    > toolset includes a library implementing AgentX.


    I am not sure. The version of Tru64 is quite "old" (Tru64 4.0F to be
    exact). Do you know if the shipped SNMP with that Tru64 version has
    AgentX support? ( I would be surprised, if it would. AFAICS, the AgentX
    RFC 2741 is dated from January 2000, Tru64 4.0F dates back to 1999).

    Anyway, thanks!
    Loic.


  10. Re: querying two different SNMP agents at port 161

    Hi Loic,

    You are correct on the publication date of 2741, but we worked from the
    i-d drafts that were eventually published at Proposed Standard in RFC
    2257 in January of 1998.

    Even if your Tru64 4.0F does not contain the AgentX functionality, the
    4.0F agent has extensibility capabilities- look for the eSNMP documentation.

    The AgentX bits hit the Tru64 5.0 release stream first, then hit both
    the Tru64 4.0 maintenance stream and the OpenVMS stream.

    At any rate, the Tru64 SNMP subagent developer's support for eSNMP and
    AgentX uses the same library API. Your release will contain wither
    eSNMP or AgentX, and any subagents developed to eSNMP will work without
    recompile or relinking with the AgentX library.

    Hope this helps!

    Regards,

    Mark

    loic-dev@gmx.net wrote:
    > Salut Mark,
    >
    >
    >>I am familiar with the Tru64 snmpd daemon and extensions available.
    >>
    >>The Tru64 SNMP Master Agent, snmpd supports AgentX. The Tru64 SNMP
    >>toolset includes a library implementing AgentX.

    >
    >
    > I am not sure. The version of Tru64 is quite "old" (Tru64 4.0F to be
    > exact). Do you know if the shipped SNMP with that Tru64 version has
    > AgentX support? ( I would be surprised, if it would. AFAICS, the AgentX
    > RFC 2741 is dated from January 2000, Tru64 4.0F dates back to 1999).
    >
    > Anyway, thanks!
    > Loic.
    >


  11. Re: querying two different SNMP agents at port 161

    Hi Loic.
    Note that the proxy feature had a long-standing bug which caused
    earlier versions of NetSNMP to freeze when executing more than one
    SNMP-walks simultaneously.
    This bug seems to be solved in the current version I'm working with,
    5.2.1
    Amit Dor-Shifer


  12. Re: querying two different SNMP agents at port 161

    Hello,

    thanks anyone! Your answers helped really a lot, and we saved
    definitively time by the deployment of a solution!

    Regards,
    Loic.


  13. Re: querying two different SNMP agents at port 161

    Hi Loic,
    The only think u want is, run both the agents in port 161 right? kindly
    correct me if my understanding is wrong.

    If u want to run both the agents in port 161, then u can go for some
    Snmp simulator kind of thing right. Using simulators u can load ur real
    agent values in the simulator and simulate multiple devices and run it
    in a same port numbers. But they use Virtual IP addresses concept.
    Virtual ips are nothing but they simulate ip addresses in ur NIC
    virtually.
    if its ok for u then let me know I can suggest u some good simulators.

    Cheers,
    M-A-N


+ Reply to Thread