What check would you like me to run?abrist wrote:Run the check from the cli and post the output. The html output in pm may be truncated.
The HTML that I sent is exactly as it shows in the web browser.
What check would you like me to run?abrist wrote:Run the check from the cli and post the output. The html output in pm may be truncated.
I would like to see what the html check returns before it is set to the browser. I would like to see the raw html returned from just the check itself so I can attempt to reproduce the problem. The closing title tags are in a very weird place in the PM.EchoKev wrote: What check would you like me to run?
abrist wrote:I would like to see what the html check returns before it is set to the browser. I would like to see the raw html returned from just the check itself so I can attempt to reproduce the problem. The closing title tags are in a very weird place in the PM.EchoKev wrote: What check would you like me to run?
Code: Select all
root@monitor:/usr/local/nagios/libexec# ./check_https <URL REMOVED> login.htm
<title>Gateway
root@monitor:/usr/local/nagios/libexec#Yes, check_https is custom script that looks for specific words in a wget of a page. It then cats the output of the line that it finds the word on to the response of the check. Otherwise it returns a string "Connection refused by host"abrist wrote:Is "check_hhtps" a custom plugin/script? I can only reproduce your issue by setting "escape_html_tags=0", and when attempted with a custom test script or check_http, it works fine when "escape_html_tags=1".
This check does not seem to work, as it is unable to read the page (HTTPS)lmiltchev wrote:Is there any possibility for you to try using "check_http" with the "-S" flag instead of "check_https" (for testing purposes) and see if you are going to experience the same issue?
It's a very simple wget bash script, due to it being used for multiple different pages there are multiple greps for items that should appear on the page to verify that it is loading the correct page (I believe), otherwise return critical unreachable:abrist wrote:Could you by chance post the script in code wraps?
Code: Select all
#!/bin/bash
wget='/usr/bin/wget --no-check-certificate --output-document=/tmp/tmp_html -S'
add_uri='https://'
end_uri='/'
if ($wget $add_uri$1$end_uri$2 2> /tmp/tmp_rep) then
cat /tmp/tmp_html | grep '<title>'
cat /tmp/tmp_html | grep 'OK'
cat /tmp/tmp_rep | grep " 1 "
exit 0
else
cat /tmp/tmp_rep | grep " 1 "|| echo 'Connection refused by host'
exit 2
fi;