How to fix MongoNetworkError : connect ECONNREFUSED in MongoSH Ubuntu | Fix mongodb shell error Troubleshooting MongoDB Connection Issues: Fixing ECONNREFUSED 127.0.0.1:27027 Error In this video, I will explain how to solve the mongodb error connect ECONNREFUSED 127.0.0.1:27017 in Mongodb shell. So, the error occurs because the mongod service is not running after you started your pc/laptop. So, you need to start mongod service in your pc/laptop once again. So, open your terminal and type the following command: sudo service mongod start Now that the error will be fixed, and you can continue using mongodb compass. #Mongodb #mongodbubuntu #mongodbshell #mongosh