Cmk-agent-ctl comapre to cmk-update-agent

CMK version: 2.2.0p34.cee
OS version:Rocky 9.5

So I don’t understand the diffrence between.
cmk-agent-ctl
and the cmk-update-agent

I would like to use the agent bakery before this was done using the cmk-update-agent but now I’m not sure if I should use the cmk-agent-ctl?

For automatic agent updates, as described here Automatic agent updates, you should use cmk-update-agent.
For registering (adding) a host to your monitoring, as described here Monitoring Linux, you should use cmk-agent-ctl

1 Like

Perfect, thanks for the clarification.
I have some follow-up questions:

  1. Why do I need to register a host in my monitoring system if I create the host using an IP scan instead? Or do I still need to register it in that case?

  2. When running the cmk-update-agent register command, I get the following error:

Max retries exceeded with URL: /site/check_mk/login.py (Caused by SSLError(SSLCertVerificationError("hostname '192.168.10.31' doesn't match 'cmk-site'")))

I have added the certificate to the agent rule in the bakery, baked the agent, and installed it. Shouldn’t this be sufficient?

This registration enables TLS encryption for the agent data. It is optional but to disable Checkmk’s need for it you have to bake an agent package without the agent controller.

You have configured the agent updater with only the IP address which is not part of the webserver’s certificate. Hence the validity cannot be verified.

Thanks Sander for answering,

In my certifcate I have the CN name as the cmk-site but i also alt_names (see below)
shouldnt it work or missing something?

Example:
[req]
default_bits       = 2048
distinguished_name = req_distinguished_name
req_extensions     = req_ext
x509_extensions    = v3_ca
prompt             = no
default_days       = 3600

[req_distinguished_name]
C  = xx
ST = xx
L  = xxx
O  = xx
OU = IT
CN =  cmk-site

[req_ext]
subjectAltName = @alt_names

[v3_ca]
subjectAltName = @alt_names

[alt_names]
DNS.1 = cmk-site
DNS.2 = www.cmk-site
IP.1  = 192.168.10.31

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed. Contact an admin if you think this should be re-opened.