I've just installed PHP 5.5 and I am no longer able to use MongoClient and I'm getting frustrated trying to figure out why.
This doesn't work:
$m = new MongoClient("mongodb://workplz.com");
My nginx error log shows:
2013/07/05 10:40:16 [error] 4163#0: *698 FastCGI sent in stderr: "PHP message: PHP Fatal error: Class 'MongoClient' not found in /blah/test.php on line 2" while reading response header from upstream, client: 123.123.123.123, server: blah, request: "GET /test.php HTTP/1.1", upstream: "fastcgi://unix:/var/lib/php5-fpm/freecookies.sock:", host: "blah"
I do have extension=mongo.so in my php.ini.
When I do phpinfo() it shows under Mongo Version 1.4.1
Extra info:
- PHP Version 5.5.0-1ubuntu2~precise1
- nginx/1.4.1
Edit
When I try to execute it from php-cli I get the same thing:
PHP Fatal error: Class 'MongoClient' not found in /blah/test.php on line 2
PHP Fatal error: Class 'MongoClient' not found in /blah/test.php on line 2