tar -zxvf zabbix-3.0.2.tar.gz
cd zabbix-3.0.2
groupadd zabbix
useradd -g zabbix zabbix
ln -s /usr/local/lib/libiconv.so.2 /usr/lib/libiconv.so.2
/sbin/ldconfig
./configure --prefix=/opt/zabbix --enable-agent
make && make install
vi /etc/services #编辑,在最后添加以下代码
# Zabbix
zabbix-agent 10050/tcp # Zabbix Agent
zabbix-agent 10050/udp # Zabbix Agent
zabbix-trapper 10051/tcp # Zabbix Trapper
zabbix-trapper 10051/udp # Zabbix Trapper
cp -a /opt/soft/zabbix-3.0.2/misc/init.d/fedora/core/zabbix_agentd /etc/init.d/zabbix_agentd
vim /etc/init.d/zabbix_agentd
BASEDIR=/opt/zabbix
chmod +x /etc/init.d/zabbix_agentd
vim /opt/zabbix/etc/zabbix_agentd.conf
Server=192.168.80.10
ServerActive=192.168.80.10
Hostname=minion1
/etc/init.d/zabbix_agentd start
时间: 2024-10-11 08:57:39