Questions tagged [pysnmp]

PySNMP is a pure Python module used for SNMP operations.

PySNMP

PySNMP is a pure-Python module that can talk SNMPv1/v2/v3, automatically download and parse MIBs via pysmi and is designed with asynchronous applications in mind (e.g. asyncio).

Its source code spans over multiple GitHub repositories and you can get started from https://github.com/etingof/pysnmp

As the original project owner passed away, future ownership is to be determined. More details can be found in https://github.com/etingof/pysnmp/issues/429

477 questions
1
vote
1 answer

Decrypt SNMPv3 in Python

I have the raw packet capture of an SNMPv3 snmpwalk ###[ Raw ]### load =…
1
vote
1 answer

many OID's for interface and others on SFP

When I do snmpwalk on interface I get multiple duplicate descriptions: Does anyone know how to get ifIndex only active interfaces? No duplicates? And: Why does the SFP module have this ID (.17236997)? As it is assigned to Gigabitethernet0/3/4…
1
vote
0 answers

pysnmp how to use -O option if possible

I'm playing around with pysnmp to create a script to discover a cisco based network via cdp. I like to do a "snmpwalk" with the -Ov option to only get values not OIDs. Following my code for the getCmd: def get(target, oids, credentials, port=1024,…
masl
  • 11
  • 1
1
vote
0 answers

PySNMP Not Able To Receive SNMPv2 Traps On Same Machine

Currently trying to implement a way to receive traps on a Python application. My device sends his snmpV2 traps to my machine directly(tested working with other software), but PySNMP doesn't seem to receive them. I'm using the example code directly…
Zac6749
  • 11
  • 2
1
vote
0 answers

pysnmp receiver without securityEngineId

I am in the process of developing a pysnmp trap receiver. I have the problem that I unfortunately only receive traps (v3) when I specify a securityEngineId. However it is not possible for me to specify this. Scenario: Over 200 devices send me traps.…
1
vote
1 answer

Python - pysnmp "NameError: name 'USM_AUTH_HMAC96_SHA' is not defined"

I installed pysnmp 4.4.12 on Windows with Python 2.7, I have been probe the example https://pysnmp.readthedocs.io/en/latest/examples/hlapi/v3arch/asyncore/sync/manager/cmdgen/snmp-versions.html#snmpv3-auth-sha-privacy-aes128 and I get this…
Adolfo
  • 11
  • 3
1
vote
1 answer

snmp value range constraint not implemented while doing snmp walk

I had performed SNMP walk for Host Resources MIB. For more understanding of Host Resource MIB please refer this https://www.netscantools.com/snmp-host-resources-mib-analysis.html The snmp walk is done using command snmpwalk -v 2c -c…
rozi
  • 71
  • 10
1
vote
0 answers

Can't find how to compile a custom MIB to use in my simple python SNMP-Tool

I'm trying to compile a custom MIB (which I need to get Information from a Qnap NAS) to use it in my pysnmp program. I tried compiling it manually, but it seems like mibdump.py tries to get a MIB from http://mibs.snmplabs.com/pysnmp/notexts/@mib@…
1
vote
0 answers

How can i Parse custom mib(.mib) file using python pysnmp or pysmi and retrieve description related to a specific OID?

How can i Parse custom mib(.mib) file using python pysnmp or pysmi and retrieve description related to a specific OID? from pysnmp.smi import builder, view, compiler mibBuilder = builder.MibBuilder() compiler.addMibCompiler(mibBuilder, sources=…
1
vote
1 answer

pysnmp trap receiver - processing with asyncio queue (w/o threads)

My goal is to have a pure asyncio implementation to receive and process SNMP-TRAPS with pysnmp. So far I only managed to accomplish it by using (one or several) separate Threads. The examples I have found for pysnmp is using a sync callback Function…
Simon
  • 354
  • 3
  • 10
1
vote
1 answer

What is the best SNMP Package to use with python for over 100 nodes to monitor at the same time

I would like to request for the best python package to be able to send SNMP Request(Get,Getbulk..etc) I am using pysnmp with multiprocessing and it is working fine for 60 nodes however when i am trying to use it for 100+ nodes with multiprocessing i…
Victronix
  • 31
  • 4
1
vote
0 answers

How to pass custom message along with mib using pysnmp

I using pysnmp "4.4.12". I have a very specific requirement where I need to send snmptrap with custom message. I am able to send trap using my code but not sure how to pass custom message. next(sendNotification(SnmpEngine(), …
Ankur
  • 31
  • 1
1
vote
1 answer

Python snmp OID values

Im using this script to get memory and cpu statics ''' from pysnmp.hlapi import * errorIndication, errorStatus, errorIndex, varBinds = next( getCmd(SnmpEngine(), CommunityData('public', mpModel=0), …
known user
  • 51
  • 6
1
vote
2 answers

PySNMP how to convert to dot oid

How to convert in python SNMPv2-SMI.enterprises.9.1.283 to dot oid? SNMPv2-SMI.enterprises.9.1.283 -> 1.3.6.1.4.1.9.1.283 Thanks, Alexey
BOJIKA
  • 13
  • 2
1
vote
1 answer

How to get each returned value as variable for later use?

from this code im trying to get the returned values of the walk as variables. def walk(host, oid): for (errorIndication, errorStatus, errorIndex, varBinds) in nextCmd(SnmpEngine(), …
P1ro
  • 23
  • 6