?
Solved

Troubleshooting Linux Website Downtime - Cause?

Posted on 2014-07-18
7
Medium Priority
?
314 Views
Last Modified: 2014-08-05
I have a group of php websites / different domains that run off a single linux server (Centos).  All of the sites are forums for the most part that run off a single mysql database.  For some reason, one of the sites goes down multiple times a day.  The others don't.  The site that goes down receives the second most traffic but not the most.  So the server should be able to handle the load.  All of the sites are very similar in structure but not content.  I bought the sites so don't know the intricacies of all of the code.  I'm not a linux guy by any means (Windows guy) but have a tiny bit of linux experience that I've picked up during my troubleshooting.  I've tried looking at logs but haven't figured out what's causing it.  Any tips or suggestions on how to troubleshoot this?  Step by step directions / commands would be greatly appreciated.
0
Comment
Question by:adrian78
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 
LVL 58

Expert Comment

by:Gary
ID: 40205756
sites goes down
What exactly happens?
What error messages?
Have you enabled error reporting on the site?
0
 
LVL 83

Expert Comment

by:Dave Baldwin
ID: 40205803
Not enough info.  Details are required.
0
 
LVL 14

Accepted Solution

by:
ThomasMcA2 earned 668 total points
ID: 40205873
Right after the server goes down, look at recently modified logs in the /var/log directory on the server. Sometimes mysql has its own log folder (/var/log/mysql), so look for that, too.
0
Not sure which OpenStack Certification to get?

So you’ve realized you might want to get certified in OpenStack, but you’re not sure what the benefits might be or even which one you should take. You know there are several certification courses you can choose from, but how do you know which one is right for you?

 
LVL 111

Assisted Solution

by:Ray Paseur
Ray Paseur earned 668 total points
ID: 40206565
In PHP, make sure you have error_reporting(E_ALL) set, as well as log_errors.  This will give you some diagnostic information if, in fact, PHP errors are causing a problem.

If you want us to be able to help, we will need to know exactly what you mean by "site goes down multiple times a day."  We would need to see the actual URL of the site, the contents of the log files and any error messages, the most recent requests to the site immediately prior to the failure.
0
 

Author Comment

by:adrian78
ID: 40206925
Hi Guys,

Thanks for the replies.

Thomas, I'll go ahead and check those log files and report back.

Ray, I have error_reporting already on but it's not a PHP error (as far as I know) that's causing it.

There are no errors reported - the site just doesn't load (progress icon keeps spinning - almost like the resources are getting max'd).  The problem is it happens a handful of times during the day and I'm not usually on the computer when it happens.  I have a ping service (monastic) that checks every 30 min and emails me… so I don't know exactly when it happens but I know it's within 30 minutes.

I'll look into those logs a bit more and will update this thread.

Thanks again!
0
 
LVL 58

Assisted Solution

by:Gary
Gary earned 664 total points
ID: 40207396
Is it one particular page do you know? Or any page...
Is it MySQL getting maxed out and just showing up under this one site as it has the second most traffic.
What kinda of memory does the server have, and what is allocated to MySQL and to Apache.
Maybe you are running out of processes - how many visitors/page loads are you getting for all sites.
0
 

Author Closing Comment

by:adrian78
ID: 40242031
Thanks guys.  Your tips were helpful but I decided to switch to a cloud solution so I don't need to worry about this :)
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many old projects have bad code, but the budget doesn't exist to rewrite the codebase. You can update this code to be safer by introducing contemporary input validation, sanitation, and safer database queries.
In this series, we will discuss common questions received as a database Solutions Engineer at Percona. In this role, we speak with a wide array of MySQL and MongoDB users responsible for both extremely large and complex environments to smaller singl…
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question