Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've upgraded from Ubuntu 9.10 to 10.04 beta 1 and PHP got upgraded from 5.2 to 5.3 Now all my WordPress & Magento sites arent working. I tried retrieving the URL headers from the command line, but HTTP request fails.

Utilizing get_headers in a small script, PHP Warning: get_headers( failed to open stream: HTTP request failed! in get_headers.php on line 12

But HTTP request fails only for WordPress and Magento based sites - not custom written ones. Does this probably have to do with some htaccess directive ?

share|improve this question

Check the setting for:

allow_url_fopen = On

in your php.ini file. It is possible that the code is not using sockets to open the remote sites and is using file_get_contents.

share|improve this answer
allow_url_fopen is already On in /etc/php5/apache2/php.ini – anjanesh Apr 3 '10 at 10:59

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.