centos7 安装 zabbix4.2

Zabbix Server 安装

1.Install Zabbix repository

rpm -Uvh https://repo.zabbix.com/zabbix/4.2/rhel/7/x86_64/zabbix-release-4.2-1.el7.noarch.rpm
yum clean all

2.Install Zabbix server, frontend
yum install mariadb-server zabbix-web-mysql zabbix-server-mysql (for RHEL 7)
systemctl start mariadb.service

3.Create initial database
mysql -uroot -p
password

mysql> create database zabbix character set utf8 collate utf8_bin;
mysql> grant all privileges on zabbix.* to zabbix@localhost identified by ‘password’;
mysql> quit;

zcat /usr/share/doc/zabbix-server-mysql*/create.sql.gz | mysql -uzabbix -p zabbix

4.Configure the database for Zabbix server
vi /etc/zabbix/zabbix_server.conf
DBHost=localhost
DBName=zabbix
DBUser=zabbix
DBPassword=

5.Configure PHP for Zabbix frontend
vi /etc/httpd/conf.d/zabbix.conf
Edit file /etc/httpd/conf.d/zabbix.conf, uncomment and set the right timezone for you.
php_value date.timezone Europe/Riga

6.Start Zabbix server and agent processes

systemctl start zabbix-server
systemctl enable zabbix-server
systemctl enable mariadb
systemctl start httpd
systemctl enable httpd

安装Zabbix agent

1.Install the Zabbix agent from the package manager:
rpm -Uvh https://repo.zabbix.com/zabbix/4.2/rhel/7/x86_64/zabbix-release-4.2-1.el7.noarch.rpm
yum clean all
yum install zabbix-agent

2.Edit the Zabbix agent configuration file and add or change the following settings
vi /etc/zabbix/zabbix_agentd.conf
Server=
ServerActive=

3.start the Zabbix agent:
systemctl start zabbix-agent
systemctl enable zabbix-agent

参考:
https://www.zabbix.com/download

你可能感兴趣的:(zabbix)