Nie można zainstalować net-snmp Ubuntu 16.04: otrzymano błąd
Próbowałem kilka razy, ale nie mogę zainstalować net-snmp na Ubuntu 16.04i, nie mogę w ogóle zrozumieć, na czym polega problem. Każda pomoc będzie mile widziana:
Nazwa katalogu net-snmp:
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
Odpowiedzi
/ usr / bin / ld: nie można znaleźć -lperl
To jest linker, narzekający, że nie może znaleźć bibliotek Perla.
Aby zainstalować biblioteki perl, uruchom sudo apt install libperl-devel
.
Ale ponieważ nie masz połączenia z Internetem, prawdopodobnie nie jest to możliwe. Możesz pobrać pakiet stąd , ale musi on pasować do innych zainstalowanych pakietów Perla - co w systemie offline wymaga śledzenia.
Piszesz, że masz maszynę w strefie DMZ. Należy skonfigurować sposób, aby urządzenie łączyło się z Internetem, pobierało aktualizacje i instalowało oprogramowanie. Może to nastąpić za pośrednictwem apt proxy , które będzie zachowywać się jak lokalny serwer lustrzany, bez narzutu związanego z dublowaniem wszystkich pakietów, których nie potrzebujesz.
Uruchamianie komputerów bez dostępu do aktualizacji jest uważane za zagrożenie bezpieczeństwa - i jak już zauważyłeś, utrudnia instalowanie oprogramowania.
Rozwiązałem ten problem w normalny sposób:
./configure
make
sudo make install
Następnie wpisałem snmpget --version
i otrzymałem odpowiedź „Wersja NET-SNMP: 5.7.3”
przede wszystkim problem został rozwiązany dzięki obejściu poprzez ręczne utworzenie dowiązania symbolicznego za pomocą ln -s /usr/lib/libperl.so.5.22 /usr/lib/libperl.so, które łączy poprawnie.
przeczytaj poniższy link, który był pomocny:
https://stackoverflow.com/questions/17576911/cannot-find-lperl-doing-a-makefile-on-c
Dziękuję wszystkim za wysiłek