Connect to MongoDB

I am new to database and have encountered some issues while connecting to mongoDB, I have checked on StackOverflow but still have no clue. This is the installation documentation I followed.
( https://docs.mongodb.com/manual/tutorial/install-mongodb-on-os-x/ )

OS: macOS Catalina version 10.15.7
mongoDB: MongoDB 4.4 Community Edition

I got an error status after running the mongoDB server, I’ve tried to install MongoDB 4.2 but the error remains, would be grateful if someone could help me out.

Thank you in advance!

can you please check logs under below directory

/usr/local/var/log/mongodb/

Hi @Djdj_Djdj !

Before you start a mongo session, what you need to do is starting the mongodb services.

Try this command:
brew services start mongodb-community

To stop the service you can use this command:
brew services stop mongodb-communit

Note: Your mongodb-community status is error. You should have started status in order to run the mongo session.

I have found and resolved the problem, thank you so much!

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.