check_http --onredirect=follow not working with use of '-u'

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
User avatar
Mitchell
Posts: 130
Joined: Thu Jan 05, 2012 2:33 am

check_http --onredirect=follow not working with use of '-u'

Post by Mitchell »

Hi,

I am not sure if it is a bug or a feature logic. I need to monitor a URL which redirects from HTTP to HTTPS and check_http only works when I use only '-H' option. it does not work with both '-H' and '-u' used together.

Code: Select all

./check_http -H xxxx --onredirect=follow
works but does not meet the needs



Code: Select all

./check_http -H xxxx -u xxxx
returns HTTP OK - with HTTP 302


Code: Select all

./check_http -H xxxx -u xxxx --onredirect=follow
returns error.

Could you please check and let me know if it is reproducable in your enviornment and how to fix it?

Thanks
Ashish
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: check_http --onredirect=follow not working with use of '

Post by tmcdonald »

What error specifically does it return? This might be an issue with checking HTTP then switching to HTTPS. Have you tried throwing in the --ssl option?
Former Nagios employee
Locked