[AGENT++] Proposal: Explicit save of persistent objects via SNMP

Frank Fock fock at agentpp.com
Wed Oct 6 23:10:55 CEST 2004


Hi Henning,

I like your idea and I have to admit that I regret that it wasn't mine! ;-)
Within the next day(s) I will create a new revision of the
AGENTPP_CONFIG_MIB with a proposal for the new functions
you have enumerated.

As an extension of your ideas I will check if providing a backup config
directory is also possible.

I will post the MIB here, and after the communities feedback I will
implement the instrumentation.

Best regards,
Frank

Henning Eggers wrote:

>Hi,
>the Mib class has a method called "save_all()" which saves all persitent
>data to the persitent dir. The agent itself only saves them in the
>destructor which is reasonable. But most agents (ours at least) run "for
>ever" and only terminate if the system crashes. So persitent data, most
>importantly changes to the USM and TargetMib tables won't get changed and
>have to be reentered after a crash.
>
>I suggest an interface in the agentpp_config_mib (or a sibling) to force a
>save (a call to save_all()). This should include the following objects:
>- The persistent path (read/write), although writing to this would only make
>sense if this information was stored somewhere else on the disk (config
>file, registry, etc. ). Another use might be to store a backup copy of the
>current values.
>- The TimeStamp of the last save (readonly), just to be reassured that
>something happend.
>- The TimeStamp of the last read (readonly), to see if the values have been
>reset.
>- The action object, an enum (read/write): noAction(1), saveAll(2),
>readAll(3), setting which would result in the respective action. Reading
>would effectively be resetting the data to its boot-up values (if the path
>was not changed).
>
>The resulting MibGroup object would need a backreference to the Mib object
>to which it was added in order to be able to call save_all(), read_all()
>(which is now part of init()) and get_persistent_objects_path(). A
>set_persistent_objects_path() would still need to be implemented.
>
>I have already started a little work on this but consequently thought that
>this might be of general use and be better placed in a more general MIB or
>even its own MIB in the agentpp tree.
>Also I wanted to check if this may actually be already implemented
>somewhere.
>
>Thanks,
>Henning
>
>
>_______________________________________________
>AGENTPP mailing list
>AGENTPP at agentpp.org
>http://agentpp.org/mailman/listinfo/agentpp
>
>  
>





More information about the AGENTPP mailing list