Monitoring Basics with Zabbix: Install, Triggers, and Dashboards

zabbix



Monitoring Basics with Zabbix: Install, Triggers, and Dashboards

Monitoring Basics with Zabbix: Install, Triggers, and Dashboards

When running production infrastructure, monitoring is non-negotiable. Whether itโ€™s a VPS fleet, a cluster of dedicated servers, or a hybrid setup across colocation and cloud, you need visibility into uptime, performance, and security. Zabbix, a mature open-source monitoring platform, remains one of the most widely used solutions in 2025. Unlike lightweight tools that only show graphs, Zabbix delivers metrics, alerts, triggers, and dashboards with enterprise-level flexibility.

This guide provides a complete introduction to Zabbix monitoring: installation, agent deployment, trigger configuration, and dashboard customization. By the end, youโ€™ll be able to deploy a working Zabbix setup for real-world production monitoring.


๐Ÿ”น Step 1: Install Zabbix Server

Zabbix requires three components: server, database, and frontend.

On Ubuntu/Debian

wget https://repo.zabbix.com/zabbix/7.0/ubuntu/pool/main/z/zabbix-release/zabbix-release_7.0-1+ubuntu22.04_all.deb
sudo dpkg -i zabbix-release_7.0-1+ubuntu22.04_all.deb
sudo apt update
sudo apt install zabbix-server-mysql zabbix-frontend-php zabbix-apache-conf zabbix-sql-scripts zabbix-agent -y

On RHEL/CentOS

sudo rpm -ivh https://repo.zabbix.com/zabbix/7.0/rhel/9/x86_64/zabbix-release-7.0-1.el9.noarch.rpm
sudo dnf clean all
sudo dnf install zabbix-server-mysql zabbix-web-mysql zabbix-apache-conf zabbix-sql-scripts zabbix-agent -y

๐Ÿ”น Step 2: Configure Database

Zabbix supports MySQL/MariaDB and PostgreSQL. Example with MariaDB:

sudo mysql -uroot -p
CREATE DATABASE zabbix CHARACTER SET utf8mb4 COLLATE utf8mb4_bin;
CREATE USER 'zabbix'@'localhost' IDENTIFIED BY 'StrongPassword!';
GRANT ALL PRIVILEGES ON zabbix.* TO 'zabbix'@'localhost';
FLUSH PRIVILEGES;

Import schema:

zcat /usr/share/zabbix-sql-scripts/mysql/server.sql.gz | mysql -uzabbix -p zabbix

Edit /etc/zabbix/zabbix_server.conf:

DBPassword=StrongPassword!

๐Ÿ”น Step 3: Start Zabbix Services

sudo systemctl restart zabbix-server zabbix-agent apache2
sudo systemctl enable zabbix-server zabbix-agent apache2

Access frontend: http://your-server-ip/zabbix

Default login: Admin / zabbix


๐Ÿ”น Step 4: Deploy Zabbix Agent

The agent collects metrics like CPU, RAM, disk, and sends them to the Zabbix server.

# On monitored host
sudo apt install zabbix-agent -y

# Edit config
/etc/zabbix/zabbix_agentd.conf
Server=192.168.1.100   # Zabbix server IP
Hostname=web01

Start agent:

sudo systemctl restart zabbix-agent
sudo systemctl enable zabbix-agent

๐Ÿ”น Step 5: Configure Hosts

In Zabbix frontend:

  • Navigate to Configuration โ†’ Hosts
  • Add a new host: web01
  • Assign group: Linux servers
  • Link template: Linux by Zabbix agent

Once added, metrics should populate within 1โ€“2 minutes.


๐Ÿ”น Step 6: Triggers

Triggers define conditions that raise alerts.

{web01:system.cpu.load[percpu,avg1].last()}>5

This fires when CPU load per core exceeds 5.

Common triggers:

  • Disk usage > 90%
  • Memory usage > 80%
  • Service down (HTTP, MySQL, Nginx)
  • Network latency > 200ms

Set severity (Warning, High, Disaster) and recovery expressions.


๐Ÿ”น Step 7: Notifications

Connect Zabbix to alerting systems:

  • Email (SMTP)
  • Slack/Discord/Telegram via media scripts
  • PagerDuty or OpsGenie

Example Telegram script uses API tokens to deliver real-time alerts.


๐Ÿ”น Step 8: Dashboards

Zabbix 7.0+ features modern dashboards:

  • Widgets for CPU, memory, disk, network
  • Graphs with historical data
  • Maps to visualize server clusters
  • SLA widgets for uptime reporting

Create a dashboard for each environment (staging, prod) with SLA-based views.


๐Ÿ”น Step 9: Advanced Features

  • Proxies โ€“ scale monitoring across remote data centers.
  • Auto-discovery โ€“ automatically add hosts via IP ranges.
  • API โ€“ integrate Zabbix with provisioning tools (Ansible, Terraform).
  • Encryption โ€“ use TLS PSK or certificates for agent communication.

โœ… Conclusion

Zabbix remains one of the most powerful monitoring solutions in 2025. With proper deployment โ€” agents, triggers, dashboards, and notifications โ€” you gain full visibility into infrastructure health. Whether monitoring a single VPS or a dedicated cluster across multiple regions, Zabbix ensures proactive alerts, SLA compliance, and reliable reporting. At WeHaveServers.com, we rely on Zabbix to provide clients with transparent uptime dashboards and real-time infrastructure monitoring.


โ“ FAQ

Is Zabbix better than Prometheus?

Zabbix is stronger for IT infrastructure monitoring (agents, SNMP, uptime), while Prometheus excels at cloud-native metrics and microservices. Many companies use both.

How many servers can Zabbix monitor?

With proxies and database tuning, Zabbix can scale to tens of thousands of monitored hosts.

Can I run Zabbix on a VPS?

Yes. A 2 vCPU / 4GB RAM VPS can monitor dozens of servers. For 500+ hosts, use a dedicated server.

Does Zabbix support Docker/Kubernetes?

Yes, via agent2 with container metrics, or by scraping cAdvisor/Prometheus exporters.

How do I secure Zabbix?

Enable TLS encryption for agent traffic, enforce HTTPS for the frontend, and limit admin access via VPN or firewall.


Leave a Reply

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