easysnmp icon indicating copy to clipboard operation
easysnmp copied to clipboard

How to install easysnmp with net-snmp installed in /opt/netsnmp

Open vnalla opened this issue 3 years ago • 1 comments

What's on your mind? I have installed net-snmp 5.9.3 in /opt/netsnmp directory and trying to install easysnmp like shown below:

python3 setup.py --basedir=/opt/netsnmp/bin.

it fails with the following error Traceback (most recent call last): File "/opt/app/vntest/easysnmp-0.2.6/setup.py", line 33, in libs_cmd = base_cmd.format('--build-lib-dirs {0}'.format(basedir)) KeyError: '/opt/netsnmp/bin'

vnalla avatar Jan 04 '23 16:01 vnalla

I'm not an expert at this, so I could be wrong here.

I ran into this issue as well. I had to change a few lines in setup.py. See this patch. easysnmp-setup.txt

Also, it seems that "--basedir" is supposed to be a build directory for net-snmp, not an install directory.

Also, don't forget to include the install command:

python3 setup.py install --basedir=/path/to/build/dir

antonc42 avatar Apr 20 '23 18:04 antonc42