Re: State Information in smnpset: where to keep it?

2013-01-08 Thread Dave Shield
On 8 January 2013 22:31, Kent Borg wrote: > I think so. Let me restate what I think I know. > > If I use the command line "snmpset" to set a bunch of variables, > I am (nearly*) guaranteed that either they all happen or none of them do. If you issue a single snmpset command with several assignme

RE: State Information in smnpset: where to keep it?

2013-01-08 Thread Kent Borg
> Make sense? I think so. Let me restate what I think I know. If I use the command line "snmpset" to set a bunch of variables, I am (nearly*) guaranteed that either they all happen or none of them do. So if I set foo to 3 and bar to 7, handle_foo() will get a RESERVE1, RESERVE2, etc. handle

Re: State Information in smnpset: where to keep it?

2013-01-08 Thread Dave Shield
On 8 January 2013 20:44, Kent Borg wrote: > I think am only doing scalars, no tables. (Whether there is a table > is dependent on the MIB, right? If I have a MIB with no tables, > I don't need to handle tables?) Correct. > With just scalars might there still be a list of requests Yes >

RE: State Information in smnpset: where to keep it?

2013-01-08 Thread Kent Borg
I think am only doing scalars, no tables. (Whether there is a table is dependent on the MIB, right? If I have a MIB with no tables, I don't need to handle tables?) With just scalars might there still be a list of requests that must be worked through? My mib2c config started out life as the

Re: State Information in smnpset: where to keep it?

2013-01-08 Thread Dave Shield
On 8 January 2013 16:00, Kent Borg wrote: > I don't think I understand. I am not interating over anything now, I am > just getting handle_somevariableofmine() calls and I look reqinfo->mode to > see what I am supposed to do. (I have a single template I feed to mib2c and > it produces a long file

Re: State Information in smnpset: where to keep it?

2013-01-08 Thread Dave Shield
On 8 January 2013 15:07, Kent Borg wrote: > But I am worried about the state machine used in setting a variable. How do > I save state information between MODE_SET_RESERVE1 and MODE_SET_RESERVE2, > MODE_SET_COMMIT? First question - are you implementing a table, or a set of scalar objects? The no

RE: State Information in smnpset: where to keep it?

2013-01-08 Thread Kent Borg
> One way to implement this is to have a structure that has backup values > stored, > such that you have the object you want to read and write, OID, and an > placeholder old_OID. > > You can then iterate over the request varbinds, storing any old values until > such > time as you commit them, or

RE: State Information in smnpset: where to keep it?

2013-01-08 Thread jregovic
One way to implement this is to have a structure that has backup values stored, such that you have the object you want to read and write, OID, and an placeholder old_OID.You can then iterate over the request varbinds, storing any old values until such time as you commit them, or undo the set. ---

State Information in smnpset: where to keep it?

2013-01-08 Thread Kent Borg
Hello, I am working on an AgentX agent to run in an embedded beast, and I seem to have things working. But I am worried about the state machine used in setting a variable. How do I save state information between MODE_SET_RESERVE1 and MODE_SET_RESERVE2, MODE_SET_COMMIT? - reginfo->my_reg_void

Re: Regarding logOption in snmptrapd.conf file

2013-01-08 Thread Dave Shield
On 8 January 2013 08:16, Adishesh M wrote: > Using latest version NET-SNMP Version: 5.7.2 same other error is coming. > > snmptrapd is not recognizing logOption Please see my earlier message: trying to set this {logOption} in the trapd config file is either not processed early enough

Re: Regarding logOption in snmptrapd.conf file

2013-01-08 Thread Adishesh M
Hi Dave, Using latest version NET-SNMP Version: 5.7.2 same other error is coming. snmptrapd is not recognizing logOption Jan 8 13:35:17 mercury13 snmptrapd[8863]: /etc/snmp/snmptrapd.conf: line 36: Warning: Unknown token: logOption. it is still logging traps to /var/log/messages file. my snm