我按照以下说明进行操作:
http://tecadmin.net/install-mongodb-on-ubuntu/
$ echo "deb http://repo.mongodb.org/apt/debian "$(lsb_release -sc)"/mongodb-org/3.2 main" | sudo tee /etc/apt/sources.list.d/mongodb.list
$ sudo apt-get update
$ sudo apt-get install mongodb-org
$ apt-get install mongodb-org=3.2.0 mongodb-org-server=3.2.0 mongodb-org-shell=3.2.0 mongodb-org-mongos=3.2.0 mongodb-org-tools=3.2.0
但我收到以下错误:
W: Failed to fetch http://repo.mongodb.org/apt/ubuntu/dists/wily/mongodb-org/3.2/multiverse/binary-amd64/Packages 404 Not Found
W: Failed to fetch http://repo.mongodb.org/apt/ubuntu/dists/wily/mongodb-org/3.2/multiverse/binary-i386/Packages 404 Not Found
W: Failed to fetch http://ppa.launchpad.net/tualatrix/ppa/ubuntu/dists/wily/main/binary-amd64/Packages 404 Not Found
W: Failed to fetch http://ppa.launchpad.net/tualatrix/ppa/ubuntu/dists/wily/main/binary-i386/Packages 404 Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.
可能是什么原因?以及如何安装成功?
截至今天,2016 年 2 月 7 日,根据MongoDB 文档:
您应该按照从 tarball 安装 MongoDB的说明进行操作。
简单来说:
即使你手动下载了14.04 的包,这里也确认
.deb
了 15.10 的问题。无论哪种方式,在手动安装后,您都需要配置 MongoDB 并将其作为进程运行或使用例如守护进程: