mongod: error while loading shared libraries: libssl.so.10 libcrypto.so.10

前端 未结 5 1877
臣服心动
臣服心动 2021-02-09 04:02

Problem

I downloaded the mongodb 3.0.7 tar files. Then I added the bin directory to my path:

export PATH=

        
5条回答
  •  無奈伤痛
    2021-02-09 04:27

    sudo apt-get purge mongodb-org*
    

    Just start over from here.

    If you don't want 3.2, do not

    sudo apt-get install -y mongodb-org
    

    Specify the version for all the individual components in the next step.

    OR you can copy the correct version link from mongodb.

    You will need to

    cd /Downloads 
    wget wget https://fastdl.mongodb.org/linux/mongodb-correct-version.tgz
    tar -zxvf mongodb-correct-version.tgz 
    

    You should see all the executables. Make sure /usr/local/bin is in your PATH

    echo $PATH
    

    Create a symbolic link for the mongod server and check the version.

    sudo ln -s ~/Downloads/mongodb-correct-version/bin/mongod /usr/local/sbin/bin/mongod
    mongod --version
    

    Now create a symbolic link for the shell and check the version.

    sudo ln -s ~/Downloads/mongodb-correct-version/bin/mongo /usr/local/bin/mongo
    mongo --version
    

    Create a directory path for the server.

    mkdir ~/data
    mkdir ~/data/db 
    

    Start the server and let it run from a separate terminal than the shell.

    mongod --dbpath ~/data/db/
    

    It should be listening on port 27017. In a new terminal, start mongo.

    mongo
    

提交回复
热议问题