MongoDB php driver causing apache on XAMPP OS X to fail

让人想犯罪 __ 提交于 2019-12-04 01:22:59

From: https://github.com/mongodb/mongo-php-driver/issues/247

The PHP process loads mongodb.so and libmongoc's _mongoc_do_init() function is executed, which calls sasl_client_init() when compiled with SASL. I found some references to crashes in earlier versions of Cyrus SASL on OS X if the client is initialized and destroyed multiple times in the same process; however, I'd expect the logic around _mongoc_do_init() ensures that it only executes once per process. I'm also not sure of the version of SASL you have installed (beyond the library having "2.2" in its filename), so I'm not sure if that is a red herring. I will need to follow up with the libmongoc devs to confirm.

In the meantime, could you provide a log of your pecl install mongodb? There are some lines of interest there related to how SASL is configured (sadly, not the exact version number).

Also, if you manually build the driver, you should be able to use the --with-mongodb-sasl=no argument to configure to disable SASL support, which may work around the issue until we can diagnose it further. The manual build steps from a shell would be:

$ cd /path/to/mongo-php-driver
$ phpize
$ ./configure --with-mongodb-sasl=no
$ make clean && make all && make install

This would also requiring initializing git submodules if you are cloning the repository. Otherwise, you should be able to extract the PECL tgz file and use those sources.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!