Solved

Troubleshooting Linux Website Downtime - Cause?

Posted on 2014-07-18
7
303 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
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 82

Expert Comment

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

Accepted Solution

by:
ThomasMcA2 earned 167 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
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 108

Assisted Solution

by:Ray Paseur
Ray Paseur earned 167 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 166 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

Complete Microsoft Windows PC® & Mac Backup

Backup and recovery solutions to protect all your PCs & Mac– on-premises or in remote locations. Acronis backs up entire PC or Mac with patented reliable disk imaging technology and you will be able to restore workstations to a new, dissimilar hardware in minutes.

Join & Write a Comment

As a database administrator, you may need to audit your table(s) to determine whether the data types are optimal for your real-world data needs.  This Article is intended to be a resource for such a task. Preface The other day, I was involved …
Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

708 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now