summaryrefslogtreecommitdiff
path: root/examples/v3arch/twisted/manager/cmdgen/set-v1.py
diff options
context:
space:
mode:
Diffstat (limited to 'examples/v3arch/twisted/manager/cmdgen/set-v1.py')
-rw-r--r--examples/v3arch/twisted/manager/cmdgen/set-v1.py30
1 files changed, 16 insertions, 14 deletions
diff --git a/examples/v3arch/twisted/manager/cmdgen/set-v1.py b/examples/v3arch/twisted/manager/cmdgen/set-v1.py
index c372104..fee0ed2 100644
--- a/examples/v3arch/twisted/manager/cmdgen/set-v1.py
+++ b/examples/v3arch/twisted/manager/cmdgen/set-v1.py
@@ -1,17 +1,19 @@
-#
-# SET Command Generator
-#
-# Send a SNMP SET request
-# with SNMPv1, community 'private'
-# using Twisted framework for network transport
-# over IPv4/UDP
-# to an Agent at 195.218.195.228:161
-# for OIDs in tuple form and an integer and string-typed values
-#
-# This script performs similar to the following Net-SNMP command:
-#
-# $ snmpset -v1 -c private -ObentU 195.218.195.228:161 1.3.6.1.2.1.1.9.1.3.1 s 'my value' 1.3.6.1.2.1.1.9.1.4.1 t 123
-#
+"""
+SET string and integer scalars (SNMPv1)
++++++++++++++++++++++++++++++++++++++++
+
+Send a SNMP SET request
+* with SNMPv1, community 'private'
+* using Twisted framework for network transport
+* over IPv4/UDP
+* to an Agent at 195.218.195.228:161
+* for OIDs in tuple form and an integer and string-typed values
+
+This script performs similar to the following Net-SNMP command:
+
+| $ snmpset -v1 -c private -ObentU 195.218.195.228:161 1.3.6.1.2.1.1.9.1.3.1 s 'my value' 1.3.6.1.2.1.1.9.1.4.1 t 123
+
+"""#
from twisted.internet import reactor, defer
from pysnmp.entity import engine, config
from pysnmp.entity.rfc3413.twisted import cmdgen