http://www.bictor.com/2015/02/15/instal ... ntu-14-04/
First, to get this thing going, we’ll need to resolve some dependencies. To do that, run this command from the terminal:
$ sudo apt-get install php-pear php5-dev
Next, you should easily be able to install the driver with the following command:
$ sudo pecl install mongo
What makes Ubuntu 14.04 a little different from other systems in how PHP extensions get loading when Apache/PHP starts. To make sure this extension gets loaded, we’ll need to add a .ini file to “/etc/php5/conf.d”. To do that, run the following command:
$ sudo touch /etc/php5/conf.d/mongo.ini
After creating the file, add this line of content:
extension=mongo.so
After you’ve saved your new .ini file, restart Apache and verify that the extension is loading with phpinfo().
Installing MongoDB for PHP in Ubuntu 14.04
Re: Installing MongoDB for PHP in Ubuntu 14.04
http://php.net/manual/en/mongodb.insta ... .pecl.php
https://github.com/mongodb/mongo-php-d ... ssues/138
https://github.com/mongodb/mongo-php-d ... ssues/138
代碼: 選擇全部
sudo apt-get install -y autoconf g++ make openssl libssl-dev libcurl4-openssl-dev
sudo apt-get install -y libcurl4-openssl-dev pkg-config
sudo apt-get install -y libsasl2-dev
sudo apt-get install libpcre3-dev
sudo pecl install mongodb
代碼: 選擇全部
extension=mongodb.so
ln -s ../../mods-available/mongo.ini 30-mongodb.ini