Summary

SNMP simulator installation guide

Introduction

The SNMP Simulator software is intended for testing SNMP Managers against a large number of SNMP Agents that represent a potentially very large network populated with different kinds of SNMP-capable devices.

More info refers to its official website

This blog is about how to install SNMP Simulator on windows (Info about my OS :Win10 Pro version: 1511 OS build: 10586.494).

1st of all, Install Python

Download/execute installation files from the official website.

Note: This blog is not for Python3.5 later versions.

It took me too much time to install Python3.5 on Windows 2003, so my suggestion version is Python3.4

Installation option:

Untitled

2nd, Install PyCrypto

why?

SNMP simulator required some Python packages:

  • PyASN1
  • PySNMP
  • PyCrypto
  • pysmi
  • ply

It always fail when installing PyCrypto by pip with error:

running build_ext
warning: GMP or MPIR library not found; Not building Crypto.PublicKey._fastmath.
building 'Crypto.Random.OSRNG.winrandom' extension
error: Unable to find vcvarsall.bat
----------------------------------------
Command d:\program files (x86)\python3.5\python.exe; -u -c import setuptools,tokenize;__file__='D:\\temp\\OSTEMP\\pip-build-9o27ywdt\\pycrypto\\setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec')) install --record D:\temp\OSTEMP\pip-3h_5j6n8-record\install-record.txt --single-version-externally-managed --compile failed with error code 1 in D:\temp\OSTEMP\pip-build-9o27ywdt\pycrypto\

Refer to stackoverflow, I would like resove this issue in an easier way : install a build distribution from 3rd party.

For Python 2.6, 2.7, 3.2, 3.3, 3.4

Visit the link to select/download Pycrypto installation file, execute the file to finish PyCrypto setup

E.g.:

For Python3.4 32bit,  choose pycrypto-2.6.1.win32-py3.4.exe

For Python3.4 64 bit, choose pycrypto-2.6.1.win-amd64-py3.4.exe

For Python3.5

Install PyCrypto by pip command

  • 64-bit
pip install --use-wheel --no-index --find-links=https://github.com/sfbahr/PyCrypto-Wheels/raw/master/pycrypto-2.6.1-cp35-none-win_amd64.whl pycrypto
  • 32bit
pip install --use-wheel --no-index --find-links=https://github.com/sfbahr/PyCrypto-Wheels/raw/master/pycrypto-2.6.1-cp35-none-win32.whl pycrypto

Finally, Install SNMPsim:

  • For Python3.5

Install SNMP Simulator by pip command:

pip install snmpsim
  • For Other versions:

Refer to SNMPsim pypi page, copy egg file’s hyperlink to install it by easy_install tool

easy_install.exe egg_file_hyperlink

Run it:

Untitled.png

Note:

  • pip will download/install package from the Internet
  • If Python is not in your OS path environment, enter to pip folder by command:
    cd python installation folder/scripts
  • when the installation was done, snmpsimd.py also in the folder: python installation folder/scripts
  • Pycrypto installation issue

On Linux , you may met an issue:

warning: GMP or MPIR library not found; Not building Crypto.PublicKey._fastmath.
src/MD2.c:31:20: fatal error: Python.h: No such file or directory
compilation terminated.

Solution:

Install Python-dev by apt-get command

sudo apt-get install python-dev
  • 0.3.1 is strong recommended

The version can be download from changelog from its official website, related link. It fixes an issue about demonize it by Python3 on Linux.

Error:

TypeError: ‘str’ does not support the buffer interface

Download/Unzip it, and install it by following command:

python setup.py install

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s