gpt4 book ai didi

mongodb - 为什么我无法安装特定版本的 MongoDB?

转载 作者:可可西里 更新时间:2023-11-01 09:27:04 25 4
gpt4 key购买 nike

我想安装 mongoDB 2.6.6,我按照这个教程 (http://docs.mongodb.org/manual/tutorial/install-mongodb-on-ubuntu/)

daniela.morais@tusk:/var/lib$ sudo apt-get install -y mongodb-org=2.6.6 mongodb-org-server=2.6.6 mongodb-org-shell=2.6.6 mongodb-org-mongos=2.6.6 mongodb-org-tools=2.6.6
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Version '2.6.6' for 'mongodb-org' was not found
E: Version '2.6.6' for 'mongodb-org-server' was not found
E: Version '2.6.6' for 'mongodb-org-shell' was not found
E: Version '2.6.6' for 'mongodb-org-mongos' was not found
E: Version '2.6.6' for 'mongodb-org-tools' was not found

最佳答案

要安装 mongodb 2.6,您需要遵循本教程:http://docs.mongodb.org/v2.6/tutorial/install-mongodb-on-ubuntu

添加公钥后,

sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10

区分步骤是添加此源:

echo 'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' | sudo tee /etc/apt/sources.list.d/mongodb.list

然后你就可以安装2.6了

sudo apt-get update
sudo apt-get install -y mongodb-org

当我在 Ubuntu 上运行这个安装时,我得到了 2.6.8。您可以使用

检查
mongod --version

关于mongodb - 为什么我无法安装特定版本的 MongoDB?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29146936/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com