Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:49675 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 736 invoked from network); 15 Sep 2010 19:40:45 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 15 Sep 2010 19:40:45 -0000 Authentication-Results: pb1.pair.com header.from=jravimenon@gmail.com; sender-id=pass; domainkeys=bad Authentication-Results: pb1.pair.com smtp.mail=jravimenon@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 74.125.82.54 as permitted sender) DomainKey-Status: bad X-DomainKeys: Ecelerity dk_validate implementing draft-delany-domainkeys-base-01 X-PHP-List-Original-Sender: jravimenon@gmail.com X-Host-Fingerprint: 74.125.82.54 mail-ww0-f54.google.com Received: from [74.125.82.54] ([74.125.82.54:60574] helo=mail-ww0-f54.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 44/AF-33442-C31219C4 for ; Wed, 15 Sep 2010 15:40:45 -0400 Received: by wwb22 with SMTP id 22so132924wwb.11 for ; Wed, 15 Sep 2010 12:40:42 -0700 (PDT) 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 :content-transfer-encoding; bh=o/GpgHS7wnzaLmF+glmvHmF2mVaveR2v+ae7FoFujbY=; b=dFCfor+MT1rapiAANHyDcC0BRCJ6WN5dmthRsdVgENAwgCZWcLSbTNVRMefTEH67xV eJZtlApsGPis4nKlZGf3uMV1oAhtPzIKXLQMTirSEz3muWgPCqeAJvdI4mk72aiOIzjW TUudW5NyuYWYc+sVw0PDdDGRRBE+iMpXcgjkU= 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:content-transfer-encoding; b=l9T4Tpj17zWVyGuson24wTYwcv7L0iFo/mBwzxyECBV4j0HEMe+c9kn7eAz6EMmFI7 aXe4hr0e5znSx1b3oNpVnuvV9SOTy5mrJ7rH807i3s9igGhMM1GKeVtDZW6vZhk2pJ6r 2dPjJL3lw6n8OLZUxeZWtm0q8Na8ryjl+Ju6Q= MIME-Version: 1.0 Received: by 10.216.233.234 with SMTP id p84mr1784516weq.38.1284579641276; Wed, 15 Sep 2010 12:40:41 -0700 (PDT) Received: by 10.216.160.133 with HTTP; Wed, 15 Sep 2010 12:40:41 -0700 (PDT) In-Reply-To: <4C910E9C.7040004@lerdorf.com> References: <4C910E9C.7040004@lerdorf.com> Date: Wed, 15 Sep 2010 12:40:41 -0700 Message-ID: To: Rasmus Lerdorf Cc: internals@lists.php.net Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [PHP-DEV] nginx+php-fpm question From: jravimenon@gmail.com (J Ravi Menon) On Wed, Sep 15, 2010 at 11:21 AM, Rasmus Lerdorf wrote= : > On 9/15/10 10:57 AM, J Ravi Menon wrote: >> =A0So my guess is, if we do php-fpm approach, we have to do all these >> cleanups manually? =A0Or are there simpler solutions or hook-ups that >> does it automatically at the end of the request cycle? > > No, fastcgi doesn't change this model at all. =A0You have the same > end-of-requests cleanups as with mod_php. > Ah good to know. >> 2) My other concern is the extra ipc overhead between >> nginx<---->php-fpm servers even on unix sockets. To me in theory >> apache+mod_php ( + apc with stat off) should be as efficient as you >> can get. Granted nginx might be more efficient in its socket mgmt >> (non-blocking event-driven i/o), but can it really outperform the >> apache approach given the issues in (1) are resolved? > > In theory that extra ipc should make the nginx case slower, true. =A0From > what I have been able to measure, that is rarely a factor though. > > You can take a look at this slide from a recent talk of mine: > > =A0http://talks.php.net/show/drupalconcph/11 > > That's testing a vanilla Drupal setup on Apache, PHP-FPM-nginx and > PHP-FPM-lighttpd. =A0The dashed lines show the latency, the solid lines > the requests/sec. A lot here will depend upon the typical payload size. If compression is done at the fcgi server end, I can see why it may not matter much. Thx, Ravi > > -Rasmus > >