Zabbix Server 5.0 Installation Tutorial for Ubuntu 20.04

Zabbix Server 5.0 Installation Tutorial for Ubuntu 20.04

Zabbix is an open-source monitoring and management solution that provides real-time visibility into the performance and health of IT infrastructure, networks, applications, and services. It enables organizations to monitor various aspects of their systems, including servers, network devices, databases, and more, by collecting and analyzing data on metrics such as CPU usage, memory, network traffic, and response times. Zabbix offers a centralized platform for proactive monitoring, alerting administrators of potential issues or anomalies, facilitating troubleshooting, and helping ensure the reliability and optimal performance of critical IT resources.

Pre-Requsities of Zabbix Installation

Before installing Zabbix, there are several prerequisites that you need to have in place to ensure a smooth installation and operation of the monitoring system. Here are the main prerequisites:

  1. Supported Operating System: Zabbix supports a variety of operating systems, including various Linux distributions, Windows, and others. Make sure to choose a supported operating system that fits your requirements.
  2. Hardware Requirements: The hardware requirements depend on the size of your environment and the number of monitored devices. Generally, you’ll need a server with sufficient CPU, RAM, and storage to handle the monitoring tasks.
  3. Database: Zabbix requires a relational database management system (RDBMS) to store configuration data, metrics, and other information. It supports databases like MySQL, PostgreSQL, Oracle, and SQLite. Ensure you have a compatible and properly configured database server.
  4. Web Server: Zabbix provides a web-based frontend for configuration and visualization. You’ll need a web server like Apache or Nginx to host the frontend.
  5. PHP: The Zabbix frontend is built using PHP, so you’ll need a compatible PHP version installed on your server.
  6. Database User and Schema: You need to create a dedicated user and schema in the database for Zabbix. The user should have appropriate permissions to create tables, modify data, and perform other necessary operations.
  7. Network Configuration: Ensure that the necessary network ports are open between Zabbix components (server, frontend, agents, proxies, etc.). The default port for the Zabbix server is 10051, and for the frontend, it’s typically 80 or 443.
  8. Time Synchronization: Accurate time synchronization across all components is crucial for correct data collection and correlation in Zabbix. Consider using NTP (Network Time Protocol) to ensure consistent time across your systems.
  9. Dependencies: Zabbix has dependencies on various libraries and packages. Make sure you have these dependencies installed before installing Zabbix.
  10. System Updates: Ensure your operating system is up to date with the latest patches and updates before installing Zabbix.
  11. Firewall and Security: Configure your firewall settings to allow the necessary traffic for Zabbix components to communicate. Also, follow best practices for securing your Zabbix installation, including using strong passwords, disabling unnecessary services, and regularly updating software.
  12. DNS Resolution: Make sure that DNS resolution is working correctly for all involved systems, as Zabbix components often rely on hostnames for communication.
  13. User Privileges: You’ll need administrative privileges to install software, configure the database, and make system-level changes.

Remember that these prerequisites may vary based on your specific setup and requirements. Always refer to the official Zabbix documentation for the most accurate and up-to-date information on prerequisites for your chosen Zabbix version and components.

apt update
apt install apache2 libapache2-mod-php
apt install mysql-server
apt install php php-mbstring php-gd php-xml php-bcmath php-ldap php-mysql

The MySQL root user’s password needs to be strong, so do that next. Run the command below and adhere to the instructions. You will obtain a password for the root account of the MySQL database server once you have finished the command listed below.


The PHP configuration variables are updated. For Apache, modify the PHP configuration file located at /etc/php/7.4/apache2/php.ini and change the timezone as necessary.

vim /etc/php/7.4/apache2/php.ini
memory_limit 256M
upload_max_filesize 16M
post_max_size 16M
max_execution_time 300
max_input_time 300
max_input_vars 10000
date.timezone = 'Asia/Kolkata'

Configure Zabbix Repository

dpkg -i zabbix-release_5.0-1+focal_all.deb

Installing Zabbix Server

Add Zabbix repository and install the Zabbix server and frontend packages:

apt update
apt install zabbix-server-mysql zabbix-frontend-php zabbix-agent zabbix-apache-conf

Create Zabbix Database and User

The Zabbix server’s database schema should then be created. Use the root account to log onto the MySQL server and issue the following commands to create a MySQL database and user.

$ mysql -u root -p

mysql> CREATE DATABASE zabbixdb character set utf8 collate utf8_bin;
mysql> CREATE USER 'zabbix'@'localhost' IDENTIFIED BY 'password';
mysql> GRANT ALL PRIVILEGES ON zabbixdb.* TO 'zabbix'@'localhost' WITH GRANT OPTION;

Load the Zabbix default schema into the database after it has been created.

cd /usr/share/doc/zabbix-server-mysql
zcat create.sql.gz | mysql -u zabbix -p zabbixdb

Update Zabbix Configuration

Update the following database configurations by editing the Zabbix server configuration file /etc/zabbix/zabbix_server.conf in your preferred text editor. The Zabbix server will connect to the database using this.

$ vim /etc/zabbix/zabbix_server.conf

The Zabbix service should now be set to launch during system startup. Restart the service to apply any changes.

systemctl enable zabbix-server
systemctl restart zabbix-server

The Zabbix package also builds a connection to the Apache configuration directory and creates its own Apache configuration file, /etc/zabbix/apache.conf. Using the next command, let’s restart the Apache service.

systemctl restart apache2

Your system is now prepared for the installation of Zabbix. Simply complete the installation by visiting the Zabbix web installer.

Running Zabbix Web Installer

On the IP address or domain of your server, go to the /zabbix subdirectory URL to access the Zabbix online installer. As an illustration, directs visitors to my Zabbix server. Now go to the following URL to visit Zabbix. Change the FQDN according to your setup.


And then follow the instructions as shown in the screenshots below.

Open your preferred web browser now and type http://your-server-ip/zabbix into the address bar. The next screen will bring you to the Zabbix web installation wizard:

1.zabbix installation welcome

Select the Next action button. Please view the following page:

2.zabbix installer pre requisities ubuntu 20.04

Verify that the server has met all of the requirements. then select the button labeled “Next step.” Please view the following page:

3.zabbix installer db connection ubuntu 20.04

Click the Next step button after entering the database credentials you created in the previous steps. Please view the following page:

4.zabbix installer server details ubuntu 20.04 1

Enter the information for your Zabbix server, then click the Next step button. Please view the following page:

Verify that all setup settings are accurate before selecting the Next step button. When the installation is successful, the following page ought to appear:
Select “Finish” from the menu. You will be taken to the Zabbix login screen, which is displayed below:

To log in, use the credentials listed below:

Username: Admin
Password: zabbix
5.zabbix server login ubuntu 20.04

You will see the Zabbix dashboard as seen in the screenshot below after a successful login.

6.zabbix server dashboard ubuntu 20 04


In conclusion, Zabbix Server 5.0 stands as a robust and versatile open-source monitoring solution that empowers organizations to effectively monitor their IT infrastructure, applications, and services. With its real-time visibility, automated alerts, and comprehensive reporting capabilities, Zabbix facilitates proactive management by detecting and addressing issues before they impact operations. The latest iteration, version 5.0, further enhances its capabilities with improved performance, enhanced security features, and a user-friendly interface. Whether for small-scale setups or complex enterprise environments, Zabbix Server 5.0 offers a powerful toolset for maintaining the health, performance, and reliability of critical IT resources.

Follow us TwitterFacebookLinkedIn

Open Source Listing

Previous Post
Next Post

Leave a Reply