You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following code: not a specific code
Resulted in this output: -
But I expected this output instead: -
I got some random segfault in php-fpm. It occurs time to time. In the logs of php-fpm I see "child XXX exited on signal 11 (SIGSEGV - core dumped) after ...".
The code is running inside a kubernetes cluster, running some container.
The php extension : php -r 'foreach (get_loaded_extensions() as $extension) echo "$extension: " . phpversion($extension) . "\n";'
I got a trace of the segfault (open it using gdb, bt full)
e4045a668378:/srv/app# gdb /usr/local/sbin/php-fpm /toto/core.php-fpm.82.257cdc11538f4aabb7801c14049cacc9.3137728.1747058258000000/core.php-fpm.82.257cdc11538f4aabb7801c14049cacc9.3137728.1747058258000000
GNU gdb (GDB) 15.2
Copyright (C) 2024 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-alpine-linux-musl".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/local/sbin/php-fpm...
(No debugging symbols found in /usr/local/sbin/php-fpm)
warning: Can't open file /dev/zero (deleted) during file-backed mapping note processing
[New LWP 11232]
[New LWP 11220]
Core was generated by `php-fpm:'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 a_crash () at ./arch/x86_64/atomic_arch.h:108
warning: 108 ./arch/x86_64/atomic_arch.h: No such file or directory
[Current thread is 1 (LWP 11232)]
(gdb) bt full
#0 a_crash () at ./arch/x86_64/atomic_arch.h:108
No locals.
#1 get_meta (p=p@entry=0x7f2ed840c0e0 "\300\0026\330.\177") at src/malloc/mallocng/meta.h:141
offset = 0
index = 31
base = 0x7f2ed840c0d0
meta = 0x7f2ed84d2800
area = <optimized out>
#2 0x00007f2eddffbb9f in __libc_free (p=0x7f2ed840c0e0) at src/malloc/mallocng/free.c:105
g = <optimized out>
idx = <optimized out>
stride = <optimized out>
start = <optimized out>
end = <optimized out>
self = <optimized out>
all = <optimized out>
mi = <optimized out>
base = <optimized out>
len = <optimized out>
e = <optimized out>
#3 0x00007f2edb820a20 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#4 0x00007f2edb830382 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#5 0x00007f2edb8337db in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#6 0x00007f2edb5bb8ea in std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release_last_use_cold() () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#7 0x00007f2edb827de0 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#8 0x00007f2edb82c8c3 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#9 0x00007f2edb82c95b in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#10 0x00007f2edb82cc8d in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#11 0x00007f2edb849de3 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#12 0x00007f2edb84b918 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#13 0x00007f2edb84ba8e in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#14 0x00007f2edba22b70 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#15 0x00007f2ede01c9d2 in start (p=0x7f2ed8360750) at src/thread/pthread_create.c:207
args = 0x7f2ed8360750
state = <optimized out>
#16 0x00007f2ede01e314 in __clone () at src/thread/x86_64/clone.s:22
--Type <RET> for more, q to quit, c to continue without paging--
No locals.
Backtrace stopped: frame did not save the PC
(gdb) bt full
#0 a_crash () at ./arch/x86_64/atomic_arch.h:108
No locals.
#1 get_meta (p=p@entry=0x7f2ed840c0e0 "\300\0026\330.\177") at src/malloc/mallocng/meta.h:141
offset = 0
index = 31
base = 0x7f2ed840c0d0
meta = 0x7f2ed84d2800
area = <optimized out>
#2 0x00007f2eddffbb9f in __libc_free (p=0x7f2ed840c0e0) at src/malloc/mallocng/free.c:105
g = <optimized out>
idx = <optimized out>
stride = <optimized out>
start = <optimized out>
end = <optimized out>
self = <optimized out>
all = <optimized out>
mi = <optimized out>
base = <optimized out>
len = <optimized out>
e = <optimized out>
#3 0x00007f2edb820a20 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#4 0x00007f2edb830382 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#5 0x00007f2edb8337db in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#6 0x00007f2edb5bb8ea in std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release_last_use_cold() () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#7 0x00007f2edb827de0 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#8 0x00007f2edb82c8c3 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#9 0x00007f2edb82c95b in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#10 0x00007f2edb82cc8d in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#11 0x00007f2edb849de3 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#12 0x00007f2edb84b918 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#13 0x00007f2edb84ba8e in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#14 0x00007f2edba22b70 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#15 0x00007f2ede01c9d2 in start (p=0x7f2ed8360750) at src/thread/pthread_create.c:207
args = 0x7f2ed8360750
state = <optimized out>
#16 0x00007f2ede01e314 in __clone () at src/thread/x86_64/clone.s:22
--Type <RET> for more, q to quit, c to continue without paging--
No locals.
Backtrace stopped: frame did not save the PC
(gdb) bt full
#0 a_crash () at ./arch/x86_64/atomic_arch.h:108
No locals.
#1 get_meta (p=p@entry=0x7f2ed840c0e0 "\300\0026\330.\177") at src/malloc/mallocng/meta.h:141
offset = 0
index = 31
base = 0x7f2ed840c0d0
meta = 0x7f2ed84d2800
area = <optimized out>
#2 0x00007f2eddffbb9f in __libc_free (p=0x7f2ed840c0e0) at src/malloc/mallocng/free.c:105
g = <optimized out>
idx = <optimized out>
stride = <optimized out>
start = <optimized out>
end = <optimized out>
self = <optimized out>
all = <optimized out>
mi = <optimized out>
base = <optimized out>
len = <optimized out>
e = <optimized out>
#3 0x00007f2edb820a20 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#4 0x00007f2edb830382 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#5 0x00007f2edb8337db in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#6 0x00007f2edb5bb8ea in std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release_last_use_cold() () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#7 0x00007f2edb827de0 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#8 0x00007f2edb82c8c3 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#9 0x00007f2edb82c95b in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#10 0x00007f2edb82cc8d in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#11 0x00007f2edb849de3 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#12 0x00007f2edb84b918 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#13 0x00007f2edb84ba8e in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#14 0x00007f2edba22b70 in ?? () from /usr/local/lib/php/extensions/no-debug-non-zts-20230831/grpc.so
No symbol table info available.
#15 0x00007f2ede01c9d2 in start (p=0x7f2ed8360750) at src/thread/pthread_create.c:207
args = 0x7f2ed8360750
state = <optimized out>
#16 0x00007f2ede01e314 in __clone () at src/thread/x86_64/clone.s:22
Docker was built using the alpine image from docker hub php:8.3.21-fpm-alpine. It running in non-root user and is using apache through the socket file.
thanks
PHP Version
PHP 8.3.21 (cli) (built: May 9 2025 17:25:07) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.3.21, Copyright (c) Zend Technologies
with Zend OPcache v8.3.21, Copyright (c), by Zend Technologies
Operating System
alpine
The text was updated successfully, but these errors were encountered:
Description
The following code: not a specific code
Resulted in this output: -
But I expected this output instead: -
I got some random segfault in php-fpm. It occurs time to time. In the logs of php-fpm I see "child XXX exited on signal 11 (SIGSEGV - core dumped) after ...".
The code is running inside a kubernetes cluster, running some container.
The php extension :
php -r 'foreach (get_loaded_extensions() as $extension) echo "$extension: " . phpversion($extension) . "\n";'
I got a trace of the segfault (open it using gdb, bt full)
Docker was built using the alpine image from docker hub
php:8.3.21-fpm-alpine
. It running in non-root user and is using apache through the socket file.thanks
PHP Version
Operating System
alpine
The text was updated successfully, but these errors were encountered: