ubuntu一键安装mongodb最新版
2017-03-09 23:56
375 查看
官网安装步骤镇楼
配置文件在哪里
启动
关闭
源码安装
秘钥 sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 0C49F3730359A14518585931BC711F9BA15703C6 14.04的源 echo "deb [ arch=amd64 ] http://repo.mongodb.org/apt/ubuntu trusty/mongodb-org/3.4 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.4.list 16.04的源 echo "deb [ arch=amd64,arm64 ] http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.4 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.4.list 升级apt-get sudo apt-get update 安装喽 apt-get install -y mongodb-org --force-yes
配置文件在哪里
Run MongoDB Community Edition¶ The MongoDB instance stores its data files in /var/lib/mongodb and its log files in /var/log/mongodb by default, and runs using the mongodb user account. You can specify alternate log and data file directories in /etc/mongod.conf. See systemLog.path and storage.dbPath for additional information. If you change the user that runs the MongoDB process, you must modify the access control rights to the /var/lib/mongodb and /var/log/mongodb directories to give this user access to these directories.
启动
sudo service mongod start
关闭
sudo service mongod stop
源码安装
wget https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu1404-3.4.2.tgz tar -zxvf mongodb-linux-x86_64-ubuntu1404-3.4.2.tgz cd mongodb cp -R -n mongodb-linux-x86_64-ubuntu1404-3.4.2/ mongodb cd mongodb-linux-x86_64-ubuntu1404-3.4.2/ mv * ../ rm -rf mongodb-linux-x86_64-ubuntu1404-3.4.2/ vim /etc/profile PATH="/letv/Downloads/mongodb/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/root/Downloads/WebStorm-163.9166.30/bin:/root/Downloads/pycharm-2016.3.2/bin:/root/Downloads/idea-IC-163.9166.29/bin" source /etc/profile mkdir -p /data/db mongod --dbpath /data/db &
相关文章推荐
- ubuntu上最新版本mongodb的安装
- ubuntu下一键安装最新版本的npm,安装markdown-pdf和phantomjs全过程
- [开发环境]PSP开发整合包(一键安装,无须配置包含目前最新的全库)
- Ubuntu 9.04安装最新版本wine1.1.16
- Ubuntu 10.04 编译安装最新版本Linux-2.6.34内核
- 基于Ubuntu 10.10的最新版fcitx小企鹅输入法的安装配置与美化
- ubuntu 10.04 安装 fcitx 最新版
- 在ubuntu 6.10中编译安装最新版本的gaim(带qq插件)
- Ubuntu 最新版 10.04 下安装中文智能输入法
- ubuntu 10.04 编译安装最新版本linux-2.6.34内核
- Ubuntu下进行最新版QT安装
- Ubuntu10.04中手动安装最新jdk的方法 转自:http://www.pczpg.com/a/2010/0907/19192.html
- ubuntu 安装最新版 Mplayer 全解[菜鸟篇]
- Ubuntu 8.04 安装 友善之臂 最新qtopia2.2.0代码
- Ubuntu 9.04 最新版下载(附:U盘安装方法和配置方法)
- Ubuntu 9.10下Nvidia官方最新190.42显卡驱动安装
- 如何在Ubuntu上安装Mercurial的最新版本
- ubuntu-获取最新fcitx源码及安装
- 在Ubuntu下安装或者更新最新版的Banshee
- Ubuntu 10.04 编译安装最新版本Linux-2.6.34内核