diff options
author | elie <elie> | 2014-08-18 07:21:15 +0000 |
---|---|---|
committer | elie <elie> | 2014-08-18 07:21:15 +0000 |
commit | a3191d9a358bab64b4a71f2048349671ec320f4e (patch) | |
tree | fe84033fd97f234d8c3b1ee067df23145fa0954a /examples | |
parent | c30181f6d866521c27df7b217356097e5546e3ae (diff) | |
download | pysnmp-git-a3191d9a358bab64b4a71f2048349671ec320f4e.tar.gz |
CommandGenerator.getNext() & .getBulk() methods now support the
maxCalls kwarg to limit the maximum number of request-response
iterations to perform
Diffstat (limited to 'examples')
-rw-r--r-- | examples/hlapi/asyncore/sync/manager/cmdgen/custom-pysnmp-mibs-search-path.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/examples/hlapi/asyncore/sync/manager/cmdgen/custom-pysnmp-mibs-search-path.py b/examples/hlapi/asyncore/sync/manager/cmdgen/custom-pysnmp-mibs-search-path.py index f85cf6b2..a0f0f298 100644 --- a/examples/hlapi/asyncore/sync/manager/cmdgen/custom-pysnmp-mibs-search-path.py +++ b/examples/hlapi/asyncore/sync/manager/cmdgen/custom-pysnmp-mibs-search-path.py @@ -8,7 +8,8 @@ # * to an Agent at demo.snmplabs.com:161 # * for all OIDs past TCP-MIB::tcpConnTable # * TCP-MIB will be searched by a user-specified path -# * run till end-of-mib condition is reported by Agent OR maxRows == 20 +# * run till end-of-mib condition is reported by Agent OR maxRows == 100 OR +# maxCalls == 10 request-response interactions occur # * ignoring non-increasing OIDs whenever reported by Agent # # make sure IF-MIB.py is search path @@ -22,7 +23,7 @@ errorIndication, errorStatus, errorIndex, varBindTable = cmdGen.bulkCmd( cmdgen.UdpTransportTarget(('demo.snmplabs.com', 161)), 0, 50, cmdgen.MibVariable('TCP-MIB', 'tcpConnTable').addMibSource('/tmp/mymibs'), - lexicographicMode=True, maxRows=100, ignoreNonIncreasingOid=True + lexicographicMode=True, maxRows=100, maxCalls=10,ignoreNonIncreasingOid=True ) if errorIndication: |