2024 April Community Bulletin Announcements Checkmk Forum

Gombloh
-
2024 april community bulletin announcements checkmk forum

CheckMK is an extensive IT monitoring platform. There are agents to run on other machines, there is network scanning/monitoring, containers and whole bunch of platforms. So to see if this is something I can and want to use I will give it a go on my monitoring server. Installation – Docker Compose For my docker instances I use Docker Compose. This container will run on my Monitor Server which runs OMV.

OMV has it’s own way of dealing with Docker Compose files, you don’t make a docker-compose.yaml but use the webinterface to create the files. So based on the information from their website together with few other sources I came up with the following. version: ‘3.3’ services: check-mk-raw: container_name: checkmk ports: – ‘5000:5000’ – ‘5080:8000’ tmpfs: ‘/opt/omd/sites/cmk/tmp:uid=1000,gid=1000’ volumes: – ‘/Docker/checkmk/monitoring:/omd/sites’ – ‘/etc/localtime:/etc/localtime:ro’ restart: unless-stopped image: ‘checkmk/check-mk-raw:2.2.0-latest’ In the examples they use container name monitoring, but I find checkmk clearer.

There’s 2 ports for CheckMK, the first (5000) is the default port to access CheckMK, the 8000 is the port for the agent controller, this is available since 2.1.0. The tmpfs option make the container use a temporary file system directly in RAM, this is for better performance. There’s 2 volumes, one is for the CheckMK files, the localtime one is to make sure the container is in the same timezone as the host.

Then the restart I’ve set to unless-stopped, as I do on all containers, and the image has the current latest version. According to documentation it’s their best practice to set a version instead of just use latest. To fire up the container we now press the up button and let OMV work it’s magic. It takes a long time to finish, but eventually the END OF LINE message appears. And when going to localhost at port 5000. The challenge is the username/password.

You have to check the logs to find your “temporary” password. As you can see in the screenshot below, the webui is not useable, it’s the container code, just use the IP as we already did. Once you are logged in you will see a large empty screen, ofcourse the data still needs to be added. But what I’m going to do to close this part is change the password for the user for security reasons.

At the left bottom you find User, with below a number of options, one being Change password. Once that is done you have CheckMK running. First Host My first host will be the server I’m running CheckMK on, this is an OpenMediavault Server, which is Debian based. So I will try with the Debian agent. This can be found under Setup->Agents->Linux.

Once you’ve download the Agent you need to get it onto the server, you can do this by using an SSH allowed user and do the following command: scp .\check-mk-agent_2.2.0p24-1_all.deb SSHUser@192.168.x.x:/tmp Then once it is there we will ssh into the server and check if the file is there using ls. Now we know it’s there we need to install the package, we do this by using the following command: sudo apt install ./check-mk-agent_2.2.0p24-1_all.deb Now the installation will start running.

Then it’s time to go to CheckMK and add our host. Go to Setup->Hosts and then Add host to monitoring. Here we fill the Hostname and I will also add the IP since I’m not sure if my DNS will resolve it properly. Then we press Save & run service discovery and we should get a list of items we can monitor. Using the Plus we can add them to the monitoring, with the x we discard them from monitoring.

I’m just going to click the Monitoring undecided services button to monitor them all and then we active all the changes. And after a while on the right side you will see something like below. If we click the host we get an overview of all our hosts (which is only one at the moment). And if we then click on the hostname we get an overview of the services. And from there we can click deeper into the rabbit hole ending up with service specific information.

Now there isn’t much to show yet, but over time the graphs will be filled with more information. SNMP Host Another way to add hosts is through SNMP, this is mostly used for networking equipment, now at this point I have a USG and an Access Point to add. So let’s go to add host for the USG. Back to the menu -> Setup -> Host and there we fill in the name for the device, and add the IP address.

We set Checkmk agent/API to none of both and SNMP to version 2 or 3. Then the option for SNMP credentials appears, if you haven’t set them you can leave that alone. Then press save and run connection test to see if it works. And then we get a list of items again, so we add them all again and there we go, another host added. Docker monitoring Now I’ve added my OMV machine to the monitor, but it runs docker as well, how do we get that in there?

It’s not that hard once you figure it out. First we copy the py file from the agent list under Linux you can find mk_docker.py. Then using scp I’m copying the file over to the tmp directory, then ssh into the machine and from the tmp directory run sudo install -m 0755 mk_docker.py /usr/lib/check_mk_agent/plugins Now in CheckMK I go to the host again and click Save & Run Service Discovery again. Now it finds a few new services, simply add them again and we’re done.

Now if we want to monitor the Containers in detail you need to create a new host. I’ve used the config file provided by Checkmk, so I can create them based on name. Let’s monitor the CheckMK container itself. The hostname is checkmk, I’m setting IP Address to No IP and Checkmk Agent /API to both no as well. Then press Save & run service discovery. Fun fact, CheckMK has an agent build in, so there’s more info for this container then the others.

Notifications to Zammad I have a docker container that runs Zammad as well, I would like to use this to register all my warnings. To do this I need to create a custom script for notifications. Zammad itself provides 2 examples for this, one a Host Script and the other a Service Script. And also in Zammad itself you can find the examples under Admin Panel > System > Integrations > Checkmk. This is also the place where you need to activate the integration in Zammad.

Once you done that you need to create 2 bash scripts in CheckMK, in my case since I have the Docker folder where I put everything under it’s in Docker\checkmk\monitoring\cmk\local\share\check_mk\notifications Here I created 2 files, one for Hosts and one for Services based on the info from Zammad. Make sure both files have chmod +x so they can be executed, otherwise they wont show up in CheckMK. To check if it worked go to Setup -> Events -> Notifications and click Add Rule.

This allows you to create a new notification rule. So let’s create a notification for a service fail. I kept it pretty simple, something to finetune later if it doesn’t do what I hope it does. So let’s wait for something to fall down… And after a little while and some tweaking, it happened, my Access Point has bad connection. So there we have it, CheckMK is running and errors are being send to Zammad as support tickets.

People Also Asked

2024AprilCommunityBulletin-Announcements-Checkmk...?

CheckMK is an extensive IT monitoring platform. There are agents to run on other machines, there is network scanning/monitoring, containers and whole bunch of platforms. So to see if this is something I can and want to use I will give it a go on my monitoring server. Installation – Docker Compose For my docker instances I use Docker Compose. This container will run on my Monitor Server which runs ...

2024MayCommunityBulletin-Announcements-Checkmk...?

There’s 2 ports for CheckMK, the first (5000) is the default port to access CheckMK, the 8000 is the port for the agent controller, this is available since 2.1.0. The tmpfs option make the container use a temporary file system directly in RAM, this is for better performance. There’s 2 volumes, one is for the CheckMK files, the localtime one is to make sure the container is in the same timezone as ...

CheckmkPricing 2026?

You have to check the logs to find your “temporary” password. As you can see in the screenshot below, the webui is not useable, it’s the container code, just use the IP as we already did. Once you are logged in you will see a large empty screen, ofcourse the data still needs to be added. But what I’m going to do to close this part is change the password for the user for security reasons.

CheckmkAnnouncesStrategic Investment from PSG?

Then it’s time to go to CheckMK and add our host. Go to Setup->Hosts and then Add host to monitoring. Here we fill the Hostname and I will also add the IP since I’m not sure if my DNS will resolve it properly. Then we press Save & run service discovery and we should get a list of items we can monitor. Using the Plus we can add them to the monitoring, with the x we discard them from monitoring.

CheckMK– Thierry's Home Lab?

There’s 2 ports for CheckMK, the first (5000) is the default port to access CheckMK, the 8000 is the port for the agent controller, this is available since 2.1.0. The tmpfs option make the container use a temporary file system directly in RAM, this is for better performance. There’s 2 volumes, one is for the CheckMK files, the localtime one is to make sure the container is in the same timezone as ...