Monitor MongoDB Atlas clusters directly in Zabbix using the official MongoDB Atlas API
- Automated discovery of clusters, nodes, and metrics
- Real-time monitoring of cluster status and availability
- CPU, memory, disk I/O, and network utilization per cluster
- Pre-configured items ready for Zabbix triggers and dashboards
- Zabbix Server 6.x or higher
- MongoDB Atlas account with active API access
- API keys with
Organization MemberorProject Read Onlypermissions - Network access from Zabbix server to
https://cloud.mongodb.com/api/atlas/v2
- Generate a MongoDB Atlas API key:
# Access MongoDB Atlas Console
# Navigate to: Organization Settings > Access Manager > API Keys
# Click "Create API Key"
# Assign permissions: Project Read Only (minimum required)
# Save Public Key and Private Key- Configure the host in Zabbix:
- Host name:
MongoDB Atlas - [Project Name] - Groups:
Cloud ResourcesorDatabases - Interfaces: not required - API-based monitoring
- Set the required macros at host level - recommended over template level for better security and flexibility:
| Macro | Value | Description |
|---|---|---|
{$ATLAS.API.PUBLIC_KEY} |
your-public-key |
MongoDB Atlas API Public Key |
{$ATLAS.API.PRIVATE_KEY} |
your-private-key |
MongoDB Atlas API Private Key |
{$ATLAS.PROJECT_ID} |
project-id |
MongoDB Atlas Project ID |
{$ORG.ID} |
organization-id |
MongoDB Atlas Organization ID |
{$URL.BASE} |
https://cloud.mongodb.com/api/atlas/v2 |
MongoDB Atlas API Base URL |
Available Metrics
Cluster metrics:
- Cluster state (IDLE, CREATING, UPDATING, DELETING)
- Node count and distribution
- MongoDB version
Performance metrics:
- CPU utilization (%)
- Memory usage (bytes)
- Disk IOPS (read/write)
- Network throughput (bytes/sec)
Database operations:
- Operations per second (insert, query, update, delete)
- Query execution time (ms)
- Active connections
- Replication lag (seconds)
Discovery Rules
The template includes Low-Level Discovery (LLD) for clusters, nodes, and databases with active operations. Discovery runs every 1 hour by default - adjust in template settings if needed.
Creating Triggers
Example trigger for high CPU usage:
Name: High CPU utilization on {HOST.NAME}
Expression: last(/MongoDB Atlas Template/atlas.cpu.usage)>80
Severity: Warning
This template builds on previous work from this fork, which adapted the original source. The main contribution here is updating the templates to MongoDB Atlas API v2, as the previous version became incompatible with the current API.
Created by Muller Matos