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 have a LAMP stack,

  • Ubuntu 12.04.3 LTS
  • PHP 5.3.10-1ubuntu3.8 with Suhosin-Patch (cli) (built: Sep 4 2013 20:05:42)
  • Apache/2.2.22 (Ubuntu)
  • MYSQL 5.5.32-0ubuntu0.12.04.1 (Ubuntu)
  • Codeigniter 2.1.0

All of these are currently running as they should be.

The sites are:

Some load with a blank white page others with a 500 Server Error.

How do I go about debugging as to why it's not working. The PHP sites / code should be running fine, the code has been in production for months.

This all started because I went into the server today to make clear some disk space (I deleted some mysqldumps). I also ran apt-get update and apt-get upgrade and it might have updated PHP. Now that mysql is working I assumed that was the main bug, but now these sites are unresponsive.

I've already checked the individual site error logs and there's nothing in them. I've tried to enable PHP error reporting to see if that's the issue and nothing is coming up. I've replaced a sites /public directory with a "hello world" index.php file and it came up on the site just fine, which means the server is working as it should, right?

Any assistance would be really great, I'm totally dead in the water...

share|improve this question
What about logs? Syslog, apache logs etc. – strangeman Sep 24 '13 at 0:41
That is not blank. Your PHP source is clearly visible there. – Michael Hampton Sep 24 '13 at 0:43
@MichaelHampton I'm seeing nothing at all on those sites, rendered or in view-source. You're seeing PHP source? Can you take a screenshot? – ThomasReggi Sep 24 '13 at 0:44
@strangeman I've checked the sites apache logs and there's nothing in them. Where can I find Syslog? – ThomasReggi Sep 24 '13 at 0:45
@ThomasReggi /var/log/syslog Hmm. '500 Server Error' must record error in the log too. – strangeman Sep 24 '13 at 0:47

I don't have enough information to debug the first two, but the last link is missing a proper php start tag. You are using "<php" instead of "<?php"

See this link for more information:

As for debugging the first two, I would start by inspecting the error log file for the web server. Usually, I find those are located in a place like "/var/log".

Here's the responses from your server. I used a traffic inspector application to get this data.

HTTP/1.1 200 OK
Date: Tue, 24 Sep 2013 00:47:28 GMT
Server: Apache/2.2.22 (Ubuntu)
X-Powered-By: PHP/5.3.10-1ubuntu3.8
Content-Encoding: gzip
Vary: Accept-Encoding
Content-Length: 26
Content-Type: text/html

HTTP/1.0 500 Internal Server Error
Date: Tue, 24 Sep 2013 00:47:45 GMT
Server: Apache/2.2.22 (Ubuntu)
X-Powered-By: PHP/5.3.10-1ubuntu3.8
Content-Encoding: gzip
Vary: Accept-Encoding
Content-Length: 26
Connection: close
Content-Type: text/html

HTTP/1.1 200 OK
Date: Tue, 24 Sep 2013 00:48:05 GMT
Server: Apache/2.2.22 (Ubuntu)
X-Powered-By: PHP/5.3.10-1ubuntu3.8
Vary: Accept-Encoding
Content-Encoding: gzip
Content-Length: 2252
Content-Type: text/html


... your raw source code omitted for security reasons ...

share|improve this answer
Using <php instead of <?php is almost certainly the cause of the problems. – Michael Hampton Sep 24 '13 at 0:52
I was debugging and did <php in vim by accident after there was already an issue. I don't know how you are seeing raw code because I can't in chrome. I just fixed it and everything is still down. Any other ideas? – ThomasReggi Sep 24 '13 at 0:57
When the tag is malformed, the entire page is treated as text and dumped to client. Your browser may have hidden this from you, but it was very clear when I inspected the traffic. The response on "" is now similar to the "bf" and "ac" servers. Now, you should examine your error logs on the server. For Ubuntu and Apache2, check the files in this directory "/var/log/apache2". Look for a file named "error.log". – Zahnon Sep 24 '13 at 1:00
Any other ideas not that that is fixed? – ThomasReggi Sep 24 '13 at 1:02
When you're done checking out your server's error.log file, you can head over to this discussion to get ideas on how to enable PHP's fancy debugging features. Just stick your directives right after your php start tag.… – Zahnon Sep 24 '13 at 1:18

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.