Win7 under MongoDB installation configuration

Source: Internet
Author: User
Tags install mongodb mongodb mongodb compass

Before looking at Windows install MongoDB operation is very simple, today in your own notebook installed, a variety of small problems. Refer to the online great god posts, and then record the next simple process to remember later.

1.MongoDB official Web Download installation package

2. Run the installation package and select "Custom" to customize the installation path under Modify: D:\software\MongoDB, the middle install MongoDB compass must not be checked, the installation of the basic card master does not move, You can install and then download Compass on your own website and then continue to "next", install to the end.

  

  

3. Where to create the database file

Create Db:d:\software\mongodb\data\db

Because you need to create a storage folder for the database files before you start the MongoDB service, the command is not created automatically and does not start successfully.

4. Start MongoDB Service

1. Open cmd command line

2. Enter the D:\software\MongoDB\bin directory (note: Enter D: Enter D, then enter the CD D:\software\MongoDB\bin)

3. Enter the following command to start the MongoDB service: Mongod--dbpath D:\software\MongoDB\data\db

At this point, when the default startup, the service has started, the port default 27017. But online various said direct browser input http://localhost:27017 can be verified, but I also have been unable to find the page, verified that the service is started, it may be Win7 will have this problem appear, You can log in using a compass that was previously downloaded separately.

  

5. Configure the local Windows MongoDB service

This can be set to power-on self-boot, can be directly started off manually, can be started by command line net start MongoDB.

1. First create a new folder under the data file log (to hold the log file)

2. Create a new configuration file in MongoDB mongo.config

3. Open the Mongo.config with Notepad and enter:

Dbpath=d:\software\mongodb\data\db

Logpath=d:\software\mongodb\data\log\mongo.log

4. Open cmd as Administrator:

CMD jumps to the D:\software\MongoDB\bin directory first.

Input: Mongod--config D:\software\Mongodb\mongo.config--install--servicename "Mongodb"

That is, based on the Mongo.config profile installation service you just created, the name is MongoDB.

  

Win7 under MongoDB installation configuration

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.