Skip to main content

A collection of command-line tools for SNMP management purposes built on top of PySNMP package.

Project description

Command-line SNMP tools

PyPI PyPI Downloads Python Versions GitHub license

This is a collection of command-line SNMP tools written in pure-Python. The tools mimic their famous Net-SNMP counterparts.

In the past this project was known as pysnmp-apps.

Features

  • Complete SNMPv1/v2c and SNMPv3 support
  • Interface compatible (almost) with Net-SNMP's snmp* tools.
  • SNMPv3 USM supports MD5/SHA/SHA-224/SHA-256/SHA-384/SHA-512 auth and DES/3-DES/AES-128/AES-192/AES-256 privacy crypto algorithms
  • Automatically downloads required MIBs from the Internet
  • Runs over IPv4 and/or IPv6 transports
  • Cross-platform: works on Linux, Windows and macOS.
  • 100% Python, works with Python 3.8+

Download

The snmpclitools package is distributed under terms and conditions of 2-clause BSD license. Source code is freely available as a Github repo.

Installation

Download snmpclitools from PyPI or just run:

$ pip install snmpclitools

How to use the tools

The most of pysnmp command-line tools could be run in a similar way as their Net-SNMP counterparts. For example:

$ snmpbulkwalk -v3 -u usr-md5-des -l authPriv -A authkey1 -X privkey1 demo.pysnmp.com system
SNMPv2-MIB::sysDescr.0 = DisplayString: Linux grommit 3.5.11.1 #2 PREEMPT Tue Mar 1 14:03:24 MSD 2016 i686 unknown unknown GNU/Linux
SNMPv2-MIB::sysObjectID.0 = ObjectIdentifier: iso.org.dod.internet.private.enterprises.8072.3.2.101.3.6.1.4.1.8072.3.2.10
SNMPv2-MIB::sysUpTime.0 = TimeTicks: 43 days 1:55:47.85372214785
[ skipped ]
SNMPv2-MIB::sysORUpTime."8" = TimeStamp: 0 days 0:0:0.77
SNMPv2-MIB::sysORUpTime."9" = TimeStamp: 0 days 0:0:0.77

$ snmpget -v3 -u usr-sha-aes -l authPriv -A authkey1 -X privkey1 demo.pysnmp.com IP-MIB::ipAdEntBcastAddr.\"127.0.0.1\"
IP-MIB::ipAdEntBcastAddr."127.0.0.1" = Integer32: 1

$ snmpset -v2c -c public demo.pysnmp.com SNMPv2-MIB::sysDescr.0 = my-new-descr
notWritable(17)

For more information, please, run any of these tools with --help option.

You can play with different security protocols against the publicly available SNMP agent like this one @www.pysnmp.com.

Getting help

If something does not work as expected, please open up a GitHub issue or post your question to Stack Overflow.

Feedback and collaboration

Your pull requests are very welcome!

Copyright (c) 2005-2019, Ilya Etingof. Copyright (c) 2022-2024, LeXtudio Inc.. All rights reserved.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

snmpclitools-0.7.2.tar.gz (59.9 kB view details)

Uploaded Source

Built Distribution

snmpclitools-0.7.2-py3-none-any.whl (36.9 kB view details)

Uploaded Python 3

File details

Details for the file snmpclitools-0.7.2.tar.gz.

File metadata

  • Download URL: snmpclitools-0.7.2.tar.gz
  • Upload date:
  • Size: 59.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.11.0 Darwin/23.6.0

File hashes

Hashes for snmpclitools-0.7.2.tar.gz
Algorithm Hash digest
SHA256 c54977a588bfc4beba83ec77f6294957128de27bb3b86c05f488cbd3d0977b15
MD5 5284f7f6015696d0312172601832783c
BLAKE2b-256 b764947b1cad405ba175c03385a4936b930b1fda7ce65e9da5bef5d64a5439fb

See more details on using hashes here.

File details

Details for the file snmpclitools-0.7.2-py3-none-any.whl.

File metadata

  • Download URL: snmpclitools-0.7.2-py3-none-any.whl
  • Upload date:
  • Size: 36.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.11.0 Darwin/23.6.0

File hashes

Hashes for snmpclitools-0.7.2-py3-none-any.whl
Algorithm Hash digest
SHA256 16af688cd085cb11d31cfde0c8c595ea8b7923eda3bfcd5377a461518da684e7
MD5 cad8567f78983b9fa12ed4723cfe05a1
BLAKE2b-256 bc0b19023f1b276a48329654d3205e219c9f6b3d44deb21debc8a9acc30eba6e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page