首先在一台agent安装zabbix-agent
rpm -Uvh https://repo.zabbix.com/zabbix/5.0/rhel/7/x86_64/zabbix-release-5.0-1.el7.noarch.rpm yum clean all yum -y install zabbix-agent zabbix_agentd -V
版本和zabbix-server一致
一,添加Linux主机
修改已安装agent主机的配置,设置zabbix的server地址
[root@localhost ~]# sed '/#/d' /etc/zabbix/zabbix_agentd.conf|sed '/^$/d' PidFile=/var/run/zabbix/zabbix_agentd.pid LogFile=/var/log/zabbix/zabbix_agentd.log LogFileSize=0 Server=192.168.1.101 ServerActive=192.168.1.101 Hostname=Zabbix server Include=/etc/zabbix/zabbix_agentd.d/*.conf
设置Server和ServerActive为zabbix服务器地址即可
登录zabbix页面添加主机