A few days ago I was trying to find out why office test server kept crashing every few hours, during the development of our website...
After a few checks using top and free commands, it was clear that apache was step by step eating all the server memory until the swap was so high that it brought the server unresponsive.
The usefull command that helped me a lot was:
watch free -m
leaving an auto-refreshing window showing the memory being used.
the top command was also very useful to track the processes eating the memory, using the key ">" to switch from processor usage to RAM usage listing.
After being sure that the server crash was due to apache, I finally came by a blog dealing with the tuning of MPM module in apache configuration file. Tuning this enables your website to be optimised to handle simultaneous connections but can also leaves many processes consuming a lot of RAM...
here are two intersting pages, one for tuning apache to drupal
http://drupal.org/node/215516
After a few checks using top and free commands, it was clear that apache was step by step eating all the server memory until the swap was so high that it brought the server unresponsive.
The usefull command that helped me a lot was:
watch free -m
leaving an auto-refreshing window showing the memory being used.
the top command was also very useful to track the processes eating the memory, using the key ">" to switch from processor usage to RAM usage listing.
After being sure that the server crash was due to apache, I finally came by a blog dealing with the tuning of MPM module in apache configuration file. Tuning this enables your website to be optimised to handle simultaneous connections but can also leaves many processes consuming a lot of RAM...
here are two intersting pages, one for tuning apache to drupal
http://drupal.org/node/215516
Commentaires
Enregistrer un commentaire
Tell me what you think