MANGODB installation Process

Source: Internet
Author: User
Tags robomongo mongodb gui

1. RDBMS vs NoSQL

Rdbms
-Highly organized structured data
-Structured Query Language (SQL) (SQL)
-Data and relationships are stored in separate tables.
-Data manipulation language, data definition language
-Strict consistency
-Basic services

Nosql
-represents more than just SQL
-No declarative query language
-No pre-defined pattern
-key-value pair storage, column storage, document storage, graphics database
-final consistency, not ACID properties
-Unstructured and unpredictable data
-Cap theorem
-High performance, high availability and scalability



2. Mangodb contrast
3. MongoDB installation Process
cd/usr/local/data/
wget https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu1404-3.2.4.tgz
-mongodb-linux-x86_64-ubuntu1404-3.2.4.tgz
Build Folder MongoDB DATA:
sudo mkdir-p /data/db/mongodb
MongoDB LOG:
sudo mkdir-p /data/log/mongodb

The first method of booting:
MONGO Server Startup:Sudo/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/bin/mongod--dbpath/data/db/mongodb/--logpath/data/ Log/mongodb/mongodb.log--logappend &

MONGO Server Close:Sudo/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/bin/mongod--dbpath/data/db/mongodb/--logpath/data/ Log/mongodb/mongodb.log--logappend--shutdown
The second method of booting:
Increase mongod.confNote: Conforms to Yalm notation, 4 spaces Non-tab
SystemLog:destination:file path:/data/log/mongodb/mongodb.log logAppend:truestorage:dbPath:/data/db/mong ODB journal:enabled:trueprocessmanagement:fork:truenet:bindip:127.0.0.1 port:27017
MONGO Server Startup:
Sudosh/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/bin/mongod--config/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/mongod.conf
MONGO Server Close:
Sudosh/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/bin/mongod--config/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/mongod.conf--shutdown
MONGO client Startup:sudo sh/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/Bin/mongo
4.terminology corresponding to the RDBMS and MongoDB:
Reference: Http://www.runoob.com/mongodb




5.mongoDB Add user when security is not turned on
Use admin
Db.createuser ({User: "Malianghang", pwd: "malianghang123", roles: [{role: "Useradminanydatabase", DB: "admin " } ]  })
6. mongodb.conf on (red part)
SystemLog:destination:file path:/data/log/mongodb/mongodb.log logAppend:truestorage:dbPath:/data/db/mong ODB journal:enabled:trueprocessmanagement:fork:truenet:bindip:127.0.0.1 port:27017security:a Uthorization:enabled                  
Turn off Mongod first, then start up: sudo sh/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/bin/mongod--config/usr/local/data/ mongodb-linux-x86_64-ubuntu1404-3.2.4/mongod.conf off: sudo sh/usr/local/data/mongodb-linux-x86_64- Ubuntu1404-3.2.4/bin/mongod--config/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/mongod.conf--shutdown

7. Start MONGO client
Sh/usr/local/data/mongodb-linux-x86_64-ubuntu1404-3.2.4/bin/mongo--host 127.0.0.1--port 27017-u "Malianghang"-P " Malianghang123 "--authenticationdatabase" admin "

Switch to the database you want use Mlh_dev
Create user in Mlh_dev: Db.createuser ({User: "Mlhtest", pwd: "malianghang123", Roles: ["ReadWrite", "DbAdmin"]})
8. MongoDB GUI recommends using Robomongo
Https://robomongo.org/download









From for notes (Wiz)

MANGODB installation Process

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.