LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-17-2005, 11:03 AM   #1
newlinuxnewbie
Member
 
Registered: Sep 2005
Posts: 114

Rep: Reputation: 15
apache suddenly stopped working


Sites can't be accessed but can still be pinged. The culprit is apache but it is still running, not stopped. Restarting apache gets the sites back up. Nothing unusual in the error log. This happens constantly.

So apache suddenly stops working (though it is still running). Please help me.
 
Old 11-17-2005, 12:20 PM   #2
fouldsy
Senior Member
 
Registered: Jan 2002
Location: St Louis, MO
Distribution: Ubuntu
Posts: 1,284

Rep: Reputation: 47
Other than in the Apache logs, do the standard system logs show any activity occuring which is causing Apache to lock? And when you constantly, give us a time frame - how often is it occuring and is it only when certain sites are accessed, etc.?
 
Old 11-17-2005, 05:07 PM   #3
newlinuxnewbie
Member
 
Registered: Sep 2005
Posts: 114

Original Poster
Rep: Reputation: 15
Nothing unusual in all the logs. Happens daily, every 16-24 hours. There's only 1 site on the server and it's barely getting any traffic.
 
Old 11-18-2005, 03:20 AM   #4
fouldsy
Senior Member
 
Registered: Jan 2002
Location: St Louis, MO
Distribution: Ubuntu
Posts: 1,284

Rep: Reputation: 47
Do you have any cron jobs scheduled to run, and is there any pattern to halt times? Does the rest of the machine stay up and running, meaning it's *just* Apache that stops? Would expect something to written to logs that causing it to fail. Have you made any recent changes to your Apache config such as installing new modules?
 
Old 11-18-2005, 07:44 AM   #5
newlinuxnewbie
Member
 
Registered: Sep 2005
Posts: 114

Original Poster
Rep: Reputation: 15
No cron jobs setup. Now my other server is having the same problem, site pingable but apache not working. I can't even login via SSH on this server.
 
Old 11-18-2005, 07:53 AM   #6
fouldsy
Senior Member
 
Registered: Jan 2002
Location: St Louis, MO
Distribution: Ubuntu
Posts: 1,284

Rep: Reputation: 47
Right, rather than looking at Apache, could be core networking if SSH doesn't respond. When you say sites are pingable, do you mean you can ping outside from your server or what? What network card are you using and what module is loaded? Can you physically ping your server when Apache + SSH stop working. What about FTP access?
 
Old 11-18-2005, 08:07 AM   #7
newlinuxnewbie
Member
 
Registered: Sep 2005
Posts: 114

Original Poster
Rep: Reputation: 15
Server is pingable when apache and ssh stop working. Site is pingable from outside. FTP is not running. The problem is fixed after a server reboot or restarting apache. Don't know why its happening to both servers.
 
Old 11-18-2005, 08:27 AM   #8
fouldsy
Senior Member
 
Registered: Jan 2002
Location: St Louis, MO
Distribution: Ubuntu
Posts: 1,284

Rep: Reputation: 47
I like a challenge, but's a good one! Loose network services, but network connectivity not affected... You say it's now affecting another server - have any updates been applied across them both? Also, maybe read through http://httpd.apache.org/dev/debugging.html for info on obtaining debug information from Apache to analyse it's point of failure.
 
Old 11-18-2005, 08:36 AM   #9
newlinuxnewbie
Member
 
Registered: Sep 2005
Posts: 114

Original Poster
Rep: Reputation: 15
I think the 2 server's problems may be unrelated. The 2nd server is due to swap being used fully and that cut off apache and ssh. The 1st server don't have any swap issues but have the same problem. Going to take a look at that debug info. Thanks.
 
Old 11-18-2005, 08:44 AM   #10
fouldsy
Senior Member
 
Registered: Jan 2002
Location: St Louis, MO
Distribution: Ubuntu
Posts: 1,284

Rep: Reputation: 47
I'd be impressed if both physical + swap memory was all used up. What are the specs of the server? Also, you could look adjusting the priority using nice or renice (check the man pages) to ensure ssh is give higher priority when the system is low on memory. This would keep a connection session open if you needed to get in. As for the debug info, let us know how it goes.
 
Old 11-18-2005, 08:49 AM   #11
newlinuxnewbie
Member
 
Registered: Sep 2005
Posts: 114

Original Poster
Rep: Reputation: 15
Here's a screen shot of the 2nd server's memory/swap being sucked dry.
http://img364.imageshack.us/img364/4...shedbad0hb.gif

The 1st server don't have any load/ram issues but still have the same problem.
 
Old 11-18-2005, 09:06 AM   #12
fouldsy
Senior Member
 
Registered: Jan 2002
Location: St Louis, MO
Distribution: Ubuntu
Posts: 1,284

Rep: Reputation: 47
Just as an extra note until you try some of those debugging ideas, you have a *lot* of processes running according to top there. How many instances of apache do you have spawned, and what else is running on the machine? Have you tried stopping all other services except apache and those related to it such as MySQL and see if you still encounter problems? Of course, if server 1 does not have memory problems, will need to see what the debug stuff returns.
 
Old 11-18-2005, 09:16 AM   #13
newlinuxnewbie
Member
 
Registered: Sep 2005
Posts: 114

Original Poster
Rep: Reputation: 15
The servers are tweaked to handle a lot of load, 100+ apache processes should not take the server down. http://img367.imageshack.us/img367/728/ss0012ns.gif

Server 2 I know what it is, just need to replace the script. Server 1, still have no idea what could be causing it to go down.
 
Old 11-18-2005, 10:11 AM   #14
msound
Member
 
Registered: Jun 2003
Location: SoCal
Distribution: CentOS
Posts: 465

Rep: Reputation: 30
The next time apache goes down open up the command line and run:
Code:
netstat -an | grep 80
Even the the process is still running, im curios to see if the service is still Listening on port 80.

Also when you say the site goes down, what page gets displayed when you type in your website's URL?
 
Old 11-18-2005, 10:18 AM   #15
newlinuxnewbie
Member
 
Registered: Sep 2005
Posts: 114

Original Poster
Rep: Reputation: 15
I might not have a chance to try that, it'll kick me out of SSH and can't connect to it anymore. If it doesn't, I'll try it out.

When the site goes down, I go to the URL, it's a white page, looks like it's still loading, even after 10 minutes same thing.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Sound has stopped working suddenly mrmuckle Linux - General 2 10-15-2005 01:57 PM
Internet suddenly stopped working. figster Linux - Newbie 2 08-29-2005 05:18 PM
yum suddenly stopped working DJOtaku Fedora 3 05-01-2005 11:38 AM
Azureus suddenly stopped working!! Braveheart1980 Linux - Software 1 02-19-2005 06:22 PM
airsnort suddenly stopped working fatrandy13 Linux - Security 1 09-23-2004 08:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:06 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration