====================
1.CentOS release 5
====================
1-1.centos5 32位
[root@LV zabbix]# cat /etc/redhat-release
CentOS release 5 (Final)
[root@LV zabbix]# uname -a
Linux LV 2.6.18-53.el5xen #1 SMP Mon Nov 12 03:26:12 EST 2007 i686 i686 i386 GNU/Linux
确定了系统centos5 32位
rpm方式安装(要找对系统版本和zabbix版本)
https://mirrors.tuna.tsinghua.edu.cn/zabbix/zabbix/3.2/rhel/5/i386/
下载zabbix-agent版本
zabbix-agent-3.2.0-1.el5.i386.rpm 358.3 KiB 2016-11-15 02:09
zabbix-agent-3.2.1-1.el5.i386.rpm 359.4 KiB 2016-11-15 02:09
zabbix-agent-3.2.10-1.el5.i386.rpm 371.9 KiB 2017-11-08 22:10
zabbix-agent-3.2.10-2.el5.i386.rpm 372.0 KiB 2017-11-09 20:01
zabbix-agent-3.2.11-1.el5.i386.rpm 373.9 KiB 2017-12-27 23:36
zabbix-agent-3.2.2-1.el5.i386.rpm 364.1 KiB 2016-12-14 20:57
zabbix-agent-3.2.3-1.el5.i386.rpm 365.0 KiB 2016-12-22 14:28
zabbix-agent-3.2.4-1.el5.i386.rpm 359.0 KiB 2017-03-21 23:19
zabbix-agent-3.2.5-1.el5.i386.rpm 360.6 KiB 2017-04-26 08:37
zabbix-agent-3.2.6-1.el5.i386.rpm 361.6 KiB 2017-05-06 21:51
zabbix-agent-3.2.7-1.el5.i386.rpm 367.0 KiB 2017-07-20 15:11
zabbix-agent-3.2.8-1.el5.i386.rpm 369.5 KiB 2017-09-27 05:59
我下载的是zabbix-agent-3.2.10-1.el5.i386.rpm
rpm -ivh zabbix-agent-3.2.10-1.el5.i386.rpm
修改配置文件(Server指定zabbix服务器IP地址,Hostname可以指定本机名)
[root@localhost ~]# vi /etc/zabbix/zabbix_agentd.conf
Server=10.1.88.200 #填写zabbix_server地址
ServerActive=10.1.88.200 #填写zabbix_server地址
Hostname=redhat5 #填写本机地址
zabbix_agentd -c /etc/zabbix/zabbix_agentd.conf 开启
关闭服务
ps -ef | grep zabbix
killall -9 zabbix_agentd
sed -i "s/^Server=127.0.0.1/Server=10.23.7.88/g" /etc/zabbix/zabbix_agentd.conf
sed -i "s/^ServerActive=127.0.0.1/ServerActive=10.23.7.88/g" /etc/zabbix/zabbix_agentd.conf
sed -i "s/Hostname=Zabbix server/Hostname=10.23.7.66/g" /etc/zabbix/zabbix_agentd.conf
1-2 redhat 5.7 64位
下载
https://mirrors.tuna.tsinghua.edu.cn/zabbix/zabbix/3.2/rhel/5/x86_64/
zabbix-agent-3.2.10-2.el5.x86_64.rpm
rpm -ivh zabbix-agent-3.2.10-2.el5.x86_64.rpm
修改配置文件(Server指定zabbix服务器IP地址,Hostname可以指定本机名)
[root@localhost ~]# vi /etc/zabbix/zabbix_agentd.conf
Server=10.1.88.200 #填写zabbix_server地址
ServerActive=10.1.88.200 #填写zabbix_server地址
Hostname=redhat5 #填写本机地址
zabbix_agentd -c /etc/zabbix/zabbix_agentd.conf 开启
==============================
2.centos 6-64位安装
==============================
需要解决依赖问题:
安装提示libcrypto.so.10被需要
我们使用openssl version看一下版本,
[root@bjgenlotGW-2-42 ~]# openssl version
OpenSSL 1.1.1 11 Sep 2018
比需要的高 如果降低openssl的版本,还有好多系统程序,依赖OpenSSL 1.1.1
另一台设备是openssl 1.0.0 都不是所需要的openssl1.0.1
我们下载openssl-1.0.1e-57.el6.x86_64.rpm 我将这个放到了百度网盘里,后期可以搜索下载。
rpm -U openssl-1.0.1e-57.el6.x86_64.rpm升级openssl
rpm -ivh zabbix-agent-6.4.1-rc1.release1.el6.x86_64.rpm
修改配置文件(Server指定zabbix服务器IP地址,Hostname可以指定本机名)
[root@localhost ~]# vi /etc/zabbix/zabbix_agentd.conf
Server=10.1.88.200 #填写zabbix_server地址
ServerActive=10.1.88.200 #填写zabbix_server地址
Hostname=redhat5 #填写本机地址
zabbix_agentd -c /etc/zabbix/zabbix_agentd.conf 开启
===================
3.centos 7-64位安装
===================
直接安装即可
rpm -ivh zabbix-agent-6.4.1-rc1.release1.el6.x86_64.rpm
修改配置文件(Server指定zabbix服务器IP地址,Hostname可以指定本机名)
[root@localhost ~]# vi /etc/zabbix/zabbix_agentd.conf
Server=10.1.88.200 #填写zabbix_server地址
ServerActive=10.1.88.200 #填写zabbix_server地址
Hostname=redhat5 #填写本机地址
zabbix_agentd -c /etc/zabbix/zabbix_agentd.conf 开启
4.windows 安装
下载windows zabbix agent
https://www.zabbix.com/cn/download_agents 可能需要翻墙
本文使用的是:链接:https://pan.baidu.com/s/1bzCuDdMP9_halTcrt54Scw
提取码:4v66
解压后
修改conf下配置文件zabbix_agentd.win.conf。
LogFile=e:\zabbix\logs\zabbix_agentd.log #自己定义
#Server = zabbix-server安装的ip地址。
Server=10.23.7.88
ServerActive=10.23.7.88
Hostname=10.23.7.93
我的操作是将zabbix_agentd.exe和\zabbix_agentd.win.conf(改名为\zabbix_agentd.conf)放到了e:\zabbix目录下
下载后使用如下命令安装
cmd
e:
安装
E:\zabbix>zabbix_agentd.exe -i -c e:\zabbix\zabbix_agentd.conf
zabbix_agentd.exe [2948]: service [Zabbix Agent] installed successfully
zabbix_agentd.exe [2948]: event source [Zabbix Agent] installed successfully
卸载
E:\zabbix>zabbix_agentd.exe -d -c e:\zabbix\zabbix_agentd.conf
zabbix_agentd.exe [3888]: service [Zabbix Agent] uninstalled successfully
zabbix_agentd.exe [3888]: event source [Zabbix Agent] uninstalled successfully
启动
E:\zabbix>zabbix_agentd.exe -s -c e:\zabbix\zabbix_agentd.conf
zabbix_agentd.exe [2224]: service [Zabbix Agent] started successfully
E:\zabbix>
注意:安装时报错如下 :缺少libcrypto-1_1-x64.dll
下载链接:https://pan.baidu.com/s/15hNP0P0JunSQuvZaZVPljw 提取码:47d4下载即可
报错2:
[root@ZB-YTH-Market-1 ~]# rpm -ivh zabbix-agent-6.0.0-1.el7.x86_64.rpm
警告:zabbix-agent-6.0.0-1.el7.x86_64.rpm: 头V4 RSA/SHA512 Signature, 密钥 ID a14fe591: NOKEY
错误:依赖检测失败:
libpcre2-8.so.0()(64bit) 被 zabbix-agent-6.0.0-1.el7.x86_64 需要
Index of /linux/centos/7.9.2009/os/x86_64/Packages下载pcre2-10.23-2.el7.x86_64 .rpm
rpm安装即开