The difference between MongoDB and MySQL

Source: Internet
Author: User

One

1, based on distributed file storage

2, add more nodes under high load, can guarantee the performance of the server

3. Store data as a document

Second, Comparison

1. Stability

2, index, index in memory, can improve the performance of random read and write. If the index is not fully in memory, once the random read and write is high, it will be frequently disk exchange, MongoDB performance will drop sharply

3, occupy the space is very big, because it belongs to the typical space to change the time principle the type. Then it's a bit more disk space than the normal database, and so far it has not implemented the online compression function,

In MongoDB frequently in the data additions and deletions, if the record changes, such as the size of the data has changed, it is easy to produce some data fragments, the result of fragmentation,

One is that the index can have performance problems,

The other is in a certain amount of time after the occupied space will be inexplicably increased, so to regularly repair the database, periodically re-index, which will improve the stability and efficiency of MongoDB.

In the latest version, it has been implemented on-line compression, should be in the 2.0 version around, should be able to achieve online compression, can be performed in the background now repair database of some operations. If that's the case, it solves the current obsession

Our big problem.

4, MongoDB to the data between the transaction relationship support is relatively weak

5, operation and maintenance is not convenient

The advantages of MongoDB

1. It is suitable for the requirement model which is not clear to the database specific data format or the database data format changes frequently, and is very friendly to the developer.

2. With a distributed file system, it is easy to deploy to the server cluster.

MongoDB has a shard concept, is convenient for the server shard use. The insertion performance of each additional shard,mongodb will also grow in close multiples, and the disk capacity can be easily expanded.

3. With the support of the Map-reduce computing framework, it is also convenient for data statistics. Similar to GROUP by

MongoDB vs. mysql command the traditional relational database is usually composed of three hierarchical concepts of database, table, record,

MongoDB is made up of three levels of databases (database), Collections (collection), document objects (documents).

MongoDB is for tables in relational databases, but there is no concept of columns, rows, and relationships in the collection, which embodies the nature of pattern freedom.

Excerpt from: http://www.cnblogs.com/caihuafeng/p/5494336.html

The difference between MongoDB and MySQL

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.