配置zabbix时错误:configure: error: Invalid Net-SNMP directory - unable to find net-snmp-config

作者:admin 发布:2018-03-13 浏览:3126次

配置zabbix时错误:

configure: error: Invalid Net-SNMP directory - unable to find net-snmp-config

解决办法:

需要安装net-snmp

ubuntu下并没有可用的package,所以只能源安装。下面是源安装方法。

首先下载net-snmp

 地址:https://sourceforge.net/projects/net-snmp/files/net-snmp/5.7.3/net-snmp-5.7.3.zip/download

解压进入文件

unzip net-snmp-5.7.3.zip 

cd net-snmp-5.7.3

一定先安装libperl-dev,否则编译会报错

Makefile:656: recipe for target 'subdirs' failed

make: *** [subdirs] Error 1

> sudo apt-get install libperl-dev
 ./configure --with-default-snmp-version="3" --with-sys-contact="@@no.where" --with-sys-location="Unknown" 
--with-logfile="/var/log/snmpd.log" --with-persistent-directory="/var/net-snmp"
make
make install
echo export LD_LIBRARY_PATH=/usr/local/lib >> /etc/bashrc


snmpget -V

NET-SNMP version: 5.7.3

安装完成

标签: net-snmp-config

Comments (0)