Trouble with SNMP proxy

Started by gbghenke, January 16, 2007, 12:40:10 PM

Previous topic - Next topic

gbghenke

Hi

This is the following scenario:

host A, netxms gui client
host B, netxms server (on the same physical network as host A)
host C, netxms agent (linux red hat enterprise, icmp, snmp and port 4700 are open from netxms server to this host)
host D, linux server with net-snmp (host C can connect using icmp and snmp to this host)

Polling in netxms of host C is not problem because i have the netxms agent on this host. However what i wanna do now is to use SNMP monitoring on the host D, which will be proxied by host C. I have activated both EnableProxy and EnableSNMPProxy in the agent configuration of host C.

When i add the host D as a node in netxms i add it and click the disable usage of ICMP pings and disable access to NetXMS agent, i select host C as proxy for SNMP. When this is finished and the host is added it becomes unavailable. (i have the correct communitystring).

When i check the traffic in the interfaces i can see that the netxms server host B is talking to the proxy host C over tcp port 4700 but host C is not trying to initiate any SNMP traffic to host D.

i cant either poll for "configuration" because it tells me that the host is unavailable.

Can i debug this and submit more information in some way? Please let me know?

All software are 0.2.15

Kind Regards
Henrik Olsson

Victor Kirhenshtein

Hello!

It's a misleading field "Proxy" in node creation dialog - it only sets agent proxy. Node object has two different properties - agent proxy and SNMP proxy, and SNMP proxy can be set only after node object creation in object's properties (my mistake, will correct it in next release). Now, you have to set "SNMP proxy" attribute in node's D properties correctly and try to re-poll it. If system will reject configuration polls because node is down (another problem which needs to be solved) you will have to restart the NetXMS server. This should clear "node unreachable" flag and allow you to do a configuration poll. If this will not help, I'll send you a patch for server that will fix this problem with configuration poll. Are you running NetXMS server on Windows or UNIX (so do you need updated Windows installation or updated source code)?

Best regards,
Victor

gbghenke

Hi again.

Yes i noticed that there was a separate setting for SNMP proxy not accessable from the "add node" dialog. Now i have set the NetXMS Agent proxy setting to none, the SNMP Proxy setting to host C and the poller node is default "<server>".

With Ping and netxms agent diabled the Poll->Status takes 0,5 Seconds to complete and host C does not generate any traffic toward host D. A restart of the netxms server does not help clear the node unreachable flag, and since the flag in still there i cannot Poll->Configuration.

With Ping and netxms agent enabled the Poll->Status makes host B generate icmp packets toward host D (which is not allowed). This also tells me after 5 seconds that Node is still unreachable.

host A is Windows runnig the Windows Gui.
host B is Linux Red Hat Enterprise 4 (netxms server runnig both server and agent.)
host C is the same as host B (netxms compiled only with agent)
host D is an snmp enabled embedded device

So answering you question, i run the Unix (source code version) version of netxms server.

Kind regards
Henrik Olsson

gbghenke

#3
UPDATE:

After playing around with the objects for half an hour using the change ip adress feature i managed to get the SNMP proxy function to work. So the problem is that its flagged unavailable its not a problem with the SNMP proxy itself.

UPDATE2:

I found out that the quick way to do this is to:

1. Create node as an unmanaged node.
2. Select the proper proxy server for snmp
3. do a Poll->Configuration
4. Change node to managed
5. done no unreachable error message :)

/Henrik

Victor Kirhenshtein

Good that you found a workaround :) In case you'll need it, you can get a patch to the server. With this patch, configuration poll initiated from console will reset "unreachable" flag and recheck node capabilities, as "Change IP address" do. To apply the patch, just replace two files:

src/server/include/nms_objects.h
src/server/core/session.cpp

with files from

https://www.netxms.org/download/patches/001/

and recompile server.

Best regards,
Victor

gbghenke

Thank you, i'll test out these patches later today.

I must say that you are making great progress on this project, keep up the good work.

/Henrik Olsson

gbghenke

Server is recompiled with your latest patch now and it works like intended. Poll->Configuration correctly discovers the Snmp agent.

However i have noticed that going from version 0.2.14 -> 0.2.15 on the netxms agent (the one that dos the snmp proxying) may have surfaced some stability issues. I have had 0.2.15 agent running (with Snmp proxy active) for about 24h now and so far the netxms agent have died (without posting a reason in the log) twice.

The other agents (without snmp proxy function active) are just as stable as 0.2.14 was.

/Henrik