Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:49683 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 46972 invoked from network); 16 Sep 2010 02:13:12 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 16 Sep 2010 02:13:12 -0000 Authentication-Results: pb1.pair.com smtp.mail=jravimenon@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=jravimenon@gmail.com; sender-id=pass; domainkeys=bad 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:64738] helo=mail-ww0-f54.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 38/96-33442-73D719C4 for ; Wed, 15 Sep 2010 22:13:12 -0400 Received: by wwb22 with SMTP id 22so514642wwb.11 for ; Wed, 15 Sep 2010 19:13:08 -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=rDLCW8DW7j7DCNLM0Faf44AMyCJPcvEB+BthxY3TXT4=; b=APKyoAzw7g2QYhyfZRZ7/IrPGQouCBeGIjBIXnhiiMqCPxIeQIRiZwxxFgKkf7LXFQ QhSKU/D9Oez/rHY5RrTuDJbAzKFnC72SDXMVkAzdwRquYIfrpQrYeC8Qtf3TUfsLPaFc VOwzmgZQ+81cZUe6ZTBIYzoQrVWehslDSxbu4= 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=cHgnpT4F7APLHpUDxu+fdv4zXMFwUJ4o++7ajcrlb+gOO4oHKQCXN7PzufdmrkAAPE RJGsMcBW76hGmK2GBCPOWDYvpD6r2kjdzK4dkR1vzZ+LEd8wpg5tnwLTd3pgoQXlHdTz +s9W6cBUZlQThqgy2gwiHk1qaLb8+48bg9hiY= MIME-Version: 1.0 Received: by 10.216.59.148 with SMTP id s20mr6050030wec.41.1284603188498; Wed, 15 Sep 2010 19:13:08 -0700 (PDT) Received: by 10.216.160.133 with HTTP; Wed, 15 Sep 2010 19:13:08 -0700 (PDT) In-Reply-To: References: <4C910E9C.7040004@lerdorf.com> Date: Wed, 15 Sep 2010 19:13:08 -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 12:40 PM, J Ravi Menon wrote= : > On Wed, Sep 15, 2010 at 11:21 AM, Rasmus Lerdorf wro= te: >> 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. > So with this mod_php like behavior, do we also need to have apc enabled in this setup for the opcode cache? As a cli daemon, I am assuming this is not necessary? thx, Ravi > >>> 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. =A0Fro= m >> 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 >> >> >