Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id A2415200BB1 for ; Thu, 3 Nov 2016 20:14:59 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 9BE71160AFF; Thu, 3 Nov 2016 19:14:59 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 6F364160AE5 for ; Thu, 3 Nov 2016 20:14:58 +0100 (CET) Received: (qmail 69964 invoked by uid 500); 3 Nov 2016 19:14:56 -0000 Mailing-List: contact users-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: users@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@httpd.apache.org Received: (qmail 69953 invoked by uid 99); 3 Nov 2016 19:14:56 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 03 Nov 2016 19:14:56 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 59BAEC0957 for ; Thu, 3 Nov 2016 19:14:56 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.38 X-Spam-Level: ** X-Spam-Status: No, score=2.38 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (1024-bit key) header.d=pitechnologies.ro Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id CL_MuqxEWLKC for ; Thu, 3 Nov 2016 19:14:54 +0000 (UTC) Received: from mail-wm0-f43.google.com (mail-wm0-f43.google.com [74.125.82.43]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id D12FB5F24F for ; Thu, 3 Nov 2016 19:14:53 +0000 (UTC) Received: by mail-wm0-f43.google.com with SMTP id n67so6770432wme.1 for ; Thu, 03 Nov 2016 12:14:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pitechnologies.ro; s=google; h=from:to:references:in-reply-to:subject:date:message-id:mime-version :thread-index:content-language; bh=3UfArDDA8vuG+0MU7CwR6onb9hjmjPDvI012jw0EpDc=; b=KZRejmVsUjwu5xK2DuizTdjMcGCXczMCm2B415tSbHDcVAGoCMhaGa2zFN+FfUxqd5 Vvdh8MFGpWbRD0txwM8vhspBcVzmD46j+BPEdt+Qvj5uSFMFw+utYt/BFGGdvx7euFUU /E/KWpT1cWESECptcrnlBmriwSr4HvB3037fA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:references:in-reply-to:subject:date :message-id:mime-version:thread-index:content-language; bh=3UfArDDA8vuG+0MU7CwR6onb9hjmjPDvI012jw0EpDc=; b=RFR4Gt5lm+7A7lPKovJX0BnorHpc655cgHUHgckxR/7N4irdKj9C0CucybUcErAzpo 2owp55REKjf+iRr00hQbpZlsjLKeGYdvJTqM9J0jSR/dtgguqalA4Q3GFKKkCiNKzyLl 1azCskcwOAVZhbsVXYAsbo3N4SY4HEo41KumCRegeVhaFLVYIAVNZuJlze6kNugrKwA0 ijovtbRjDxddU7wzaji1OOqeZmvmHyGDc9j8j7LUZxCoTFZdfDMmeIxihehCerpfX7mi iou2xMfuLx+ikrhSgUpxHwthCwNNPmE3h6NSRbA2rBuatXBeRaA/LVBBRGggSFslJZ5j G+SA== X-Gm-Message-State: ABUngvepsR8vaYvs63rQR/qE1TAQXjtjwF0g98Jxw+uJCfrwDNcF7Fxs9F3dS6sasFeXI0SH X-Received: by 10.194.60.106 with SMTP id g10mr10074926wjr.151.1478200477827; Thu, 03 Nov 2016 12:14:37 -0700 (PDT) Received: from titexpc ([188.24.88.61]) by smtp.gmail.com with ESMTPSA id t129sm487326wmg.23.2016.11.03.12.14.36 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 03 Nov 2016 12:14:37 -0700 (PDT) From: "Alexandru Duzsardi" To: References: In-Reply-To: Date: Thu, 3 Nov 2016 21:14:38 +0200 Message-ID: <010301d23606$86306d30$92914790$@pitechnologies.ro> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0104_01D23617.49BCE6B0" X-Mailer: Microsoft Outlook 16.0 Thread-Index: AQHV+Gt94aQSq9oDFT1ns7MgaMtivqDAG8Og Content-Language: en-us Subject: RE: [users@httpd] How does this configuration work? archived-at: Thu, 03 Nov 2016 19:14:59 -0000 ------=_NextPart_000_0104_01D23617.49BCE6B0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Usually /var/run and /run are symlinks one of the other=20 so that makes /var/rum/php7.0-fpm.sock and /run/php7.0-fpm.sock the same = unix domain socket =20 From: Jason Brooks [mailto:jason.brooks@eroi.com]=20 Sent: Thursday, November 3, 2016 9:07 PM To: users@httpd.apache.org Subject: [users@httpd] How does this configuration work? =20 Hello, =20 So, the need to make sense of this is not an issue: I will be using the = mod_proxy_fcgi to use php-fpm. I am just curious. =20 While trying various configurations to get php-fpm to work, I found the = following conundrum: the following configuration should NOT work but it = does... =20 Here is the apache configuration snippet derived from this site = dated last August. =20 Require all granted=20 =20 =20 AddHandler php7-fcgi .php=20 Action php7-fcgi /php7-fcgi virtual=20 Alias /php7-fcgi /usr/lib/cgi-bin/php7-fcgi=20 FastCgiExternalServer /usr/lib/cgi-bin/php7-fcgi -socket = /var/run/php/php7.0-fpm.sock -pass-header Authorization =20 Here is the php-fpm www pool socket definition as configured = out-of-the-box: listen =3D /run/php/php7.0-fpm.sock =20 My test php script calls phpinfo() only. It works. It=E2=80=99s not = clear how it works. =20 Apache opens /var/run/php/php7.0-fpm.sock php-fpm opens /run/php/php7.0-fpm.sock removal of either file causes php not to work. When I point apache to the socket file php-fpm opens, it = does not work. =20 HOW? How does apache manage to connect to php-fpm when the defined = socket paths do not make sense? As far as I know, the unix socket file = is simply opened and read/written to: there=E2=80=99s no way to tell = linux =E2=80=9Cconnect both files to each other=E2=80=9D from within a = program... =20 Thanks for your time! =20 =20 Jason Brooks Systems Administrator eROI Performance is Art. =20 =20 m: 505 nw couch #300 w: eroi.com t: 503.290.3105 f: 503.228.4249 =09 fb: fb.com/eROI =09 =20 =20 ------=_NextPart_000_0104_01D23617.49BCE6B0 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable

Usually /var/run and /run are symlinks one of the other =

so that makes /var/rum/php7.0-fpm.sock and /run/php7.0-fpm.sock the = same unix domain socket

 

From:<= /b> = Jason Brooks [mailto:jason.brooks@eroi.com]
Sent: Thursday, = November 3, 2016 9:07 PM
To: = users@httpd.apache.org
Subject: [users@httpd] How does this = configuration work?

 

Hello,

 

So, the need to make sense of this is not an issue: I = will be using the mod_proxy_fcgi to use php-fpm.  I am just = curious.

 

While trying various configurations to get php-fpm to = work, I found the following conundrum: the following configuration = should NOT work but it does...

 

Here is the apache configuration snippet derived = from this site dated last = August.

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 <Directory = /usr/lib/cgi-bin> 

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 Require all = granted 

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 =  </Directory> 

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0  <IfModule = mod_fastcgi.c> 

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 AddHandler php7-fcgi = .php 

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 Action php7-fcgi /php7-fcgi = virtual 

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0 Alias /php7-fcgi = /usr/lib/cgi-bin/php7-fcgi 

              =   FastCgiExternalServer /usr/lib/cgi-bin/php7-fcgi -socket = /var/run/php/php7.0-fpm.sock -pass-header = Authorization

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 </IfModule>

 

Here is the php-fpm www pool socket definition as = configured out-of-the-box:

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 listen =3D = /run/php/php7.0-fpm.sock

 

My test php script calls phpinfo() only.  It = works.  It=E2=80=99s not clear how it works. =  

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 Apache opens = /var/run/php/php7.0-fpm.sock

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 php-fpm opens = /run/php/php7.0-fpm.sock

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 removal of either file causes php not to = work.

=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 When I point apache to the socket file php-fpm = opens, it does not work.

 

HOW?  How does apache manage to connect to = php-fpm when the defined socket paths do not make sense?  As far as = I know, the unix socket file is simply opened and read/written to: = there=E2=80=99s no way to tell linux =E2=80=9Cconnect both files to each = other=E2=80=9D from within a program...

 

Thanks for your time!

 

 

Jason Brooks

Systems Administrator

eROI

Performance is Art.

 

 

=

m:

505 nw couch #300

w:

eroi.com

t:

503.290.3105

f:

503.228.4249

fb:

fb.com/eROI

=  

=

 

------=_NextPart_000_0104_01D23617.49BCE6B0--