Unable to install net-snmp of ubuntu 16.04 : error received

I have tried several times but unable to install net-snmp on Ubuntu 16.04i cant understand at all what is the issue . Please any help will be more than welcome :

net-snmp directory name :

net-snmp-5.7.3+dfsg

output of ./configure
--------------------------------------------------------- Net-SNMP configuration summary:
--------------------------------------------------------- SNMP Versions Supported: 1 2c 3 Building for: linux Net-SNMP Version: 5.7.3 Network transport support: Callback Unix Alias TCP UDP IPv4Base SocketBase TCPBase UDPIPv4Base UDPBase SNMPv3 Security Modules: usm Agent MIB code: default_modules => snmpv3mibs mibII ucd_snmp notification notification-log-mib target agent_mibs agentx disman/event disman/schedule utilities host MYSQL Trap Logging: unavailable Embedded Perl support: disabled SNMP Perl modules: building -- not embeddable SNMP Python modules: disabled Crypto support from: crypto Authentication support: MD5 SHA1 Encryption support: DES AES Local DNSSEC validation: disabled
Error Received :
/usr/bin/ld: cannot find -lperl
collect2: error: ld returned 1 exit status
Makefile:976: recipe for target 'libnetsnmpagent.la' failed
make[1]: *** [libnetsnmpagent.la] Error 1
make[1]: Leaving directory '/home/siaetest/net-snmp-5.7.3+dfsg/agent'
Makefile:852: recipe for target 'installsubdirlibs' failed
make: *** [installsubdirlibs] Error 1
sudo apt-cache search net-snmp
libnet-snmp-perl - Script SNMP connections
libsnmp-base - SNMP configuration script, MIBs and documentation
libsnmp-dev - SNMP (Simple Network Management Protocol) development files
libsnmp30 - SNMP (Simple Network Management Protocol) library
libsnmp30-dbg - SNMP (Simple Network Management Protocol) library debug
snmp - SNMP (Simple Network Management Protocol) applications
snmpd - SNMP (Simple Network Management Protocol) agents
libsnmp-extension-passpersist-perl - Generic pass/pass_persist extension framework for Net-SNMP
libsnmp-perl - SNMP (Simple Network Management Protocol) Perl5 support
python-netsnmp - SNMP (Simple Network Management Protocol) Python support
ruby-snmp - simple network management protocol bindings for ruby
snmptrapd - Net-SNMP notification receiver
snmptt - SNMP trap handler for use with snmptrapd
tkmib - SNMP (Simple Network Management Protocol) MIB browser
8

2 Answers

I have resolved this issue through normal way :

./configure
make
sudo make install 

I then typed snmpget --version

and i got reply "NET-SNMP version: 5.7.3"

primarily the issue was resolved with the workaround by manually creating the symlink with ln -s /usr/lib/libperl.so.5.22 /usr/lib/libperl.so and it links correctly.

please read below link which was helpful :

Thanks everyone for the effort

/usr/bin/ld: cannot find -lperl

This is the linker, complaining that it can't find perl libraries.

To install the perl libraries, run sudo apt install libperl-devel.

But as you do not have internet connectivity, this is probably not possible. You can download the package from here, but it must match other installed perl packages - which in a offline system requires some tracking down.

You write that you have the machine in a DMZ. You should configure some way for the machine to reach internet, to get updates and install software. This can be via an apt proxy, which will behave like a local mirror, without the overhead to mirror all packages that you don't need.

Running machines without access to updates is considered a security risk - and as you've discovered, makes installing software more difficult.

3

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like