chuan-yun / Molten

php probe for zipkin and opentracing
Apache License 2.0
792 stars 160 forks source link

Segfault with molten 0.1.2 and php 7.2 with opcache #109

Open remicollet opened 5 years ago

remicollet commented 5 years ago

FPM segfault on startup when both opcache and molten are loaded.

(gdb) bt
#0  0x00007fd72c8faa1c in zend_string_hash_val (s=0xe8738e16c172886c) at /usr/src/debug/php-7.2.12-1.fc29.remi.x86_64/Zend/zend_string.h:97
#1  0x00007fd72c8faa1c in accel_new_interned_string (str=0xe8738e16c172886c) at /usr/src/debug/php-7.2.12-1.fc29.remi.x86_64/ext/opcache/ZendAccelerator.c:448
#2  0x00007fd72c8f9fea in accel_copy_permanent_strings (new_interned_string=new_interned_string@entry=0x7fd72c8fa9e0 <accel_new_interned_string>)
    at /usr/src/debug/php-7.2.12-1.fc29.remi.x86_64/ext/opcache/ZendAccelerator.c:535
#3  0x00007fd72c8fc244 in accel_use_shm_interned_strings () at /usr/src/debug/php-7.2.12-1.fc29.remi.x86_64/ext/opcache/ZendAccelerator.c:649
#4  0x0000564ee8e5e8e6 in zend_interned_strings_switch_storage () at /usr/src/debug/php-7.2.12-1.fc29.remi.x86_64/Zend/zend_string.c:221
#5  0x0000564ee8dce255 in php_module_startup (sf=<optimized out>, additional_modules=<optimized out>, num_additional_modules=<optimized out>)
    at /usr/src/debug/php-7.2.12-1.fc29.remi.x86_64/main/main.c:2410
#6  0x0000564ee8ee4979 in php_cgi_startup (sapi_module=<optimized out>) at /usr/src/debug/php-7.2.12-1.fc29.remi.x86_64/sapi/fpm/fpm/fpm_main.c:838
#7  0x0000564ee8c8ce11 in main (argc=2, argv=0x7ffc9cfc84e8) at /usr/src/debug/php-7.2.12-1.fc29.remi.x86_64/sapi/fpm/fpm/fpm_main.c:1833
remicollet commented 5 years ago

notice php-cli doesn't seems to be affected

silkcutKs commented 5 years ago

this bug already fix at github master branch, but don`t upload to pecl。 after i will do that.

remicollet commented 5 years ago

@silkcutKs same segfault (and backtrace with master, up to 919dfe7d9d7bd8ac6d6bb64e048ae93a868e4e23)

vagrant-tiger commented 5 years ago

@silkcutKs same segfault error with php-7.2.5 on master branch