If you want to push the agent output from a Windows machine to Checkmk, just follow this small how-to!
LAST TESTED ON CHECKMK 2.2.0P1
Table of Contents
Step-by-step guide
- Enable SSH on the monitoring system (https://docs.checkmk.com/latest/en/agent_linux.html#_creating_ssh_key_pairs)
. - Create the script
.On a Windows machine (Check that manual for SSH → Windows monitoring over SSH)
ECHO OFF "C:\Program Files (x86)\checkmk\service\check_mk_agent.exe" test > HostFile scp HostFile USER@CMKSERVER:/var/cmk/HOST
Create a batch job to run the script automatically (https://www.windowscentral.com/how-create-automated-task-using-task-scheduler-windows-10#create_advanced_taskscheduler_windows10)
On a Linux machine
#!/bin/bash check_mk_agent | ssh USER@CMKSERVER "cat > /var/cmk/HOST"
Create a cronjob to run the script automatically
.
On the Checkmk Server, we need to create a rule by going to Setup → Agents → Other intergrations → Individual program call... → Add rule
Command line to execute: cat /var/cmk/$HOSTNAME$
More information can be found here: Windows monitoring over SSH
Related articles