php mongdb driver 1.17
Installation
To build and install the driver:
$ pecl install mongodb
$ echo "extension=mongodb.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`
Install for 64-bit Linux
Download the binary files for the desired release of MongoDB.
Download the binaries from https://www.mongodb.org/downloads.
For example, to download the latest release through the shell, issue the following:
curl -O https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-3.2.6.tgz
Extract the files from the downloaded archive.
For example, from a system shell, you can extract through the tar command:
tar -zxvf mongodb-linux-x86_64-3.2.6.tgz
Copy the extracted archive to the target directory.
Copy the extracted folder to the location from which MongoDB will run.
mkdir -p mongodb
cp -R -n mongodb-linux-x86_64-3.2.6/ mongodb
Ensure the location of the binaries is in the PATH variable.
The MongoDB binaries are in the bin/ directory of the archive. To ensure that the binaries are in yourPATH, you can modify your PATH.
For example, you can add the following line to your shell’s rc file (e.g. ~/.bashrc):
export PATH=<mongodb-install-directory>/bin:$PATH
Replace <mongodb-install-directory> with the path to the extracted MongoDB archive.
Run MongoDB Community Edition
Create the data directory.
Before you start MongoDB for the first time, create the directory to which the mongod process will write data. By default, the mongod process uses the /data/db directory. If you create a directory other than this one, you must specify that directory in the dbpath option when starting the mongodprocess later in this procedure.
The following example command creates the default /data/db directory:
mkdir -p /data/db
Run MongoDB.
To run MongoDB, run the mongod process at the system prompt. If necessary, specify the path of themongod or the data directory. See the following examples.
Run without specifying paths
If your system PATH variable includes the location of the mongod binary and if you use the default data directory (i.e., /data/db), simply enter mongod at the system prompt:
mongod
Specify the path of the mongod
If your PATH does not include the location of the mongod binary, enter the full path to the mongodbinary at the system prompt:
<path to binary>/mongod
Specify the path of the data directory¶
If you do not use the default data directory (i.e., /data/db), specify the path to the data directory using the --dbpath option:
mongod --dbpath <path to data directory>
php mongdb driver 1.17的更多相关文章
- Practical Node.js (2018版) 第7章:Boosting Node.js and Mongoose
参考:博客 https://www.cnblogs.com/chentianwei/p/10268346.html 参考: mongoose官网(https://mongoosejs.com/docs ...
- DB2 syntax error
Error infomation: An unexpected token "JOIN" was found following "". Expected t ...
- selenium的一些使用方法
新建实例driver = webdriver.Chrome()1.通过标签属性Id查找元素方法:find_element_by_id(element_id)实例:driver.find_element ...
- selenium2 webdriver 常用的python 函数
新建实例driver = webdriver.Chrome() 1.通过标签属性Id查找元素 方法:find_element_by_id(element_id) 实例:driver.find_elem ...
- Python Selenium 常用方法总结(不断补充)
还有此篇内容也丰富Selenium常见元素定位方法和操作的学习介绍 selenium Python 总结一些工作中可能会经常使用到的API. 1.获取当前页面的Url 方法:current_url 实 ...
- Spark记录-Spark-Shell客户端操作读取Hive数据
1.拷贝hive-site.xml到spark/conf下,拷贝mysql-connector-java-xxx-bin.jar到hive/lib下 2.开启hive元数据服务:hive --ser ...
- Python Selenium 常用方法总结
selenium Python 总结一些工作中可能会经常使用到的API. 1.获取当前页面的Url 方法:current_url 实例:driver.current_url 2.获取元素坐标 ...
- python3+selenium3.13的简单操作
1.浏览器 1.1 浏览器窗口大小位置 driver.set_window_size(self, width, height, windowHandle) 将某个窗口设置为固定大小 driver.se ...
- selenium2.0关于python的常用函数
转: 新建实例driver = webdriver.Chrome() 1.获取当前页面的Url函数 方法:current_url 实例: driver.current_url 2.获取元素坐标 方法: ...
随机推荐
- css美化Div边框的样式实例*(转载)
css美化Div边框的样式实例 很多时候如果不是用了很多样式,很难把边框修饰得好看,看了一篇博文,觉得真的挺漂亮,也挺好看. 转载的博文地址 将这段美化的css代码 border:1px soli ...
- ZooKeeper Distributed lock
https://segmentfault.com/a/1190000016351095 http://www.dengshenyu.com/java/%E5%88%86%E5%B8%83%E5%BC% ...
- Java的多态-进阶
Java的多态——进阶 总括 Parent p = new Child(); 反之,Child() c = new Parent(); 会报错. 当使用多态方式调用方法时,首先检查父类中是否有该方法. ...
- LTE引理——解决数论竞赛题的利器
LTE (Lifting The Exponent Lemma)引理是一个解指数型不定方程的强力工具.它在Olympiad folklore非常知名,虽然它的起源已经无从查找了.它和Hensel’s ...
- 题解【POJ3252】Round Numbers
Description The cows, as you know, have no fingers or thumbs and thus are unable to play Scissors, P ...
- 【 js 上传文件】
上传文件 <!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml"> <head> ...
- 【Python】 平方根
平方根,又叫二次方根,表示为[√ ̄],如:数学语言为:√ ̄16=4.语言描述为:根号下16=4. 以下实例为通过用户输入一个数字,并计算这个数字的平方根: num = float(input('请输入 ...
- 使用spring中遇到"java.lang.NoClassDefFoundError: org/aopalliance/intercept/MethodInterceptor"问题
项目中缺少aopalliance的jar包,下载一个相应的jar加入项目中就可以解决问题. 下载链接:http://www.java2s.com/Code/Jar/a/Downloadaopallia ...
- sqlserver 优化语句小助手
我们在开发的过程中,经常会遇到一些性能差的问题,此刻我的解决思路一般是,首先在浏览器端监控查看是哪一个调用的方法占用的时间比较长如下图,然后会根据方法定位到具体的方法,然后可能是自己写的遗传sql语句 ...
- [蓝桥杯][基础训练]Huffuman树
Description Huffman树在编码中有着广泛的应用.在这里,我们只关心Huffman树的构造过程. , p1, …, pn-1},用这列数构造Huffman树的过程如下:1. 找到{pi} ...