开发者

Info Agent's SNMP

I Have some questions:

In in my system (es. windows), have many DLL extension agent attached with snmp service

When 开发者_如何学JAVAa request comes to the service snmp "Snmp.exe" it sends the request to all agents or only one?

How do I know which of them can answer the request?

Thanks


The main agent's job is to handle registrations for SNMP and each DLL will register the information it is able to serve. The information in SNMP is registered under a tree-structure represented by OIDs. The agent is smart enough to know which DLL (or subagent) is able to serve up a request based on the incoming OID being asked about.

You might consider reading RFC2741 which describes the "AgentX" protocol. Although this talks about the protocol and not a DLL, the fundamental way it works under the hood should be pretty similar.


@Wes response is OK. Here is just a complement. As discribed in "How to add an SNMP extension agent to the NT registry", you can find the DLL extension in the registry entries pointed by the one in :

Windows Server NT4 to Windows Server 2003 R2 (Workstatio, W2K, XP):

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SNMP\Parameter\ExtensionAgents

Begining Windows 2008 (Vista) :

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\SNMP\Parameters\ExtensionAgents

Each DLL expose SnmpExtensionInit function which report the supportedView as an OID.

BOOL WINAPI SnmpExtensionInit (DWORD dwTimeZeroReference,
                               HANDLE *hPollForTrapEvent,
                               AsnObjectIdentifier *supportedView);

I write a wrapper program that just load the DLL and call the function just to report the response, you can download and try slxSNMPInfo if you want. Sorry the site is in french, but the strings in the EXE files are in english.

Info Agent's SNMP

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜