Page 1 of 1

ERROR in opening page! Err:Maximum (20) redirects followed

Posted: Tue Oct 07, 2014 2:10 am
by ashok
Hi All,

I want to monitor two Urls.

when i tried to execute check_curl.php exactly 24 hrs back, i got the output as Page OK.

But after some time iam getting the below error everytime

ERROR in opening page! Err:Maximum (20) redirects followed


Command used is :

[root@nagxi libexec]# /usr/bin/env http_proxy=http://x.x.x.x:80/ no_proxy=localhost,127.0.0.0/8 /usr/local/nagios/libexec/check_curl.php -T 90 -U http://www.xxxxx.in -a xxxx:xxx -F
ERROR in opening page! Err:Maximum (20) redirects followed
[root@nagxi libexec]#


The webpage was opening fine in web browser..

Please help me..

Thanks

Re: ERROR in opening page! Err:Maximum (20) redirects follow

Posted: Tue Oct 07, 2014 9:29 am
by tmcdonald
When you open the page in a browser, does the page seem to flicker a bit before loading? That could indicate that the URL you are visiting is redirecting to another page before the page can be rendered. If that is the case and there is some Javascript code that stops the redirect, the curl command-line might not be able to account for it.

Also, the proxy might be doing some redirection of its own transparently. Do you use the proxy when connecting via your browser?

Re: ERROR in opening page! Err:Maximum (20) redirects follow

Posted: Tue Oct 07, 2014 11:49 pm
by ashok
Thanks for the reply.

Yes it flickers a bit..

yes i'm using proxy to open the page

can you please help me how to increase the redirects followed using check_curl.php

Re: ERROR in opening page! Err:Maximum (20) redirects follow

Posted: Thu Oct 09, 2014 1:39 pm
by tmcdonald
Would you mind PMing me the site address if possible? That way I could test other methods of connecting. The page may or may not be using Javascript to handle the redirect, but if it is curl will not be able to follow it.