Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V3 get command #32

Closed
DrewScatterday opened this issue Nov 14, 2023 · 5 comments
Closed

V3 get command #32

DrewScatterday opened this issue Nov 14, 2023 · 5 comments
Labels
area:documentation Improvements or additions to documentation area:pysnmp PySNMP package question Further information is requested

Comments

@DrewScatterday
Copy link

Not sure if I'm missing something. I'm on WSL linux with python 3.10 in a conda env

I did the following:

  • pip install pysnmp-lextudio
  • pip install snmpclitools-lextudio
  • snmpget.py -v3 -l authPriv -u usr-md5-des -A authkey1 -X privkey1 demo.pysnmp.com sysDescr.0

I got some error messages but was able to resolve it by changing to this:

  • snmpget -v 3 -l authPriv -u usr-md5-des -A authkey1 -X privkey1 demo.pysnmp.com sysDescr.0
@DrewScatterday
Copy link
Author

One tiny other thing I noticed was I couldn't get USM to work with just strings. For example:

user = UsmUserData('usr-md5-des', 'authkey1', 'privkey1')

I got an error message:
pysnmp.error.PySnmpError: Unsupported authentication object

But changing to this seemed to solve for me

user = UsmUserData(userName='usr-md5-des', authKey='authkey1', privKey='privkey1')

Maybe this thread will help someone from Google

@lextm
Copy link

lextm commented Nov 14, 2023

Please go through the documentation on https://pysnmp.com and the examples folder in this repo if you want to learn more about this project.

@lextm lextm added area:documentation Improvements or additions to documentation question Further information is requested area:pysnmp PySNMP package labels Nov 14, 2023
@lextm lextm closed this as completed Nov 14, 2023
@DrewScatterday
Copy link
Author

Hey @lextm Thank your maintaining this repo and keeping it alive!

A few misunderstandings on my part:

Have a great day

@lextm
Copy link

lextm commented Nov 15, 2023

"https://pysnmp.readthedocs.io" has been a pain for long, but whoever set it up isn't responsive to any inquiry to shut it down. It takes time for "https://pysnmp.com" to grow higher in search engine results and replace that obsolete site one day.

I just updated https://www.pysnmp.com/snmpclitools/ to reflect latest changes. You no longer need to add .py to execute the commands, but simply snmpget. However, this will conflict to Net-SNMP if you happen to install that on the same machine. You will need to hack system path to make sure the PySNMP command line tools are resolved before Net-SNMP executable.

@DrewScatterday
Copy link
Author

Yeah I've been mislead by that out of date site/repo a few times

The demo.snmp agent url that "https://pysnmp.readthedocs.io/" references is no longer active so I started really getting confused when trying to poll with snmp get messages and nothing was working. So thanks for running and maintaining demo.pysnmp.com because it makes testing snippets really easy!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:documentation Improvements or additions to documentation area:pysnmp PySNMP package question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants