Mongodb error showing 'MongoNetworkError: connect ECONNREFUSED 127.0.0.1:27017' in Ubuntu 20.04.3 (Focal)

I am trying to install MongoDB in my Ubuntu 20.04.03 (focal) through the instructions held in MongoDB Official Site

After Successful install, I started the MongoDB service via the command sudo systemctl start mongod

Later, I entered the command sudo systemctl status mongod

The Result was

 mongod.service - MongoDB Database Server Loaded: loaded (/lib/systemd/system/mongod.service; enabled; vendor preset> Active: failed (Result: signal) since Thu 2021-09-16 18:10:08 IST; 19min a> Docs: Process: 14939 ExecStart=/usr/bin/mongod --config /etc/mongod.conf (code=ki> Main PID: 14939 (code=killed, signal=ILL)
Sep 16 18:10:07 user-desktop systemd[1]: Started MongoDB Database Server.
Sep 16 18:10:08 user-desktop systemd[1]: mongod.service: Main process exited, c>
Sep 16 18:10:08 user-desktop systemd[1]: mongod.service: Failed with result 'si>

For a try, I entered command mongosh

The Result was

`Current Mongosh Log ID: 6143405ddba508a78c45b90c
Connecting to: mongodb://127.0.0.1:27017/?directConnection=true&serverSelectionTimeoutMS=2000
MongoNetworkError: connect ECONNREFUSED 127.0.0.1:27017`

When I tried mongodit shows Illegal Instruction

Guys please Tell what to do

4 Reset to default

Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like