Install MongoDb in Windows and mongodb in windows
Installing MongoDb in windows is quite comfortable. The specific steps are as follows:
1; MongoDb official website, https://www.mongodb.org, according to the corresponding operating system download the corresponding version.
2. decompress the package to the directory you want to install, such as d: \ mongodb.
3: create a data/db directory, that is, the data storage directory.
D: \ mongodb \ data \ db
D: \ mongodb \ data \ log \ MongoDB. log
4: Configure environment variables so that you do not need to input them to d: \ mongodb \ bin every time.
Configuration
5: add the mongo background service to the service item. The command is as follows:
Mongo-serviceName "MongoDB"
Make sure that the current mongo background Exits normally. If you exit illegally, a mongo. lock file is generated under the db directory and deleted.
After generation:
6. Test the connection.
Run the mongo command,
The test is successful.
So far, mongodb is successfully installed in windows.
Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.