Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 6 Apr 2023 09:19:37 -0400
From:      "Kevin P. Neal" <kpn@neutralgood.org>
To:        William Dudley <wfdudley@gmail.com>
Cc:        questions@freebsd.org
Subject:   Re:  updated to 13.1 (i386). Apache won't run if php80 enabled
Message-ID:  <ZC7G6cZgolyuBVhu@neutralgood.org>
In-Reply-To: <22bb0a77-30e3-846f-0f43-573d6697c40b@FreeBSD.org>
References:  <CAFsnNZJxHSFc-Tb2PmLq59HWNxD6SNjwQqnPneJfRXqMipUw8g@mail.gmail.com> <20230406070831.a6f09f389baed2a6ff4dbbbb@sohara.org> <CAAdA2WMovgFWBC6A2ApA9==k4WH-PpnY8GVs1Ww4CC-Myid3Pg@mail.gmail.com> <22bb0a77-30e3-846f-0f43-573d6697c40b@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Apr 06, 2023 at 08:08:50AM +0100, Matthew Seaman wrote:
> On 06/04/2023 07:18, Odhiambo Washington wrote:
> > On Thu, Apr 6, 2023 at 9:09 AM Steve O'Hara-Smith <steve@sohara.org> wrote:
> > 
> >> On Wed, 5 Apr 2023 11:09:37 -0400
> >> William Dudley <wfdudley@gmail.com> wrote:
> >>
> >>> I have another machine running 13.1, but it's amd64.  It happily runs
> >>> Apache with php80, so I downgraded the i386 machine to php80
> >>> so the two machines would be "the same".
> >>>
> >>> Except this didn't fix the problem.  Apache won't run with either php80
> >>> OR php81 enabled, using this stanza in httpd.conf:
> >>
> >>          Two possibilities spring to mind
> >>
> >>          - the two machines are not "the same", check all relevant package
> >> versions right down the dependency tree.
> >>
> >>          - The code depends on a feature not in one CPU or something of that
> >> order. Given that PHP and Apache work independently the glue is the prime
> >> suspect, I'd try building mod-php from ports.
> >>
> > 
> > He wants to keep things simple, so he prefers pkg install... no ports.
> 
> In that case, he needs to use mod_php from php81 which is the current 
> default version of PHP used by the FreeBSD pkg system.  The way apache 
> works by loading a binary module with an embedded php interpreter into 
> the apache process itself is quite restrictive in that regard.

Right, and if he's running the latest package of Apache but a backlevel
php80 then that's a problem.

> Personally, I'd configure a php web app to use a separate php-fpm daemon 
> and front that with nginx proxying through to the fpm port: a similar 
> approach is possible with apache which might prove useful.

I'm a fan of Apache and I use it with php-fpm to run NextCloud. It works
well. I'm not sure what is harder to get running, though, php inside of
Apache (with mod_php) or Apache+php-fpm. I tried Apache with mod_php first
but switched away because it didn't support HTTP/2. Using Apache+php-fpm
does give me HTTP/2 and once I got that running I left it alone.

-- 
Kevin P. Neal                                http://www.pobox.com/~kpn/
      'Concerns about "rights" and "ownership" of domains are inappropriate.  
 It is appropriate to be concerned about "responsibilities" and "service" 
 to the community.' -- RFC 1591, page 4: March 1994



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?ZC7G6cZgolyuBVhu>