Install MongoDB Community Edition 3.2 on Ubuntu 12.04


  • Lv 1

    一、安裝 MongoDB

    1.Import the MongoDB public key

    //
    root@ubuntu:~# sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv EA312927
    Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --secret-keyring /tmp/tmp.mEWLPEWCQn --trustdb-name /etc/apt/trustdb.gpg --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyserver hkp://keyserver.ubuntu.com:80 --recv EA312927
    gpg: requesting key EA312927 from hkp server keyserver.ubuntu.com
    gpg: key EA312927: public key "MongoDB 3.2 Release Signing Key <packaging@mongodb.com>" imported
    gpg: Total number processed: 1
    gpg:               imported: 1  (RSA: 1)
    

    2.Create a list file for MongoDB

    root@ubuntu:~# echo "deb http://repo.mongodb.org/apt/ubuntu precise/mongodb-org/3.2 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.2.list
    deb http://repo.mongodb.org/apt/ubuntu precise/mongodb-org/3.2 multiverse
    

    3.Reload local package database

    root@ubuntu:~# sudo apt-get update
    Get:1 http://security.ubuntu.com precise-security Release.gpg [198 B]                     
    Get:2 http://security.ubuntu.com precise-security Release [55.5 kB]                              
    Get:3 http://security.ubuntu.com precise-security/main Sources [144 kB]                                                                                                                                                                    
    Get:4 http://security.ubuntu.com precise-security/restricted Sources [4,476 B]                                                                                                                                                             
    Get:5 http://security.ubuntu.com precise-security/universe Sources [53.0 kB]                                                                                                                                                               
    Get:6 http://security.ubuntu.com precise-security/multiverse Sources [3,033 B]               
    //skipped 
    

    本帖部分内容已隐藏,请登入并回覆,以查看隐藏内容!

登录后回复
 

与 萌阔论坛 的连接断开,我们正在尝试重连,请耐心等待