According to the error message you don’t have a running MongoDB instance or it’s port is changed. Please check in the task manager whether you have a running task mongod.
In case not, here is how you start it:
Open the command prompt and navigate to your Mongo server installation directory (by default it is C:Program FilesMongoDBServer<Version>bin) like this:
cd C:Program FilesMongoDBServer<Version>bin
Then enter the following:
mongod
If you have installed Mongo server it should run it at the default port. In case you have a running mongod end that task and start it again with my instructions.
Update
In case you already stored data on mongod or want to change default port:
mongod --dbpath <pathtodb> --port <number>
On Windows data resides by default on C:datadb.
Update 2
According to your comment you don’t have installed Mongo Server. Here is the download link:
download mongodb compass exe then download mongodb community msi seperately,install both when installing mongo community make sure you un-check install mongo compass
2
Answers
According to the error message you don’t have a running MongoDB instance or it’s port is changed. Please check in the task manager whether you have a running task
mongod
.In case not, here is how you start it:
Open the command prompt and navigate to your Mongo server installation directory (by default it is C:Program FilesMongoDBServer<Version>bin) like this:
Then enter the following:
If you have installed Mongo server it should run it at the default port. In case you have a running
mongod
end that task and start it again with my instructions.Update
In case you already stored data on
mongod
or want to change default port:On Windows data resides by default on
C:datadb
.Update 2
According to your comment you don’t have installed Mongo Server. Here is the download link:
https://www.mongodb.com/try/download/community
download mongodb compass exe then download mongodb community msi seperately,install both when installing mongo community make sure you un-check install mongo compass