Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:51033 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 6871 invoked from network); 15 Dec 2010 11:58:59 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 15 Dec 2010 11:58:59 -0000 Authentication-Results: pb1.pair.com header.from=jond3k@gmail.com; sender-id=pass; domainkeys=bad Authentication-Results: pb1.pair.com smtp.mail=jond3k@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.160.170 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: jond3k@gmail.com X-Host-Fingerprint: 209.85.160.170 mail-gy0-f170.google.com Received: from [209.85.160.170] ([209.85.160.170:60868] helo=mail-gy0-f170.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 43/00-06741-28DA80D4 for ; Wed, 15 Dec 2010 06:58:58 -0500 Received: by gyf2 with SMTP id 2so1008710gyf.29 for ; Wed, 15 Dec 2010 03:58:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=ftEkyds/y+tnkabuKgY3yDwCb9svcWB72jED/KdGGz8=; b=eykMR3TVg6fVx3TS5kN+xf+aAuRWbafSMLMdCRX8dWXcIkuibcOINbSp/5p004vHU+ 4EnLJDTw8EZPSFyD9gFdlA64Bv6/nNc3m+GjnuvZ8XevwGJ+3WIuRehjHFHmm+TAPckY 7bhNpjOovkfuUqelcJUAYPg+8Cv3XJNXn9iI0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=aSoGDxVVnhHG6Ete3CAxO8p2sgQDUgMg3SyN63fSmbh1eSOVERzySpZP9cvxlvWYE6 v4hoOI7mpbOZM4IeCxJn8qwE+YRhlxC70vk7MfsUcl6qBuD8mqLZZIRJcNlY9RaesN5j O/ZrwlpDlfaeVchM/wW1yP57JQsqETAizba/U= MIME-Version: 1.0 Received: by 10.101.136.29 with SMTP id o29mr4402114ann.58.1292414335898; Wed, 15 Dec 2010 03:58:55 -0800 (PST) Received: by 10.100.174.1 with HTTP; Wed, 15 Dec 2010 03:58:55 -0800 (PST) In-Reply-To: References: Date: Wed, 15 Dec 2010 11:58:55 +0000 Message-ID: To: Julien Pauli Cc: jvlad , internals@lists.php.net Content-Type: text/plain; charset=ISO-8859-1 Subject: Re: [PHP-DEV] Re: PHP Performance in Apache: Multi-Process vs Multi-Threaded From: jond3k@gmail.com (Jon Davey) 2010/12/15 Julien Pauli > > Well, I would say that if your problem is memory, you should consider > threads as they all share the same memory space in their process. > > Apache's children can weight very heavy if PHP's been compiled to > support lots of extensions, you can happen with ~40/50Mb per process > which is very huge. Considerating 50 parallel processes eat up 2-3Gb > for example. > Surely creating a fork of a 50MB process will not consume an additional 50MB because of copy-on-write virtual memory? I would think you would only see this growth in memory usage if the extensions maintained a large payload of data that was being heavily modified in each request, such as caches, but I expect they create their own shared memory segments (I have yet to check the source of APC). Jon