How to change from prefork to work MPM

How to change from prefork to work MPM

am 18.08.2007 18:46:19 von sir_ddd

Hi all,

I have a question, maybe silly question, about to how can I change the MPM
on an Apache Installed, let me explain I have Apache 2.2.4 running on Fedora
Core 5 with PHP 5 and Mysql 5; I've installed the apache with default
options, "configure --enable-so", I saw that default MPM installed was
prefork, but now I want to changed it for worker MPM...

How can I do it?, I need recompile the apache "--with-mpm=worker"... I know
this list it's for apache, what is the appropiate MPM Apache that works
better with php?
regards

David

____________________________________________________________ _____
Acepta el reto MSN Premium: Correos más divertidos con fotos y textos
increíbles en MSN Premium. Descárgalo y pruébalo 2 meses gratis.
http://join.msn.com?XAPID=1697&DI=1055&HL=Footer_mailsenviad os_correosmasdivertidos


------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

Re: How to change from prefork to work MPM

am 18.08.2007 20:06:30 von noodlet

T24gMTgvMDgvMDcsIERhdmlkIETDrWF6IETDrWF6IDxzaXJfZGRkQGhvdG1h aWwuY29tPiB3cm90
ZToKPiBJIGhhdmUgYSBxdWVzdGlvbiwgbWF5YmUgc2lsbHkgcXVlc3Rpb24s IGFib3V0IHRvIGhv
dyBjYW4gSSBjaGFuZ2UgdGhlIE1QTQo+IG9uIGFuIEFwYWNoZSBJbnN0YWxs ZWQsIGxldCBtZSBl
eHBsYWluIEkgaGF2ZSBBcGFjaGUgMi4yLjQgcnVubmluZyBvbiBGZWRvcmEK PiBDb3JlIDUgd2l0
aCBQSFAgNSBhbmQgTXlzcWwgNTsgSSd2ZSBpbnN0YWxsZWQgdGhlIGFwYWNo ZSB3aXRoIGRlZmF1
bHQKPiBvcHRpb25zLCAiY29uZmlndXJlIC0tZW5hYmxlLXNvIiwgIEkgc2F3 IHRoYXQgZGVmYXVs
dCBNUE0gaW5zdGFsbGVkIHdhcwo+IHByZWZ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Bu
ZXcgY2hpbGQKYW5kIGNhcnJ5IG9uCmJ1dCB3aXRoIHdvcmtlciB5b3UnbGwg YmUgdGFraW5nIG91
dCBtYW55IHJlcXVlc3RzIGF0IHRoZSBzYW1lIHRpbWUuCgpUaGlzIGlzIGFs bCBiYXNlZCBvbiBo
ZWFyc2F5OyBJJ3ZlIG5ldmVyIHRyaWVkIHBocCBhbmQgd29ya2VyIGluCnBy b2R1Y3Rpb24sIGJ1
dCB0aGV5IHNlZW0gZmluZSBvbiBteSBkZXZlbG9wbWVudCBib3guCgotLSAK bm9vZGwK

Apache consuming lot of memory

am 20.08.2007 18:27:44 von sir_ddd

Hi All,

I have running Apache 2.2.4 with PHP 5.2 and Mysql 5 on Fedora 5, my server
has 2GB RAM and only it runs a php runtime with flash embedded that stream
MP3 files for 300 simultaneus users...

My point is that apache is consuming about 1.80GB!!!! I feel that it's not
correct, my prefork MPM config is...


StartServers 3
MinSpareServers 5
MaxSpareServers 10
MaxClients 300
MaxRequestsPerChild 10000


Other parameters are:

Timeout 30
KeepAlive On
MaxKeepAliveRequests 1000
KeepAliveTimeout 3

Also the CPU load is max 6% use..

I've been reading differents docs, What can I do to ensure that Apache just
consume the necesary memory?

thanks in advance....

David

____________________________________________________________ _____
Horóscopo, tarot, numerología... Escucha lo que te dicen los astros.
http://astrocentro.msn.es/


------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

Re: Apache consuming lot of memory

am 21.08.2007 03:34:06 von Jeff Peng

-------- Original-Nachricht --------
> Datum: Mon, 20 Aug 2007 18:27:44 +0200
> Von: "David Díaz Díaz"
> An: users@httpd.apache.org
> Betreff: [users@httpd] Apache consuming lot of memory

> Hi All,
>
> I have running Apache 2.2.4 with PHP 5.2 and Mysql 5 on Fedora 5, my
> server
> has 2GB RAM and only it runs a php runtime with flash embedded that stream
> MP3 files for 300 simultaneus users...
>
> My point is that apache is consuming about 1.80GB!!!! I feel that it's not
> correct, my prefork MPM config is...
>
>
> StartServers 3
> MinSpareServers 5
> MaxSpareServers 10
> MaxClients 300
> MaxRequestsPerChild 10000
>

>
> Other parameters are:
>
> Timeout 30
> KeepAlive On
> MaxKeepAliveRequests 1000
> KeepAliveTimeout 3
>
> Also the CPU load is max 6% use..
>
> I've been reading differents docs, What can I do to ensure that Apache
> just
> consume the necesary memory?
>


There is almost nothing reasons on those parameters setting,but it seems your application program itself is large.
Also after install Apache,you could strip httpd to reduce some memory usage.
--
Psssst! Schon vom neuen GMX MultiMessenger gehört?
Der kanns mit allen: http://www.gmx.net/de/go/multimessenger

------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

Re: Apache consuming lot of memory

am 21.08.2007 17:19:08 von Joshua Slive

On 8/20/07, Jeff Peng wrote:

>
> There is almost nothing reasons on those parameters setting,but it seems your application program itself is large.
> Also after install Apache,you could strip httpd to reduce some memory usage.

I doubt that stripping the binary is going to do any good.

But yes, it is almost certainly your php app that is allocating all
that memory. You should look there before looking at th apache config.

Joshua.

------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

Re: Apache consuming lot of memory

am 22.08.2007 03:55:38 von solidzh

2007/8/21, Joshua Slive :
> On 8/20/07, Jeff Peng wrote:
>
> >
> > There is almost nothing reasons on those parameters setting,but it seems your application program itself is large.
> > Also after install Apache,you could strip httpd to reduce some memory usage.
>
> I doubt that stripping the binary is going to do any good.
>

Why not? I once also striped the httpd,it reduce the size from 2M to 300K.
If you're running 300 httpd,this really reduce some memory.

------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

Re: Apache consuming lot of memory

am 22.08.2007 04:42:00 von Joshua Slive

On 8/21/07, solidzh wrote:
> 2007/8/21, Joshua Slive :
> > On 8/20/07, Jeff Peng wrote:
> >
> > >
> > > There is almost nothing reasons on those parameters setting,but it seems your application program itself is large.
> > > Also after install Apache,you could strip httpd to reduce some memory usage.
> >
> > I doubt that stripping the binary is going to do any good.
> >
>
> Why not? I once also striped the httpd,it reduce the size from 2M to 300K.
> If you're running 300 httpd,this really reduce some memory.

That's just the size of the binary on disk. It normally won't have an
effect on actual memory usage. And even if it does have an effect, it
is in a part of memory that can be shared between all the processes.

Joshua.

------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

Re: Apache consuming lot of memory

am 22.08.2007 06:18:47 von solidzh

2007/8/22, Joshua Slive :
> On 8/21/07, solidzh wrote:
> > 2007/8/21, Joshua Slive :
> > > On 8/20/07, Jeff Peng wrote:
> > >
> > > >
> > > > There is almost nothing reasons on those parameters setting,but it seems your application program itself is large.
> > > > Also after install Apache,you could strip httpd to reduce some memory usage.
> > >
> > > I doubt that stripping the binary is going to do any good.
> > >
> >
> > Why not? I once also striped the httpd,it reduce the size from 2M to 300K.
> > If you're running 300 httpd,this really reduce some memory.
>
> That's just the size of the binary on disk. It normally won't have an
> effect on actual memory usage. And even if it does have an effect, it
> is in a part of memory that can be shared between all the processes.
>

Sorry but why it's shared by all the processes?From my
understanding,all processes have their own memory area for storing
codes.

------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org

Re: Apache consuming lot of memory

am 22.08.2007 15:16:01 von Joshua Slive

On 8/22/07, solidzh wrote:
> 2007/8/22, Joshua Slive :
> > On 8/21/07, solidzh wrote:
> > > 2007/8/21, Joshua Slive :
> > > > On 8/20/07, Jeff Peng wrote:
> > > >
> > > > >
> > > > > There is almost nothing reasons on those parameters setting,but it seems your application program itself is large.
> > > > > Also after install Apache,you could strip httpd to reduce some memory usage.
> > > >
> > > > I doubt that stripping the binary is going to do any good.
> > > >
> > >
> > > Why not? I once also striped the httpd,it reduce the size from 2M to 300K.
> > > If you're running 300 httpd,this really reduce some memory.
> >
> > That's just the size of the binary on disk. It normally won't have an
> > effect on actual memory usage. And even if it does have an effect, it
> > is in a part of memory that can be shared between all the processes.
> >
>
> Sorry but why it's shared by all the processes?From my
> understanding,all processes have their own memory area for storing
> codes.

A modern OS will minimize memory usage by sharing memory between
multiple instances of the same binary wherever possible.

Joshua.

------------------------------------------------------------ ---------
The official User-To-User support forum of the Apache HTTP Server Project.
See for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org