Commandes pour Installer le Serveur Zabbix sur Rocky Linux

sudo dnf update & sudo dnf upgrade -y

sudo dnf install httpd -y
sudo systemctl start httpd
sudo systemctl enable httpd

sudo firewall-cmd --permanent --zone=public --add-service=http
sudo firewall-cmd --permanent --zone=public --add-service=https
sudo firewall-cmd --reload

sudo dnf install mysql-server -y
sudo systemctl start mysqld.service
sudo systemctl enable mysqld.service
sudo systemctl status mysqld.service
sudo mysql_secure_installation

sudo rpm -Uvh https://repo.zabbix.com/zabbix/6.4/rhel/9/x86_64/zabbix-release-6.4-1.el9.noarch.rpm

sudo dnf install zabbix-server-mysql zabbix-web-mysql zabbix-apache-conf zabbix-sql-scripts zabbix-selinux-policy zabbix-agent

mysql -uroot -p
create database zabbix character set utf8mb4 collate utf8mb4_bin;
create user zabbix@localhost identified by 'password';
grant all privileges on zabbix.* to zabbix@localhost;
set global log_bin_trust_function_creators = 1;
quit;

sudo zcat /usr/share/zabbix-sql-scripts/mysql/server.sql.gz | mysql --default-character-set=utf8mb4 -uzabbix -p zabbix

mysql -uroot -p
set global log_bin_trust_function_creators = 0;
quit;


sudo systemctl restart zabbix-server zabbix-agent httpd php-fpm
sudo systemctl enable zabbix-server zabbix-agent httpd php-fpm

sudo firewall-cmd --zone=public --permanent --add-port=10050/tcp
sudo firewall-cmd --zone=public --permanent --add-port=10051/tcp
sudo firewall-cmd --reload

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.