Super User is a question and answer site for computer enthusiasts and power users. 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 Ubuntu 64 webserver with Apache, Mysql, php5, and ssh. 265MB ram, unlimited Swap. (about 1TB) My issue: Today the webserver was down, I tried to ssh to it and it was Extremely slow. I stoped apache, and tried to restart it a few times by first killing stray apache ps as needed until all related to apache was stoped. It failed to start and was very slow. I then shut the server unit down and started it up. When I checked the server box statistics it showed usage in the past hour as:

Swap: 50mb (read) 30MB (write) 11:00am Swap: 146GB (read) 6GB (write) 12:00am The CPU was also high, but not to a allarming extent. My questions are: How do I solve this apache2 issue? (this is the second time it happened, after the first 3months ago I did a New install) And how do I prevent it? What configs can I change to prevent apache from using more than a certain amount of ram?

Thank you

share|improve this question
    
Do you mean 256GB of RAM? Also, a swap file is on disk, not in memory. – user3463 Aug 25 '12 at 21:29
    
256 MB not GB, I do know that swap is not ram, I forgot to add that the ram was at 100% which caused the swap overflow – SteveLacy Aug 26 '12 at 2:26
up vote 0 down vote accepted

I think that here (Introducing LAMP Tuning Techniques - O'Reilly Media - http://goo.gl/aq9KG) you will find some useful tips.

Most of this configurations take place in your apache httpd.conf file for what you might also find useful this: Understanding an httpd.conf File (TCP/IP Network Administration, 3rd Edition) - http://goo.gl/efycF

share|improve this answer
    
I will modify my httpd.conf file to add swap limits where possible – SteveLacy Aug 27 '12 at 5:43

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .