Page 1 of 1
Web Page Content Check for HTTPS site not working
Posted: Wed Aug 22, 2012 6:01 pm
by ecarrasq
Linux Distribution and version? CentOS, 2.6.18-308.8.2.el5PAE
32 or 64bit? 32bit
VMware Image or Manual Install of XI? VMware Image
Are there specials configurations on your system, ie; is Gnome installed? No
Are you using a proxy? No
Are you using SSL? No
Nagios Version? NagiosXi 2001R3.1
Issue:
I'm using the NagiosXi Website Monitoring Wizard, for a web page content check; However, I keep getting
"HTTP WARNING: HTTP/1.1 401 Unauthorized"
Though I launch the website on my browser and I can login manually just fine. The one thing I'm noting that may be of relevance is the login prompt is a "Pop-up" window after entering the https url.
Selection_015.png
Selection_015.jpeg
Any suggestions will be greatly appreciated, as we are using this to validate Sharepoint Site is up, and database availability via this check.
Thank you,
Eddie
Re: Web Page Content Check for HTTPS site not working
Posted: Thu Aug 23, 2012 8:38 am
by scottwilkerson
You should enter login credentials in the username and password field next to "Credentials:" when running the wizard.
Re: Web Page Content Check for HTTPS site not working
Posted: Thu Aug 23, 2012 2:18 pm
by ecarrasq
I did.
I used the "NagiosXi Website Monitoring Wizard" and filled it out accordingly with username/password, that is why I got the
"HTTP WARNING: HTTP/1.1 401 Unauthorized"
which is why I created this ticket, but I cannot post the username/password here on this forum or on the attached screenshot.
Re: Web Page Content Check for HTTPS site not working
Posted: Thu Aug 23, 2012 2:42 pm
by lmiltchev
When you ran the wizard, did you select the "Use SSL:" check-mark box? Can you show the actual command ran in the terminal, along with its output? You can remove the sensitive data.
Re: Web Page Content Check for HTTPS site not working
Posted: Thu Aug 23, 2012 2:57 pm
by ecarrasq
This is the command line from NagiosXi. I substituted the data.
check_xi_service_http!-s "Word we are looking for" -H web.page.org -f ok -I <ip address> -u "/page1/page2/" -S -p 443 -a "username:password"
websitewizard001.jpeg
Don't know if you got this part, but just incase here it is "Though I launch the website on my browser and I can login manually just fine. The one thing I'm noting that may be of relevance is the login prompt is a "Pop-up" window after entering the https url."
Thank you for your time.
Re: Web Page Content Check for HTTPS site not working
Posted: Thu Aug 23, 2012 4:06 pm
by lmiltchev
The "Pop-up" shouldn't be an issue. I am not sure why you are getting this. We were not able to recreated it. We ran a test check against a https site in terminal:
Code: Select all
/usr/local/nagios/libexec/check_http -s "Word" -H <URL> -f ok -I <IP> -u "/page1/page2" -S -p 443 -a "username:password"
and we got:
Code: Select all
HTTP OK: HTTP/1.1 200 OK - 4937 bytes in 0.037 second response time |time=0.037347s;;;0.000000 size=4937B;;;0
When we plugged in wrong credentials, we got:
Code: Select all
HTTP CRITICAL: HTTP/1.1 401 Authorization Required...
I know you said you can log in manually just fine, however the error indicates otherwise. Unless we have the URL and the credentials to log in, I am afraid we are not going to be able to troubleshoot this one. You can send us an e-mail at
[email protected] and open a support ticket in our system, so we will be communicating via email.
Re: Web Page Content Check for HTTPS site not working
Posted: Thu Aug 23, 2012 4:52 pm
by ecarrasq
Thank you for validating the scripts, as it was helpful to pinpoint the problem. I verified with the Server Admins that provided me the credentials, and was just told the site uses NTLM for auth, which maybe why its not working. In light of that I found this:
check_sharepoint.pl
http://exchange.nagios.org/directory/Pl ... pl/details
It works with both integrated NTML and forms based authentication, and I can do the "Search for custom string on page ". Seems a bit more complex, but worth a shot. I'll keep you posted.
Thanks everyone very much for you time,
Eddie
Re: Web Page Content Check for HTTPS site not working
Posted: Fri Aug 24, 2012 9:31 am
by scottwilkerson
Excellent. Glad you found a plugin to meet your needs.