Zabbix server environment platform
Version: ZABBIX version 4.4
System: CentOS8.0.1905
Database: Mysql-server-8.0.17
Install CentOS8 yum source
# cd /etc/yum.repos.d/
# rm -f CentO*.repo
# curl -o CentOS-Base.repo https://raw.githubusercontent.com/hackyoMa/docker-centos/8/CentOS-Base.repo
# yum makecache
Install zabbix yum source
# rpm -Uvh https://repo.zabbix.com/zabbix/4.4/rhel/8/x86_64/zabbix-release-4.4-1.el8.noarch.rpm
# dnf clean all
Install Zabbix server, web front end, agent
# dnf -y install zabbix-server-mysql zabbix-web-mysql zabbix-apache-conf zabbix-agent
Create the initial database
# sudo yum -y install @mysql:8.0
Activate MySQL service:
sudo systemctl status --now mysql
Confirm service status:
sudo systemctl status mysqld
Initialize MySQL database
mysql_secure_installation
Note, please make sure:
Set the password of the root user of the database. Delete anonymous users. Forbid root user to log in remotely. Delete the test database and access it.
MySQL user root test access permissions:
# mysql -uroot -p
password
Create database
mysql> create database zabbix character set utf8 collate utf8_bin;
Create user
mysql> create user 'zabbix'@'%' identified by 'zabbix_Password'
Authorized user
mysql> grant all privileges on zabbix.* to 'zabbix'@'%'with grant option;
mysql> flush privileges;
mysql> quit;
Import the initial structure and data, the system will prompt you to enter the newly created password.
# zcat /usr/share/doc/zabbix-server-mysql*/create.sql.gz | mysql -uzabbix -p zabbix
Configure database for Zabbix server
Edit the configuration file /etc/zabbix/zabbix_server.conf
DBPassword=password
Configure PHP for Zabbix frontend
Edit the configuration file /etc/php-fpm.d/zabbix.conf
, uncomment and set the correct time zone
; php_value[date.timezone]= Asia/Shanghai
Start the Zabbix server and agent processes, and set them to start at boot:
# systemctl restart zabbix-server zabbix-agent httpd php-fpm
# systemctl enable zabbix-server zabbix-agent httpd php-fpm
Now your Zabbix server has been installed and started to run
Configure Zabbix frontend
Reference: https://www.zabbix.com/documentation/4.4/manual/installation/install#installing_frontend
Connect to the newly installed Zabbix frontend: http://server_ip_or_name/zabbix
Follow the steps in the Zabbix file: Install the front end
Can be viewed through the user data table
Default account: Admin default password: zabbix
Summary: During the execution of zcat /usr/share/doc/zabbix-server-mysql*/create.sql.gz | mysql -uzabbix -p zabbix
Encountered the following problem: Error 1046(3D000) No database selected
The above is the CentOS 8.0.1905 installation ZABBIX4.4 introduced by the editor to you. I hope it will be helpful to you. If you have any questions, please leave me a message, and the editor will reply to you in time. Thank you very much for your support to the ZaLou.Cn website!
If you think this article is helpful to you, welcome to reprint, please indicate the source, thank you!
Recommended Posts