Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Web Technology by (47.6k points)

I just want to try MongoDB Compass GUI for MongoDB, but when I try to connect using local host port: 27017 I get this error:

Could not connect to MongoDB on the provided host and port

I followed these instructions on YouTube.

2 Answers

0 votes
by (106k points)

You need to press windows key button and search Services and find MongoDB then start. Then try again. It will work.

0 votes
by (107k points)

You have to just follow the following steps while connecting MongoDB tool(MongoDB Compass)to MongoDB:

  1. Go to C drive and create a folder db in the path C:datadb, if you don't see the data folder in C drive, please create it first and then db folder

  2. Go the folder, where you had installed MongoDB, in my case, it was C:\Program Files\MongoDB\Server\4.2\bin

  3. Type the command C:Program FilesMongoDBServer4.2bin>mongod

This will set up the MongoDB on your system and now if you try connecting, you may not be getting the issue.

Related questions

0 votes
1 answer
0 votes
2 answers
0 votes
2 answers
0 votes
2 answers
asked Oct 17, 2019 in Web Technology by Sammy (47.6k points)

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...