-
Notifications
You must be signed in to change notification settings - Fork 209
Description
Description
php -m
crashes, if curl
and mongodb
shared extensions loaded together (both compiled with system openssl support):
# rpm -qf /etc/php71/conf.d/curl.ini /etc/php71/conf.d/mongodb.ini
php71-curl-7.1.9-1.x86_64
php71-pecl-mongodb-1.2.11-1.x86_64
[root at blodnatt ~]# rpm -q curl
curl-7.55.1-1.x86_64
some openssl global lock again?
Source: http://lists.pld-linux.org/mailman/pipermail/pld-devel-en/2017-October/025436.html
See the full thread for discussion: http://lists.pld-linux.org/mailman/pipermail/pld-devel-en/2017-October/thread.html
The reproducer has been baked into docker container: https://gitlab.com/glensc/php71-mongodb-crash
$ ➔ docker run --rm registry.gitlab.com/glensc/php71-mongodb-crash:20171028_1 php71 -i | grep -E 'mongodb|libmongoc|libbson'
/etc/php71/conf.d/mongodb.ini,
mongodb
libbson headers version => 1.8.0
libbson library version => 1.8.0
libmongoc headers version => 1.8.1
libmongoc library version => 1.8.1
libmongoc SSL => enabled
libmongoc SSL library => OpenSSL
libmongoc crypto => enabled
libmongoc crypto library => libcrypto
libmongoc crypto system profile => enabled
libmongoc SASL => enabled
mongodb.debug => no value => no value
While the reproducer has been made for older versions, I just re-tested today with recent versions (libbson 1.9.3, libmongoc 1.9.3, openssl-1.0.2m-1.x86_64, php71-pecl-mongodb-1.4.2-0.1.x86_64) and the problem hasn't magically gone away :(
Currently the workaround exists, load mongodb ext after openssl ext:
➔ LC_ALL=C ls -1 /etc/php71/conf.d/*ssl*.ini /etc/php71/conf.d/*mongo*.ini
/etc/php71/conf.d/z-1-openssl.ini
/etc/php71/conf.d/z-2-mongodb.ini
Source: http://lists.pld-linux.org/mailman/pipermail/pld-devel-en/2017-October/025438.html
Which means the problem is somewhere in openssl cleanup routines.