I am trying to use netsnmp in python but it is unable to import after following all suggestions related to netsnmp in python. I installed netsnmp using below commands

yum install net-snmp net-snmp-utils
easy_install ipython

snmpd service is running. It still throws this error

ImportError: No module named netsnmp

I am using Cent os 6.5 and Python version 2.6.6 Kindly help if installation is incorrect or any other configuration is missing.

有帮助吗?

解决方案

To import netsnmp in python only net-snmp-python is required both net-snmp net-snmp-utils can be removed. so just

yum install net-snmp-python

will do for importing netsnmp library into python on Cent os 6.5

yum install net-snmp net-snmp-utils

will enable SNMP queries from Linux terminal. Both can work independently.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top