Sometime yesterday the URL fopen wrapper capability on one of my servers stopped working, or became severly impared.
One of my scripts has code similar to this:
$URL = 'http://someserver/path';
include($URL);
When running, it causes the page to appear blank. There doesn't appear to be a timeout until you get the default dns not found error in IE.
I switched the script to:
$URL = 'http://IPADDRESS/path'; and had the same result.
I made a copy of the remote file and put it on the local webserver and changed to this:
$URL = 'http://localhost/path'; and it worked, but took a very long time.
I ssh into the server that is having this problem and use lynx to open the remote url. It works perfectly. Nice and fast wither using IP or hostname.
I do a tail -f on the log file of the remote server to see what's happening and I get this (shortened for readability):
192.168.128.1 - - [05/Jun/2002:12:17:51 -0400] "GET /cgi-bin/myscript HTTP/1.0" 408 - "-" "-"
Now it takes quite a while before an entry like this will show up. As a matter of fact, most attempts don't put an entry in the log file.
I tried using the following code as well, just to see what would happen, but nothing changed:
$success = fopen($URL, 'r');
if($success){ echo "IT WORKED"; }else{ echo "IT DIDN'T WORK"; }
Nothing is output to the browser. It just appears to be blank until the browser gives up.
Can anyone suggest some trouble shooting measures? I've exhaused my supply.