php 添加mongodb扩展_PHP_编程开发_程序员俱乐部

中国优秀的程序员网站程序员频道CXYCLUB技术地图
热搜:
更多>>
 
您所在的位置: 程序员俱乐部 > 编程开发 > PHP > php 添加mongodb扩展

php 添加mongodb扩展

 2014/4/30 23:45:01  zlr  程序员俱乐部  我要评论(0)
  • 摘要:PHPMongoDB扩展安装[root@a5139~]#wgethttp://pecl.php.net/get/mongo-1.3.4.tgz[root@a5139~]#tarzxvfmongo-1.3.4.tgz[root@a5139~]#cdmongo-1.3.4[root@a5139mongo-1.3.4]#/usr/local/php/bin/phpizeConfiguringfor:PHPApiVersion:20041225ZendModuleApiNo
  • 标签:PHP MongoDB
PHP MongoDB 扩展安装
[root@a5139 ~]# wget http://pecl.php.net/get/mongo-1.3.4.tgz
[root@a5139 ~]# tar zxvf mongo-1.3.4.tgz
[root@a5139 ~]# cd mongo-1.3.4
[root@a5139 mongo-1.3.4]# /usr/local/php/bin/phpize
Configuring for:
PHP Api Version: 20041225
Zend Module Api No: 20060613
Zend Extension Api No: 220060519
[root@a5139 mongo-1.3.4]# ./configure –with-php-config=/usr/local/php/bin/php-config
[root@a5139 mongo-1.3.4]# make && make install
Installing shared extensions: /usr/local/php/lib/php/extensions/no-debug-non-zts-20060613/

[root@a5139 mongo-1.3.4]# ls /usr/local/php/lib/php/extensions/no-debug-non-zts-20060613/
memcache.so mongo.so pdo_mysql.so
[root@a5139 mongo-1.3.4]# vi /usr/local/php/etc/php.ini
#加入

extension_dir = “/usr/local/php/lib/php/extensions/no-debug-non-zts-20060613/”
#extension = “memcache.so”
#extension = “pdo_mysql.so”
extension = “mongo.so”

[root@a5139 mongo-1.3.4]# /etc/init.d/php-fpm restart
Shutting down php_fpm . done
Starting php_fpm done
#探针查看已经支持mongodb鸟!


http://www.iamle.com/archives/1290.html

http://stephenzhao.blog.51cto.com/2515860/668502
上一篇: ThinkPHP3.2.2行为扩展 下一篇: 没有下一篇了!
发表评论
用户名: 匿名