groupadd zabbix
useradd -g zabbix zabbix
wget https://cdn.zabbix.com/zabbix/sources/stable/5.0/zabbix-5.0.3.tar.gz
tar -xzvf zabbix-5.0.3.tar.gz
cd zabbix-5.0.3/
./configure --enable-server --with-mysql --enable-ipv6 --with-net-snmp --with-libcurl --with-libxml2
yum install -y net-snmp net-snmp-utils net-snmp-devel
zabbix在编译时报:
configure: error: Invalid Net-SNMP directory - unable to find net-snmp-config
解决办法是安装net-snmp-devel
yum install -y net-snmp-devel
make -j8
make install
cd /root/zabbix-5.0.3/database/mysql/
mysql -h127.0.0.1 -uzabbix -p zabbix < schema.sql
mysql -h127.0.0.1 -uzabbix -p zabbix < images.sql
mysql -h127.0.0.1 -uzabbix -p zabbix < data.sql
zabbix_server
killall zabbix_server
zabbix_server
telnet 127.0.0.1 10051
复制管理端到WEB目录
cp -R /root/zabbix-5.0.3/ui/ /www/wwwroot/zabbix.com/
配置文件:/usr/local/etc/zabbix_server.conf
service zabbix-agent restart
管理网默认的用户名是 Admin,密码是zabbix
yum 安装zabbix agent
rpm -Uvh https://repo.zabbix.com/zabbix/5.0/rhel/7/x86_64/zabbix-release-5.0-1.el7.noarch.rpm
yum install zabbix-agent
修改配置:/etc/zabbix/zabbix_agentd.conf
4.编辑Zabbix Agent 配置文件
vim /etc/zabbix/zabbix_agentd.conf
Server=[zabbix server ip]
ServerActive=[zabbix server ip]
Hostname=[ Hostname of client system ]
5.重启Zabbix Agent
service zabbix-agent restart
6.添加开机启动
chkconfig zabbix-agent on