VMware

How to install Zabbix ver 7.x on Debian 12.x



00:00 How to install Zabbix ver 7.x on Debian 12.x

=============================================================================
How to Install and Configure Zabbix v7.x on Debian 12 (Bookworm)
=============================================================================
=== Download Debian 12 ===

Download Debian 12 64-bit from following website

==== Debian 12 Installation ====
7:30 Hostname section
11:22 Software selection Section
=============================================================================
=== PHP version ===

The default version of PHP to install on Debian 12 is version 8.2

To install ver 8.3, SURY PHP PPA repository must be added
=============================================================================
update Debian 12 packages
=============================================================================
switch to the root user by (su -) command

update software repositories packages

apt update
apt upgrade

=============================================================================
16:20 install prerequisites packages
=============================================================================
apt install sudo
apt install net-tools
apt install curl wget zip git build-essential

=============================================================================
17:51 install Apache and MySQL packages
=============================================================================

apt install apache2 mariadb-server mariadb-client

=============================================================================
18:20 install PHP packages
=============================================================================

apt install php php-mysql php-common php-cli php-common php-json php-opcache php-readline php-mbstring php-gd php-dom php-zip php-curl

Verify php version

php -v

=============================================================================
19:30 Install Zabbix repository
=============================================================================
wget
dpkg -i zabbix-release_7.0-2+debian12_all.deb
apt update

=============================================================================
21:00 Install Zabbix server, frontend, agent
=============================================================================
apt install zabbix-server-mysql zabbix-frontend-php zabbix-apache-conf zabbix-sql-scripts zabbix-agent

=============================================================================
22:00 Create initial database
=============================================================================

mysql_secure_installation

Switch to unix_socket authentication [Y/n] n
Change the root password? [Y/n] y
Remove anonymous users? [Y/n] y
Disallow root login remotely? [Y/n] n
Remove test database and access to it? [Y/n] y
Reload privilege tables now? [Y/n] y

Run the following command to login into MySQL:

mysql -u root -p

create database ZABBIXDATABASE character set utf8mb4 collate utf8mb4_bin;
create user ZABBIXUSER@localhost identified by ‘P@$$W0RD’;
grant all privileges on ZABBIXDATABASE.* to ZABBIXUSER@localhost;
set global log_bin_trust_function_creators = 1;
quit;

=== To verify Database ===

SHOW DATABASES;

=== To verify user permision ===

SHOW GRANTS FOR ‘ZABBIXUSER’@localhost;
=============================================================================
28:07 import initial schema and data. You will be prompted to enter your ZABBIXUSER password.
=============================================================================

zcat /usr/share/zabbix-sql-scripts/mysql/server.sql.gz | mysql –default-character-set=utf8mb4 -uZABBIXUSER -p ZABBIXDATABASE

Then type your created ZABBIXUSER password

30:45 The password that you set should be ZABBIXUSER password (P@$$W0RD) NOT mysql root password

mysql -u root -p

set global log_bin_trust_function_creators = 0;
quit;
=============================================================================
31:35 Configure the database for Zabbix server
=============================================================================
Edit file /etc/zabbix/zabbix_server.conf by nano

DBName=ZABBIXDATABASE
DBUser=ZABBIXUSER
DBPassword=P@$$W0RD

=============================================================================
35:30 Start Zabbix server and agent processes
=============================================================================
systemctl restart zabbix-server zabbix-agent apache2
systemctl enable zabbix-server zabbix-agent apache2

37:21 set my Zabbix Database information
38:00 set Zabbix Server host name

39:30 log in to Zabbix by default account

default user=Admin
password=zabbix
pass zabbix



source

Related Articles

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button