查询zabbix服务器snmpd服务状态的时候提示:

# systemctl status snmptrapd
● snmptrapd.service - Simple Network Management Protocol (SNMP) Trap Daemon.
   Loaded: loaded (/lib/systemd/system/snmptrapd.service; disabled; vendor preset: enabled)
   Active: active (running) since Thu 2018-03-01 14:38:19 +02; 17min ago
 Main PID: 11243 (snmptrapd)
   CGroup: /system.slice/snmptrapd.service
           └─11243 /usr/sbin/snmptrapd -Lsd -f

Mar 01 14:38:20 raspberrypi snmptrapd[11243]: Cannot adopt OID in UCD-SNMP-MIB: laErrorFlag ::= { laEntry 100 }
Mar 01 14:38:20 raspberrypi snmptrapd[11243]: Cannot adopt OID in UCD-SNMP-MIB: laLoadFloat ::= { laEntry 6 }
Mar 01 14:38:20 raspberrypi snmptrapd[11243]: Cannot adopt OID in UCD-SNMP-MIB: laLoadInt ::= { laEntry 5 }
Mar 01 14:38:20 raspberrypi snmptrapd[11243]: Cannot adopt OID in UCD-SNMP-MIB: laConfig ::= { laEntry 4 }
Mar 01 14:38:20 raspberrypi snmptrapd[11243]: Cannot adopt OID in UCD-SNMP-MIB: laLoad ::= { laEntry 3 }
Mar 01 14:38:20 raspberrypi snmptrapd[11243]: Cannot adopt OID in UCD-SNMP-MIB: laNames ::= { laEntry 2 }
Mar 01 14:38:20 raspberrypi snmptrapd[11243]: Cannot adopt OID in UCD-SNMP-MIB: laIndex ::= { laEntry 1 }
Mar 01 14:38:20 raspberrypi snmptrapd[11243]: embedded perl support failed to initialize (perl_parse(/usr/share/snmp/snmp_perl_trapd.pl) returned 2)
Mar 01 14:38:20 raspberrypi snmptrapd[11243]: NET-SNMP version 5.7.3 AgentX subagent connected
Mar 01 14:38:20 raspberrypi snmptrapd[11243]: NET-SNMP version 5.7.3

其他提示:

# snmptrapd -On
Can't locate NetSNMP/TrapReceiver.pm in @INC (you may need to install the NetSNMP::TrapReceiver module) (@INC contains: /etc/perl /usr/local/lib/arm-linux-gnueabihf/perl/5.24.1 /usr/local/share/perl/5.24.1 /usr/lib/arm-linux-gnueabihf/perl5/5.24 /usr/share/perl5 /usr/lib/arm-linux-gnueabihf/perl/5.24 /usr/share/perl/5.24 /usr/local/lib/site_perl) at /usr/share/snmp/snmp_perl_trapd.pl line 13.
BEGIN failed--compilation aborted at /usr/share/snmp/snmp_perl_trapd.pl line 13.

解决方法

apt install libsnmp-perl
# or
apt install snmptt
最后修改:2021 年 05 月 20 日 11 : 01 AM
如果觉得我的文章对你有用,请随意赞赏