Centos 6.x 搭建 Zabbix Agent 客户端
如需搭建zabbix server端,请参考:Zabbix-Server配置
环境:
Zabbix-Server: Centos 6.8 IP:192.168.126.129 #Zabix-Server地址(此篇文章可不必在意)
Zabbix-Agent: Centos 6.8 IP:192.168.126.136
1、安装源码
[root@localhost ~]# rpm -ivh http://repo.zabbix.com/zabbix/2.4/rhel/6/x86_64/zabbix-release-2.4-1.el6.noarch.rpm Retrieving http://repo.zabbix.com/zabbix/2.4/rhel/6/x86_64/zabbix-release-2.4-1.el6.noarch.rpm warning: /var/tmp/rpm-tmp.KgKscI: Header V4 DSA/SHA1 Signature, key ID 79ea5ed4: NOKEY Preparing... ################################# [100%] Updating / installing... 1:zabbix-release-2.4-1.el6 ################################# [100%]
2、安装zabbix客户端
[root@localhost ~]# yum install zabbix-agent -y Loaded plugins: langpacks base | 3.6 kB 00:00:00 docker-main-repo | 2.9 kB 00:00:00 elrepo …………………………………………………………………………………… Installed: zabbix-agent.x86_64 0:2.4.8-1.el6 Dependency Installed: zabbix.x86_64 0:2.4.8-1.el6 Complete!
3、zabbix配置文件
[root@localhost ~]# cd /etc/zabbix/ [root@localhost zabbix]# ls zabbix_agentd.conf zabbix_agentd.d [root@localhost zabbix]# vi zabbix_agentd.conf Server=zbbix server ip ServerActive= zbbix server ip Hostname=本机ip
4、重启服务
[root@localhost zabbix]# service zabbix-agent start Starting zabbix-agent (via systemctl): [ OK ] [root@localhost zabbix]#chkconfig zabbix-agent on