Bug #79231 [Opn->Dup]: Segfault when preloading via php-fpm

From: Date: Wed, 05 Feb 2020 14:57:23 +0000
Subject: Bug #79231 [Opn->Dup]: Segfault when preloading via php-fpm
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-225376@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=79231&edit=1

 ID:                 79231
 Updated by:         nikic@php.net
 Reported by:        brent at spatie dot be
 Summary:            Segfault when preloading via php-fpm
-Status:             Open
+Status:             Duplicate
 Type:               Bug
 Package:            opcache
 Operating System:   Ubuntu 18.04.3 LTS
 PHP Version:        7.4.2
 Block user comment: N
 Private report:     N

 New Comment:

Assuming you meant opcache.preload_user rather than opcache.user, this is a duplicate of bug #79128.


Previous Comments:
------------------------------------------------------------------------
[2020-02-05 12:18:29] brent at spatie dot be

Description:
------------
I've been trying out preloading, and am running into a segfault using PHP 7.4.2, only when
using php-fpm.

I've been using this preload script: https://github.com/brendt/aggregate.stitcher.io/blob/master/preload.php

When using this preload script via PHP's built-in webserver, all works fine. For reference,
this is the command I used to test this: php -c /etc/php/7.4/fpm/php.ini -S
aggregate.stitcher.io:8001 -t public -d opcache.preload=preload.php -d opcache.user=forge

However, when using the same preloading script via php-fpm, a segfault occurs. Here's a snippet
from the php-fpm logs, this message gets repeated over and over again:

```
[05-Feb-2020 12:06:01] WARNING: [pool www] child 2961 exited on signal 11 (SIGSEGV - core dumped)
after 0.942953 seconds from start
[05-Feb-2020 12:06:01] NOTICE: [pool www] child 2972 started
[05-Feb-2020 12:06:01] WARNING: [pool www] child 2963 exited on signal 11 (SIGSEGV - core dumped)
after 0.947206 seconds from start
[05-Feb-2020 12:06:01] NOTICE: [pool www] child 2977 started
[05-Feb-2020 12:06:01] WARNING: [pool www] child 2965 exited on signal 11 (SIGSEGV - core dumped)
after 1.009507 seconds from start
[05-Feb-2020 12:06:01] NOTICE: [pool www] child 2979 started
```

Checking php-fpm's status using sudo service php7.4-fpm status after restarting
it, I get the following output:

```
…
Feb 05 12:04:42 brent php-fpm7.4[2039]: [Preloader] Preloaded
Illuminate\Mail\TransportManager
Feb 05 12:04:42 brent php-fpm7.4[2039]: [Preloader] Preloaded Illuminate\Mail\Markdown
Feb 05 12:04:42 brent php-fpm7.4[2039]: [Preloader] Preloaded 1127 classes
Feb 05 12:04:42 brent systemd[1]: Started The PHP 7.4 FastCGI Process Manager.
```

So php-fpm manages to start, it only crashes as soon as a request arrives at the server. 

Anything I can do to provide more information? 



------------------------------------------------------------------------



--
Edit this bug report at https://bugs.php.net/bug.php?id=79231&edit=1


Thread (2 messages)

« previous php.bugs (#225376) next »