Home

Zabbix: IT Infrastructure Monitoring

Monitoring
Difficulty: Advanced
11 min read

Learn how to deploy Zabbix to monitor your infrastructure: server installation, agents, templates, triggers, alerts and dashboards.

Back to tutorials

Key takeaways

  • Size the server at 2 vCPU, 4 GB of RAM and 50 GB of storage minimum, and move to 4 vCPU, 8 GB and SSD storage beyond 500 hosts or offload collection to Zabbix Proxies. Ports to open: 10051 (server), 10050 (agent), 80/443 (frontend).
  • MySQL install gotcha: the database must be created with utf8mb4 COLLATE utf8mb4_bin, and SET GLOBAL log_bin_trust_function_creators = 1 is required to import /usr/share/zabbix-sql-scripts/mysql/server.sql.gz. The frontend then opens with the default credentials Admin / zabbix, which must be changed on first login.
  • The Hostname in /etc/zabbix/zabbix_agent2.conf must match the Host name declared in the frontend exactly, otherwise the host stays without data; check the chain from the server with zabbix_get -s 192.168.1.20 -k agent.ping.
  • Triggers are expressions over the collected data, such as avg(/Linux by Zabbix agent/system.cpu.util,5m)>90 or last(/Linux by Zabbix agent/vfs.fs.size[/,pfree])<10, spread across six severities from Not classified to Disaster that drive actions and escalations.
  • Encrypt agent-server traffic with a pre-shared key: openssl rand -hex 32 | sudo tee /etc/zabbix/zabbix_agent2.psk, then TLSConnect=psk and TLSAccept=psk on the agent plus the same PSK identity in the host Encryption tab in the frontend — both ends must match.
What is Zabbix?
Zabbix is an enterprise-grade open source monitoring solution. It lets you monitor your entire IT infrastructure: servers, network equipment, virtual machines, applications and cloud services. Zabbix collects metrics, detects anomalies and alerts you in real time to guarantee the availability of your systems.

Prerequisites

Before starting the Zabbix installation, make sure you have the following:

  • Linux server: Ubuntu 22.04 LTS or Debian 12 (64-bit architecture recommended)
  • Database: MySQL 8.0+ or PostgreSQL 14+ (PostgreSQL recommended for large environments)
  • Web server: Nginx or Apache with PHP 8.0+
  • Minimum resources: 2 vCPU, 4 GB of RAM, 50 GB of storage
  • Privileges: root or sudo access on the server
  • Network: Port 10051 (Zabbix Server), port 10050 (Zabbix Agent), port 80/443 (Frontend)
Sizing
The required resources depend on the number of monitored hosts. For more than 500 hosts, plan for at least 4 vCPU, 8 GB of RAM and SSD storage. For very large environments, use Zabbix Proxies.

Zabbix architecture

Zabbix is built on a modular architecture made up of several components:

  • Zabbix Server: The central component that receives monitoring data, evaluates triggers and sends alerts. It is the brain of the system.
  • Zabbix Agent: A lightweight daemon installed on each monitored host. It collects local metrics (CPU, memory, disk, network) and forwards them to the server.
  • Zabbix Proxy: An optional intermediate component that collects data on behalf of the server. Ideal for remote sites or distributed environments.
  • Zabbix Frontend: The PHP web interface used to configure monitoring, visualize data and manage alerts.
  • Database: Stores the configuration, the metric history and the events. MySQL or PostgreSQL are supported.

Premium Content

This advanced tutorial is reserved for premium members.

9,90€ / month
  • All advanced tutorials
  • New content every week
  • Progress tracking
  • Cancel anytime
MR

Written by

Morgann Riu

Cybersecurity and Linux administration expert. I share my knowledge through free tutorials and training to help system administrators and developers secure their infrastructures.

Frequently asked questions

What is Zabbix and what is it used for?
Zabbix is an open source monitoring platform that lets you track the status of your servers, network equipment, applications and services in real time. It collects metrics (CPU, RAM, disk, network), detects anomalies through triggers and sends alerts via email, Slack or SMS.
What is the difference between Zabbix Agent and Zabbix Proxy?
Zabbix Agent is installed on each host to be monitored and collects local metrics (CPU, memory, disk). Zabbix Proxy is an intermediate component that collects data from multiple agents and forwards it to the central server, ideal for remote sites or distributed environments with many hosts.
Can Zabbix monitor network equipment via SNMP?
Yes, Zabbix natively supports SNMP v1, v2c and v3 to monitor switches, routers, printers and any SNMP-compatible device. You can query standard or custom OIDs, and Zabbix provides preconfigured SNMP templates for the major vendors.
How do I optimize Zabbix performance with many hosts?
For large environments, use Zabbix Proxies to distribute the load, increase pollers and cache in the server configuration, switch to PostgreSQL with TimescaleDB for better storage performance, and set up partitioning of history tables.
Is Zabbix free and suitable for enterprises?
Yes, Zabbix is fully open source and free under the GPL v2 license. There is no limit on the number of monitored hosts. The Zabbix company offers optional commercial support. Enterprises monitor tens of thousands of hosts with Zabbix in production.
How do I secure communication between the Zabbix Server and the agents?
Zabbix supports native TLS encryption between the server, proxies and agents. You can use certificates or pre-shared keys (PSK). Configure TLSConnect and TLSAccept in the configuration files to enable end-to-end encryption.

Share this tutorial

Did you enjoy this article?

Was this article helpful?

Thanks for your feedback!

Comments

Recommended for you

In-depth article on the topic

Checklist Sécurité Linux

30 points essentiels pour sécuriser un serveur Linux. Recevez aussi les nouveaux tutoriels par email.

Pas de spam. Désabonnement en 1 clic.

↑