Mongodb 操作

Start MongoDB

The MongoDB instance stores its data files in the /var/lib/mongo and its log files in /var/log/mongo, and run using themongod user account. If you change the user that runs the MongoDB process, you must modify the access control rights to the/var/lib/mongo and /var/log/mongo directories.

Start the mongod process by issuing the following command (as root or with sudo):

service mongod start

You can verify that the mongod process has started successfully by checking the contents of the log file at/var/log/mongo/mongod.log.

You may optionally ensure that MongoDB will start following a system reboot by issuing the following command (with root privileges:)

chkconfig mongod on

Stop MongoDB

Stop the mongod process by issuing the following command (as root or with sudo):

service mongod stop

Restart MongoDB

You can restart the mongod process by issuing the following command (as root or with sudo):

service mongod restart

 url:http://docs.mongodb.org/manual/tutorial/install-mongodb-on-red-hat-centos-or-fedora-linux/

最新文章

  1. 总结:视频播放的四种实现方案(Native)
  2. 【jq】c#零基础学习之路(5)自己编写简单的Mylist<T>
  3. js:方法3. 对象
  4. HDU 4471 矩阵快速幂 Homework
  5. xcode7 __weak 导致报错 is unavailable
  6. Auto push git tag
  7. @ExceptionHandler
  8. C#获取相对路径的方法
  9. php 快速fork出指定个子进程
  10. magento寄存器的使用
  11. 201521123063 《Java程序设计》 第12周学习总结
  12. Python中装饰器的用法
  13. MySQL 笔记整理(9) --普通索引和唯一索引,应该怎么选择?
  14. 详述 hosts 文件的作用及修改 hosts 文件的方法
  15. 突破内网限制上网(ssh+polipo)
  16. SQL Server -- stuff 函数
  17. perfmon——使用windows系统自带的性能监视器监控进程信息
  18. 代码调试--自定义一个简单的debug函数
  19. 使用 pkg 打包分发 nodejs 应用
  20. linux修改文件所属用户和用户组

热门文章

  1. 20165324 Java实验三 敏捷开发与XP实验
  2. Android Study Notes
  3. 中高级PHP开发者应该掌握哪些技术?
  4. 【android】activity的4种启动模式简介
  5. C++通过HTTP请求Get或Post方式请求Json数据(转)
  6. 《学习OpenCV3》目录和全书划分
  7. 20145307第七周JAVA学习报告
  8. Hive相关随笔
  9. 深度学习:Keras入门(二)之卷积神经网络(CNN)【转】
  10. # fabirc 配置多组服务器 密码与密钥一起使用 key_filename的设置