Check_HTTP issues checking https site

Hi

I want to implement a simple URL check, but I always seem to get the following error:

Connection refused HTTP CRITICAL - Unable to open TCP socket
or
CRITICAL - Socket timeout after 10 seconds

Here are my settings:
image

I would like to execute the command on the CLI but I can’t find how, to determine where the error lies.

1: What could be wrong with a simple HTTPS check?
2: How can I run check_HTTP on the CLI ?

Kind regards

Hello @Steven1,

i would troubleshoot this with a simple curl-command to check if your monitoring-server can even access the website. So just try curl <url> from the command line of the monitoring-server and see if you get a response. If you get a timeout there as well it will most likely be some kind of firewall-issue between your monitoring-server and the webserver.
You should also check if the webserver uses a non-standard port, e.g. not 80 or 443, then you need to specify the port explicitly.
You can find the binary for check_http in the site under ~/lib/nagios/plugins/check_http and you can run it from there. However, i would recommend troubleshooting with curl or wget and if that works going back to webinterface and configuring the check.
Hope that helps.

Cheers,
Lorenz

Hey @lkoenig

Finally found the correct path for the executable version of the plugin, thanks for that!
And I’ve found that the webserver listens on a non default port, so after I adjusted that, thanks to your curl suggestion, I now have an active check in CheckMK.

Thanks for showing the correct path to start my investigation!

1 Like

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.