Check_http - getting 404 error without virtual host

Hi!

We have a big issue with check_http. We have a lot of checks for our application (tomcat behing
nginx reverse proxy / AKS with nginx ingress); I guess since 1.6.0p7 there was a change in
check_http (werk 10451).

I have configured check_http with check rules - we do not use “virtual host” there. But: since this
update we are getting 404 errors. If I do the same check on the CLI - the check and host is “OK 200”

So if I configure the virtual host in the check rule, all works fine again :frowning: - but I cannot use
variables in “virtual host” right?

Any ideas? Environment: RAW + EE 1.6.0p11

Regards
Günther

Hi @grasch,

It could be related due to proxy settings, if you have anything configured on OS side you should specified in cmk as well

Hi,
no proxy settings - nginx as an reverse proxy is installed on EACH application server at the
app side as well as an ingress controller on AKS.

I guess it’s check related. Why the CLI check result differs from the GUI… do not understand…

Regards
Günther

have you ran the exact command that’s shown on the web interface ? if so it’s strange, from cli I only see it working if you had a specified proxy on os, besides that yeah must be check related. Can you share your rule parameters ?

Of course…
only with activated “Virtual host” it’s working. normally I leave it blank here (virtual host) - but if
I do so, I get an 404.

On the CLI: if I use -H it works (its virtual host)
if I use -I it doesn’t work --> 404

OK, got it fixed.
I defined in the check rule unter Virtual Host activated --> “$HOSTNAME$”
Not it works - but documentation mentioned that we should not use virtual host…
any suggestions?

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.