Command-line SNMP tools

转载 2018年04月17日 15:11:44

Command-line SNMP tools

PyPI Python Versions Build status 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/SHA224/SHA256/SHA384/SHA512 auth and DES/3DES/AES128/AES192/AES256 privacy crypto algorithms
  • Automatically downloads required MIBs from the Internet
  • Runs over IPv4 and/or IPv6 transports
  • Cross-platform: works on Linux, Windows and OS X.
  • 100% Python, works with Python 2.4 up to Python 3.6

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.py -v3 -u usr-md5-des -l authPriv -A authkey1 -X privkey1 demo.snmplabs.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.py -v3 -u usr-sha-aes -l authPriv -A authkey1 -X privkey1 demo.snmplabs.com IP-MIB::ipAdEntBcastAddr.\"127.0.0.1\"
IP-MIB::ipAdEntBcastAddr."127.0.0.1" = Integer32: 1

$ snmpset.py -v2c -c public demo.snmplabs.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 @snmplabs.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

I'm interested in bug reports, fixes, suggestions and improvements. Your pull requests are very welcome!

Copyright (c) 2005-2018, Ilya Etingof. All rights reserved.

用VB编写异步多线程下载程序

用VB编写异步多线程下载程序大庆油田有限公司勘探开发研究院网络室 满孝 为了高效率地下载某站点的网页,我们可利用VB的Internet Transfer 控件编写自己的下载程序, Internet T...
  • hktl
  • hktl
  • 2001-03-30 01:30:00
  • 1074

command line tools工具无法调用

问题 mac终端:使用ar命令时,command line tools工具无法调用 错误提示:xcrun:error:active developer path ("/Applications/X...
  • dengzhaowensky
  • dengzhaowensky
  • 2014-09-26 10:17:57
  • 1114

nios ii常用函数整理

偏移量决定写入的数据对应何种(目的/所起作用) IO操作函数 函数原型:IORD(BASE, REGNUM) 输入参数:BASE为寄存器的基地址,REGNUM为寄存器的偏移量 函数说明:从基地址为BA...
  • aiqin138
  • aiqin138
  • 2015-05-24 19:27:25
  • 332

Ubuntu16.04+CUDA8.0+cudnn5.1+TensorFlow-GPU详细安装步骤

最近学习机器学习的基本算法,想着配合Python2.7+TensorFlow-gpu进行学习,奈何Windows上TensorFlow只支持Python3.5.x,虚拟机上用Ubuntu对硬件的调用又...
  • m0_37336333
  • m0_37336333
  • 2017-08-06 21:32:22
  • 1680

VMware 下 Linux 利用虚拟光驱安装 VMware Tools 详解

     我用的Linux系统是Fedora,刚学Linux,好多东西还不会,昨晚因为需要在主机系统window 7和虚拟系统Fedora之间copy或托拉文件,为此需要在虚拟机系统Fedora上安装...
  • lxiron
  • lxiron
  • 2010-11-02 10:58:00
  • 15919

The "android" command is deprecated

The "android" command is deprecated. For manual SDK, AVD, and project management, please use Androi...
  • launch_225
  • launch_225
  • 2017-06-27 09:31:41
  • 1687

编译Android 2.3源码错误总结

虽然版本2.3很老了,但是这是在完全新的Ubuntu上面编译的,可以使我们更加熟练. 1. host C: acp :0:0: warning: "_FORTIFY_SOURCE" redefin...
  • JIYILANZHOU
  • JIYILANZHOU
  • 2016-06-14 22:20:12
  • 929

开发snmp rddtools

1  安装  /usr/ports/net-mgmt/net-snmp/   获取  snmpwalk 等管理调试命令    记得同时选上  支持 python 模块 2.  最...
  • huithe
  • huithe
  • 2012-05-20 14:49:50
  • 1367

ios 库编译环境配置 xcode command line tools

mount 命令可以查看共享文件夹
  • djzhao
  • djzhao
  • 2014-10-13 18:20:11
  • 6035

GNU/Linux Command-Line Tools Summary

GNU/Linux Command-Line Tools Summary Gareth Anderson                somecsstudent(at)gmail.co...
  • AU3604
  • AU3604
  • 2013-05-16 08:14:15
  • 590
收藏助手
不良信息举报
您举报文章:Command-line SNMP tools
举报原因:
原因补充:

(最多只允许输入30个字)