Greetings,

I'm writing a python pass_persist script as part of a project I'm  
working on, and I couldn't help but notice a lack of public examples  
of python pass_persist scripts. Accordingly, I'd like to submit mine  
to net-snmp, but first I'd like to get some feedback. I'm also new to  
python, so any comments regarding the language would be appreciated  
(feel free to send such items directly to me to avoid off-topicness,  
if necessary :)

Here's the script: http://www.dreness.com/bits/tech/persist_test.py

This has been tested on Mac OS X Server 10.4.10 running 5.4 (via  
macports), and FreeBSD 6.1 running 5.2.3 (via freebsd ports).

It optionally produces a debug log (in this example, debug log of an  
snmpwalk rooted at the script's baseOID, with only two OIDs defined  
by the script)

- starting up
in: PING
out: PONG
in: getnext
in: .1.3.6.1.4.1.8072.9999.9999
- relative target: ||
- refreshing OID cache 0
- sorted OIDs to: ['.1.1', '.1.2']
- getnext is working .1.1
-  < .1.1
out: .1.3.6.1.4.1.8072.9999.9999.1.1
out: integer
out: 739
in: PING
out: PONG
in: getnext
in: .1.3.6.1.4.1.8072.9999.9999.1.1
- relative target: |.1.1|
- getnext is working .1.1
- .1.1 < .1.1
- getnext is working .1.2
- .1.1 < .1.2
out: .1.3.6.1.4.1.8072.9999.9999.1.2
out: integer
out: 54
in: PING
out: PONG
in: getnext
in: .1.3.6.1.4.1.8072.9999.9999.1.2
- relative target: |.1.2|
- getnext is working .1.1
- .1.2 < .1.1
- getnext is working .1.2
- .1.2 < .1.2
out: NONE

Cheers,
-Andre

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to