MongoDB installed and set as Windows service to turn it on

Source: Internet
Author: User

Official download of the compressed ZIP file for Windows platform in MongoDB, address: https://www.mongodb.org/dr/fastdl.mongodb.org/win32/mongodb-win32-x86_ 64-3.2.1.zip/download

1, unzip the zip file, my path is: F:\StudyTools\MongoDB

2. Set the data file path:

Create a new log and Data folder inside F:\StudyTools\MongoDB

Create a new Mongodb.log file inside F:\StudyTools\MongoDB\log

3. Open MongoDB Service

Open cmd, enter the F:\StudyTools\MongoDB\bin directory, enter the command "Mongod--dbpath f:studytools\mongodb\data" To open the MongoDB service.

It is troublesome to enter the above command to open each time you need to use it. So it is convenient to install the MONGO database as a Windows service and set the boot up (of course set to manual).

4. Install the MONGO database as a Windows service

Run cmd as an administrator, enter the F:\StudyTools\MongoDB\bin directory, and enter the following command:

1) mongod--dbpath F:\StudyTools\MongoDB\data--logpath F:\StudyTools\MongoDB\log\mongodb.log--install

2) net start MongoDB

To this MongoDB service finished installing.

Enter the service to see MongoDB services such as:

MongoDB installed and set as Windows service to turn it on

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.