Current time: 11-30-2024, 11:11 AM Hello There, Guest! (LoginRegister)


Post Reply 
Running ISPCP on a low resources system
Author Message
BeNe Offline
Moderator
*****
Moderators

Posts: 5,899
Joined: Jan 2007
Reputation: 68
Post: #2
RE: Running ISPCP on a low resources system
Daff Wrote:Becaus of this thread telling about the huge memory usage of an ISPCP installation (which is about 640 Megabytes) on a virtual private server (VPS) I was searching for some optimization possibilities. Virtuozzo or OpenVZ (which is basically the same but less expensive Wink based virtual servers don't use a real swap file they only provide, besides the warranted RAM, a burstable RAM (which is swapped on the hardware node so try not to exceed your warranted RAM). If an application exceeds the burstable RAM value it simply won't start.

1. Configure apache worker MPM for low memory usage

On most Systems Apache consumes most memory (in the basic configuration on my System about 480 MB RAM).
So we have to change the MPM workers to a lower value:

# worker MPM
# StartServers: initial number of server processes to start
# MaxClients: maximum number of simultaneous client connections
# MinSpareThreads: minimum number of worker threads which are kept spare
# MaxSpareThreads: maximum number of worker threads which are kept spare
# ThreadsPerChild: constant number of worker threads in each server process
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule mpm_worker_module>
StartServers 1
MaxClients 100
MinSpareThreads 1
MaxSpareThreads 50
ThreadsPerChild 10
MaxRequestsPerChild 5000
</IfModule>

That suggestion was partly taken from http://wiki.vpslink.com/index.php?title=...igurations I don't know if its a usefull configuration, hope somebody is willing to test iit, too.
Another value I found important is the default thread stack size (which is 8 Megabytes). I really don't know how much of it is really used by an apache Thread. Here somebody tells about 1 Megabyte but I think its a bit too less. Actually I use this one (just add it at the end of you /etc/apache2/apache2.conf):

ThreadStackSize 4000000

After every change you have to call
$ /etc/init.d/apache2 force-reload

This modification works perfect. Apache2 needs about ~80-100MB.
05-27-2007 08:08 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Running ISPCP on a low resources system - BeNe - 05-27-2007 08:08 PM

Forum Jump:


User(s) browsing this thread: 1 Guest(s)