zabbix-proxy的安装以及使用

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了zabbix-proxy的安装以及使用相关的知识,希望对你有一定的参考价值。

############yum源#############
[[email protected] zabbix]# cat /etc/yum.repos.d/zabbix.repo
[zabbix]
name=Zabbix Official Repository - $basearch
baseurl=http://repo.zabbix.com/zabbix/3.4/rhel/7/$basearch/
enabled=1
gpgcheck=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-ZABBIX-A14FE591
[zabbix-non-supported]
name=Zabbix Official Repository non-supported - $basearch
baseurl=http://repo.zabbix.com/non-supported/rhel/7/$basearch/
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-ZABBIX
gpgcheck=0
[[email protected] zabbix]#

###########安装#############
yum install zabbix-proxy mariadb mariadb-server -y
systemctl start mariadb
systemctl enable mariadb
mysql_secure_installation
create database zabbix-proxy character set utf8 collate utf8_bin;
grant all on zabbix-proxy. to [email protected]‘localhost‘ identified by ‘123456‘;
grant all on zabbix-proxy.
to zabbix-proxy@‘localhost‘ identified by ‘123456‘;
zcat schema.sql.gz |mysql -uzabbix-proxy -p123456 -h 127.0.0.1 zabbix-proxy

#########配置文件##############
[[email protected] zabbix]# grep -E "^[a-Z]" /etc/zabbix/zabbix_proxy.conf
ProxyMode=0 ##主动模式 zabbix-proxy主动给sever端
Server=192.168.249.10 ##zabbix-server的地址
Hostname=zabbix-proxy ##server添加的时候用的到
LogFile=/var/log/zabbix/zabbix_proxy.log
LogFileSize=0
PidFile=/var/run/zabbix/zabbix_proxy.pid
SocketDir=/var/run/zabbix
DBName=zabbix-proxy
DBUser=zabbix-proxy
DBPassword=123456
SNMPTrapperFile=/var/log/snmptrap/snmptrap.log
Timeout=4
ExternalScripts=/usr/lib/zabbix/externalscripts
LogSlowQueries=3000
[[email protected] zabbix]#

##########启动#######################
systemctl start zabbix-proxy
systemctl enable zabbix-proxy

以上是关于zabbix-proxy的安装以及使用的主要内容,如果未能解决你的问题,请参考以下文章

zabbix的自动注册(Auto registration),使用proxy实现

zabbix-proxy安装部署

zabbix-proxy+cacti+nagios基本安装配置

zabbix-proxy安装

docker安装zabbix-proxy

zabbix-proxy的安装