docker.recipes

Checkmk Monitoring

intermediate

Checkmk infrastructure monitoring platform.

Overview

Checkmk is a comprehensive infrastructure monitoring platform originally based on Nagios Core, developed to address the limitations of traditional monitoring systems. Born from the need for better scalability and usability, Checkmk combines active monitoring checks with passive monitoring agents to provide real-time visibility into servers, network devices, applications, and cloud resources. The platform includes both a modern web interface and powerful alerting capabilities that go far beyond basic Nagios functionality. This Docker deployment creates a complete Checkmk RAW monitoring environment with persistent data storage and proper networking isolation. The containerized setup includes the core monitoring engine, web interface, notification system, and all necessary dependencies in a single cohesive stack. The configuration uses tmpfs mounting for temporary files to optimize performance while maintaining data persistence for monitoring configurations and historical data. This stack is ideal for system administrators transitioning from traditional monitoring solutions, DevOps teams needing comprehensive infrastructure visibility, and organizations requiring enterprise-grade monitoring without licensing costs. The Checkmk RAW edition provides powerful monitoring capabilities including distributed monitoring, business intelligence features, and extensive plugin ecosystem, making it suitable for environments ranging from small business networks to large enterprise infrastructures.

Key Features

  • Native Nagios plugin compatibility with extended check capabilities and performance data collection
  • Agent-based and agentless monitoring with automatic service discovery for Linux, Windows, and network devices
  • Built-in business intelligence dashboards with customizable views and reporting capabilities
  • Multi-site distributed monitoring architecture for geographically dispersed infrastructure
  • Integrated notification system with email, SMS, and webhook support for escalation management
  • Performance graphing with RRDtool integration and long-term trend analysis
  • Flexible alerting rules engine with time-based conditions and maintenance window support
  • REST API for automation and integration with external systems and configuration management tools

Common Use Cases

  • 1Enterprise network monitoring with automated discovery of servers, switches, and network infrastructure
  • 2Application performance monitoring for web services, databases, and custom business applications
  • 3Cloud infrastructure monitoring across AWS, Azure, and Google Cloud Platform resources
  • 4Compliance monitoring for security policies, system updates, and configuration drift detection
  • 5MSP monitoring deployments with multi-tenant site management and customer separation
  • 6DevOps pipeline monitoring for CI/CD infrastructure, build servers, and deployment environments
  • 7Industrial IoT monitoring for manufacturing equipment, sensors, and operational technology networks

Prerequisites

  • Minimum 4GB RAM recommended for monitoring up to 1000 hosts with historical data retention
  • Docker Engine 20.10+ with Docker Compose V2 for proper tmpfs and volume mounting support
  • Port 8080 available for web interface access and agent communication
  • Basic understanding of SNMP, SSH, and network monitoring concepts for host configuration
  • Administrative access to target systems for agent installation and monitoring setup

For development & testing. Review security settings, change default credentials, and test thoroughly before production use. See Terms

docker-compose.yml

docker-compose.yml
1services:
2 checkmk:
3 image: checkmk/check-mk-raw:latest
4 container_name: checkmk
5 restart: unless-stopped
6 ports:
7 - "${CHECKMK_PORT:-8080}:5000"
8 environment:
9 - CMK_SITE_ID=${SITE_ID:-cmk}
10 - CMK_PASSWORD=${ADMIN_PASSWORD:-cmkadmin}
11 volumes:
12 - checkmk_data:/omd/sites
13 tmpfs:
14 - /opt/omd/sites/cmk/tmp:uid=1000,gid=1000
15 networks:
16 - checkmk-network
17
18volumes:
19 checkmk_data:
20
21networks:
22 checkmk-network:
23 driver: bridge

.env Template

.env
1# Checkmk
2CHECKMK_PORT=8080
3SITE_ID=cmk
4ADMIN_PASSWORD=cmkadmin

Usage Notes

  1. 1Checkmk at http://localhost:8080/cmk
  2. 2Login: cmkadmin/cmkadmin
  3. 3Install agents on hosts
  4. 4Based on Nagios

Quick Start

terminal
1# 1. Create the compose file
2cat > docker-compose.yml << 'EOF'
3services:
4 checkmk:
5 image: checkmk/check-mk-raw:latest
6 container_name: checkmk
7 restart: unless-stopped
8 ports:
9 - "${CHECKMK_PORT:-8080}:5000"
10 environment:
11 - CMK_SITE_ID=${SITE_ID:-cmk}
12 - CMK_PASSWORD=${ADMIN_PASSWORD:-cmkadmin}
13 volumes:
14 - checkmk_data:/omd/sites
15 tmpfs:
16 - /opt/omd/sites/cmk/tmp:uid=1000,gid=1000
17 networks:
18 - checkmk-network
19
20volumes:
21 checkmk_data:
22
23networks:
24 checkmk-network:
25 driver: bridge
26EOF
27
28# 2. Create the .env file
29cat > .env << 'EOF'
30# Checkmk
31CHECKMK_PORT=8080
32SITE_ID=cmk
33ADMIN_PASSWORD=cmkadmin
34EOF
35
36# 3. Start the services
37docker compose up -d
38
39# 4. View logs
40docker compose logs -f

One-Liner

Run this command to download and set up the recipe in one step:

terminal
1curl -fsSL https://docker.recipes/api/recipes/checkmk-monitoring/run | bash

Troubleshooting

  • CMK site creation fails with permission errors: Ensure Docker has sufficient permissions and tmpfs is properly mounted with correct uid/gid
  • Web interface shows 'Site not started' error: Check container logs for OMD service status and restart the container if necessary
  • Agent discovery fails to find services: Verify network connectivity and ensure monitoring agents are properly installed with correct site configuration
  • Performance graphs not displaying data: Check RRDtool permissions in the data volume and verify check intervals are configured correctly
  • Email notifications not sending: Configure SMTP settings in the site configuration and test mail server connectivity from container
  • High memory usage during large environment discovery: Increase container memory limits and consider adjusting discovery check intervals

Community Notes

Loading...
Loading notes...

Download Recipe Kit

Get all files in a ready-to-deploy package

Includes docker-compose.yml, .env template, README, and license

Ad Space