Getting started with MongoDb (1) Installing Mongodb on windows 7

Source: Internet
Author: User

Mongodb

The following are running in service mode:

D: \ mongodb \ bin> mongod-port 2011 -- logpath D: \ db \ log.txt -- logappend -- dbpath D: \ db \ mongodb -- directoryperdb -- serviceName MDB -- install

1) start the Service net start MDB

2) There are two ways to connect to the database

1. cmd.exe -- host 127.0.0.1-port 2000

2. cmd.exe FIG: 2000/test

3) show all database commands

4) the Db command displays the currently used database

5) show collections for all collections of all current databases

6) change the name of the database use database. If no data exists, the database will not be saved as long as no data is inserted. Therefore, the delayed creation clustering technology should be used for 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.