Login  
Search All Forums
Dart Home | PowerSNMP for .NET | Custom Development Reply | PowerSNMP for .NET Topics | Forums   
AuthorForum: PowerSNMP for .NET
Topic: Use Agent for sending traps only
RHerwarts

From: Eindhoven, Netherlands
Posts: 2
Member Since: 08/05/10
posted August 5, 2010 3:01 AM

Hello,

is it possible to instantiate and start an agent for sending traps only?

I would like to disable the SNMP request functionality for an instance of an agent to avoid port conflicts on port 161. This occurs when multiple agents are instanciated in different processes. We need to be able to send traps from multiple processes running on the same machine.
I managed to work around this by setting the local endpoint of the agent to a dummy port. Thus avoiding the port conflict. However this is not what I prefer.
I tried to NOT start the agent for the processes that only use the agent to send traps. However when I send a trap port 161 will be opened anyway.

Any ideas?

Regards,

Raymond
K M Drake



From: Utica, NY USA
Posts: 3406
Member Since: 07/14/00
posted August 5, 2010 9:37 AM

Hi Raymond,
Yes, it is possible, by setting the agent.LocalEndPoint.

Some points:
1. You must open a local port to send traps.
2. You can open the agent on any port you want (and is available) by setting LocalEndPoint (if you use 0, an available port will be selected).
3. If you do not want it to listen for requests, do not call Start.
4. You can open a dedicated port, and keep it open, or open and close a different port with each trap sent.

Is it possible you are somehow using the same instance of the agent that is listening for requests?

-ken

RHerwarts

From: Eindhoven, Netherlands
Posts: 2
Member Since: 08/05/10
posted August 9, 2010 2:04 AM

Hi Ken,

thanks this helped me out!

Regards,

Raymond
Reply | PowerSNMP for .NET Topics | Forums   
This site is powered by PowerTCP WebServer Tool PowerTCP WebServer for ActiveX