First thanks for your response,
Then if I’ve understood what u said, I think I did use my handlers in
subagent for scalars as bellow:
netsnmp_handler_registration *reg;
reg = netsnmp_create_handler_registration("objInteger", NULL,
objInteger_oid,
OID_LENGTH(objInteger_oid),
HANDLER_CAN_RWRITE);
netsnmp_init_watcher_info(&objInteger_winfo, *&objInteger*, sizeof(long),
ASN_INTEGER, WATCHER_FIXED_SIZE);
I put the scalars in my program, then used a reference in my snmp handler
code(like the second argument of last function in the above example).
Now I want to do sth like that for tables.
I used different kinds of table handler (data-set, container,…), but
couldn’t find a way to use data defined somewhere else as table objects.
I can’t figure out how I can associate the definition of data in my program
and table objects in subagent code.
ZG
On Sun, Feb 20, 2011 at 8:11 AM, Wes Hardaker <
[email protected]> wrote:
> >>>>> On Sun, 20 Feb 2011 01:48:57 -0500, Zahra Ghavami <
> [email protected]> said:
>
> ZG> How can i handle a table in a way that its data can be manipulated by
> other
> ZG> programs not using snmp?
> ZG> e.g. having a simple reference to an array,...?
>
> The traditional way of doing that is the opposite: put the data in the
> program you want it to be in, and instrument the other program with
> source code to make it an AgentX subagent to the main snmpd.
> --
> Wes Hardaker
> Please mail all replies to [email protected]
>
------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders