How-to monitor the site processes
This article applies to Checkmk versions up to 2.3.0pX. Starting with Checkmk 2.4.0, this information is no longer relevant and can be safely ignored for newer versions, as there is now a built-in process monitoring.
Those manually created rules up to 2.3.0pX won't be removed automatically when upgrading to 2.4.0 and have to be removed manually.
Also, it's recommended to remove these process discovery rules, as this will only cause confusion with the built-in process discovery rules. Please make sure to update all other places in the Setup menu wherever those process names are being referred.
Step-by-step guide
To configure all relevant site processes to be monitored, follow these steps:
Create a Process discovery rule:
- The Process name is:
"%u/%1%2" - The regular expression is:
(?:(?:python3 |\/usr\/sbin\/apache2 -f )*\/omd\/sites\/\w+\/.*?(checkhelper|icmpreceiver|apache|--create-rrd|--handle-alerts|(?:mk)*notifyd(?:d)*|--notify|--checker|--real-time-checks|fetcher|mkeventd|rrdcached|redis|cmc |icmpsender)|(dcd|gunicorn|liveproxyd))
Make sure to enable the "Grab user from found processes" option.
The rule should match your Checkmk server hosts.
.
- The Process name is:
After saving and activating the changes, do a service discovery on your Checkmk server hosts. There, you will see a bunch of services to be added:
Click on “Accept all” to add them to the monitoring.
After activating the changes, your site's processes will be monitored in a basic way, already..
- Some of these processes should only run once, so let's add a "State and count of processes" rule for them:
Alternative regular expressions for monitoring particular Site processes
We recommend monitoring all site processes, but if you want to pick particular sets of processes, you can use these regular expressions:
Component | Regular Expression |
---|---|
Active check helpers | \/omd\/sites\/\w+\/lib\/cmc\/(checkhelper) |
Agent receiver | (gunicorn) |
Alert handler | python3 \/omd\/sites\/\w+\/bin\/cmk .*?(--handle-alerts) |
Checkers | python3 \/omd\/sites\/\w+\/bin\/cmk .*?(--checker) |
DCD | (dcd) |
Event console | python3 \/omd\/sites\/\w+\/bin\/(mkeventd) |
Fetchers | python3 \/omd\/sites\/\w+\/bin\/(fetcher) |
ICMP receiver | \/omd\/sites\/\w+\/lib\/cmc\/(icmpreceiver) |
ICMP sender | \/omd\/sites\/\w+\/lib\/cmc\/(icmpsender) |
Liveproxy daemon | (liveproxyd) |
Microcore | \/omd\/sites\/\w+\/bin\/(cmc) |
Notification helpers | python3 \/omd\/sites\/\w+\/bin\/cmk .*?(--notify) |
Notification spooler | python3 \/omd\/sites\/\w+\/bin\/(mknotifyd) |
RRD cache daemon | \/omd\/sites\/\w+\/bin\/(rrdcached) |
RRD helpers | python3 \/omd\/sites\/\w+\/bin\/cmk .*?(--create-rrd) |
Real-time helper | python3 \/omd\/sites\/\w+\/bin\/cmk .*?(--real-time-checks) |
Redis DB | \/omd\/sites\/\w+\/bin\/(redis-server) |
Site Apache | \/usr\/sbin\/apache2 -f \/omd\/sites\/\w+\/etc\/(apache)\/apache.conf |
Each of these expressions contain one group, so you can use "%u/%1" as Process name in your Process discovery rule.
Related articles