MongoDB (a): The download and installation of MongoDB

Source: Internet
Author: User
Tags mongodb client

The MongoDB here is in the Windows environment

Windows installation under:

1.:http://www.mongodb.org/downloads

Recommended download stable version (stable version)

2. Installation

(1): Unzip to C:\mongodb (the path itself can be specified)

(2): Create a storage location for the database files, such as C:\mongodb\data. Note: You must create a storage folder for the database files before you start the MongoDB service, otherwise the command will not be created automatically and cannot be started successfully

(3): Start MongoDB service: Open cmd command line, C:\mongodb\bin>mongod--dbpath=c:\mongodb\data, as follows:

The above indicates that the MongoDB service started successfully. The default port is the 27017,web port is 28017.

You can modify the database port by adding the parameter--port: C:\mongodb\bin>mongod--port 27019--dbpath=c:\mongodb\data

(4): Start the MongoDB client. Open a CMD command-line window again (Note: The window opened above cannot be closed or the service will be closed). Input: C:\mongodb\bin>mongo, or

The user double-clicks the mongo.exe so that it enters the client. (You can also write this at startup: MONGO Ip: Port number such as: MONGO 127.0.0.1:27017). Examples are as follows:

In this case, MongoDB can be used, under test, for example, to view the database:

MongoDB (a): The download and installation of MongoDB

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.