Table of Contents
MongoDB 2.8存储引擎FAQ
存储引擎是什么东东?
MongoDB为什么要引入存储引擎API?
MongoDB2.8会支持什么样的存储引擎?
将来版本默认的存储引擎会是什么?
如何升级到新的存储引擎?
如果我已购买了MongoDB的服务,这个对WiredTiger存储引擎有效么?
WiredTiger存储引擎发现bug,应该找谁?
MongoDB对WiredTiger拥有什么样的授权?
我可以在复制集混用不同的存储引擎吗?
这个对MongoDB MMS有什么影响?
使用新的存储引擎需要修改已有程序吗?
什么时候应该用 WiredTiger?  MMAP v1?
WiredTiger压缩率有多少?
WiredTiger的并发能力比MMAP v1高多少?
WiredTiger支持数据模式检验,ACID事务,国际语言支持和快照。这些在MongoDB里面都会支持吗?
我还需要在一台机器上运行多个MongoDB实例来充分利用我的硬件资源么?
2.8 什么时候发布?
Home Database Mysql Tutorial MongoDB 2.8存储引擎FAQ

MongoDB 2.8存储引擎FAQ

Jun 07, 2016 pm 04:41 PM
faq m mongodb source storage engine

Source MongoDB 2.8存储引擎FAQ 2.8-rc0在光棍节的周二发布了,忙着血拼的童鞋们多半没有注意到哈。 2.8的最主要的新功能是支持两个存储引擎: MMAP 和 WiredTiger。其中WiredTiger 支持压缩和文档级锁, MMAP支持集合级锁。 其他更新请看http://docs.mongod

Source

MongoDB 2.8存储引擎FAQ

2.8-rc0在光棍节的周二发布了,忙着血拼的童鞋们多半没有注意到哈。 2.8的最主要的新功能是支持两个存储引擎: MMAP 和 WiredTiger。其中WiredTiger 支持压缩和文档级锁, MMAP支持集合级锁。 其他更新请看http://docs.mongodb.org/manual/release-notes/2.8/

以下是关于存储引擎的一些FAQ

存储引擎是什么东东?

存储引擎是数据库管理系统的一个重要组成部分。它的主要职责就是负责把数据存储到硬盘和把数据从硬盘检索出来。MySQL和Riak均支持多个不同的存储引擎。不同的存储引擎对不同的应用需求有特别的优化。如某个存储引擎可以是专为高并发写设计的,而另一个则是为高压缩率设计从而达到节省磁盘空间的目标。

MongoDB为什么要引入存储引擎API?

MongoDB 从最初版本一直到2.6都只支持一种基于内存映射技术的存储引擎,现在叫做MMAP v1。随着MongoDB的广泛普及,仅有一个存储引擎方案已经很难满足各种各样的场景需求,如压缩,高并发,文档级锁,内存数据库性能等等。引入API可以让MongoDB,技术合作伙伴,和MongoDB 用户根据性能,可用性,高效性,容量及扩展性等具体需求开发适合于这些场景的存储引擎,从而进一步增加MongoDB的适用性。

MongoDB2.8会支持什么样的存储引擎?

以下两个是2.8 支持的2个存储引擎

  • MMAP v1 – 目前的基于内存映射的存储引擎。MMAP v1在2.8支持collection level locking,并在2.8内继续作为MongoDB的默认存储引擎。
  • WiredTiger – 这是一个BerkerlyDB 架构师们开发的一个存储引擎。主要特点为高性能写入,支持压缩和文档级锁。

其他一些正在考虑支持的存储引擎(会在2.8之后的版本实现):

  • RocksDB – Facebook 开发的优化写操作的一个存储引擎
  • TokuFT – Tokutek开发。这个引擎也在 MySQL (TokuDB) 和TokuMX下使用
  • InMemoryExperiment – MongodDB 开发的内存数据库,尚在试验中
  • FusionIO – 跳过文件系统和OS直接访问FushionIO存储介质,提供高效读写

将来版本默认的存储引擎会是什么?

在2.8 MMAP v1 还仍会是默认的存储引擎。3.0以后WiredTiger很可能会成为默认存储引擎。

如何升级到新的存储引擎?

用户需要对既有的数据执行一个升级操作以使用新的WiredTiger存储引擎。详细的升级文档将随2.8一起发布。基本过程就是通过加一个新的采用新的存储引擎的复制集成员并让之完成initial sync,然后逐渐替换掉老的成员。2.8里对复制集的initial sync有不少性能改善,所以增加一个新成员会比之前速度会有较大提升。

如果我已购买了MongoDB的服务,这个对WiredTiger存储引擎有效么?

对的。没有影响。

WiredTiger存储引擎发现bug,应该找谁?

MongoDB

MongoDB对WiredTiger拥有什么样的授权?

MongoDB 从WiredTiger Data Engine 获得了对源代码的永久授权。

我可以在复制集混用不同的存储引擎吗?

可以的。用户可以在复制集里混用存储引擎。你需要注意一些额外事项,如Oplog的大小要根据各个存储引擎的特点而做不同的计划。另外,备份恢复可能会变得复杂一点因为备份数据可能是一个存储引擎的格式而在恢复的时候可能要求恢复到另一个存储引擎里去。

这个对MongoDB MMS有什么影响?

MMS 和即将发布的 OpsManager 会有以下功能增强:

  • 创建或修改MongoDB实例时候可以选择使用哪一种存储引擎
  • 创建或修改复制集的时候可以混用不同存储引擎
  • 从2.6升级到2.8,然后切换存储引擎

使用新的存储引擎需要修改已有程序吗?

WiredTiger 和目前的MMAP v1 存储引擎是100%兼容的。用户不需要对程序做任何的修改便可直接使用。有一些状态监控的命令会有一些调整,这些在2.8里会有具体的文档说明。此外,由于WiredTiger会对写性能有极大的提升,以及文档锁的实现,以前的微分片,分库分表及其他的为提高MMAPv1并发率而实现的变通方案将不再需要。我们强烈建议在选择一个存储引擎的时候要把性能测试作为一个必不可少的步骤包含在选型过程中。

什么时候应该用 WiredTiger?  MMAP v1?

一般来说,WiredTiger会对大部分应用场景提供更好的性能表现。在2.8中 MongoDB会支持复制集中存储引擎的混合部署,用户可以很容易地在两个存储引擎中切换。这样可以在测试过程中选择更加合适自己的方案。

WiredTiger压缩率有多少?

目前这个还没有最终确定。2.8 rc0里已经支持Snappy和Zlib压缩并默认开启Snappy压缩。

WiredTiger的并发能力比MMAP v1高多少?

这个取决于使用场景。我们会在2.8 发布时提供一些这方面的参考。

WiredTiger支持数据模式检验,ACID事务,国际语言支持和快照。这些在MongoDB里面都会支持吗?

不一定所有的都会支持。有一些功能如压缩会比较容易实现并已经在2.8 里实现(2.8 已经支持 zlib 和Snappy 压缩),而其他的一些功能则还没有完全和MongoDB整合起来。然而WiredTiger的这些既有功能将大大帮助MongoDB将来版本里面实现这些功能。

我还需要在一台机器上运行多个MongoDB实例来充分利用我的硬件资源么?

如果使用 MMAP v1, 微分片技术在适当的场景下还可以继续使用。对于WiredTiger用户不再需要微分片。因为文档级锁的引入,一个MongoDB实例就可以充分利用所有系统资源。

2.8 什么时候发布?

目前计划是2014年12月。

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Roblox: Bubble Gum Simulator Infinity - How To Get And Use Royal Keys
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
Nordhold: Fusion System, Explained
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
Mandragora: Whispers Of The Witch Tree - How To Unlock The Grappling Hook
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Hot Topics

Java Tutorial
1666
14
PHP Tutorial
1273
29
C# Tutorial
1253
24
Use Composer to solve the dilemma of recommendation systems: andres-montanez/recommendations-bundle Use Composer to solve the dilemma of recommendation systems: andres-montanez/recommendations-bundle Apr 18, 2025 am 11:48 AM

When developing an e-commerce website, I encountered a difficult problem: how to provide users with personalized product recommendations. Initially, I tried some simple recommendation algorithms, but the results were not ideal, and user satisfaction was also affected. In order to improve the accuracy and efficiency of the recommendation system, I decided to adopt a more professional solution. Finally, I installed andres-montanez/recommendations-bundle through Composer, which not only solved my problem, but also greatly improved the performance of the recommendation system. You can learn composer through the following address:

Navicat's method to view MongoDB database password Navicat's method to view MongoDB database password Apr 08, 2025 pm 09:39 PM

It is impossible to view MongoDB password directly through Navicat because it is stored as hash values. How to retrieve lost passwords: 1. Reset passwords; 2. Check configuration files (may contain hash values); 3. Check codes (may hardcode passwords).

How to choose a database for GitLab on CentOS How to choose a database for GitLab on CentOS Apr 14, 2025 pm 04:48 PM

GitLab Database Deployment Guide on CentOS System Selecting the right database is a key step in successfully deploying GitLab. GitLab is compatible with a variety of databases, including MySQL, PostgreSQL, and MongoDB. This article will explain in detail how to select and configure these databases. Database selection recommendation MySQL: a widely used relational database management system (RDBMS), with stable performance and suitable for most GitLab deployment scenarios. PostgreSQL: Powerful open source RDBMS, supports complex queries and advanced features, suitable for handling large data sets. MongoDB: Popular NoSQL database, good at handling sea

What is the CentOS MongoDB backup strategy? What is the CentOS MongoDB backup strategy? Apr 14, 2025 pm 04:51 PM

Detailed explanation of MongoDB efficient backup strategy under CentOS system This article will introduce in detail the various strategies for implementing MongoDB backup on CentOS system to ensure data security and business continuity. We will cover manual backups, timed backups, automated script backups, and backup methods in Docker container environments, and provide best practices for backup file management. Manual backup: Use the mongodump command to perform manual full backup, for example: mongodump-hlocalhost:27017-u username-p password-d database name-o/backup directory This command will export the data and metadata of the specified database to the specified backup directory.

MongoDB and relational database: a comprehensive comparison MongoDB and relational database: a comprehensive comparison Apr 08, 2025 pm 06:30 PM

MongoDB and relational database: In-depth comparison This article will explore in-depth the differences between NoSQL database MongoDB and traditional relational databases (such as MySQL and SQLServer). Relational databases use table structures of rows and columns to organize data, while MongoDB uses flexible document-oriented models to better suit the needs of modern applications. Mainly differentiates data structures: Relational databases use predefined schema tables to store data, and relationships between tables are established through primary keys and foreign keys; MongoDB uses JSON-like BSON documents to store them in a collection, and each document structure can be independently changed to achieve pattern-free design. Architectural design: Relational databases need to pre-defined fixed schema; MongoDB supports

How to set up users in mongodb How to set up users in mongodb Apr 12, 2025 am 08:51 AM

To set up a MongoDB user, follow these steps: 1. Connect to the server and create an administrator user. 2. Create a database to grant users access. 3. Use the createUser command to create a user and specify their role and database access rights. 4. Use the getUsers command to check the created user. 5. Optionally set other permissions or grant users permissions to a specific collection.

How to encrypt data in Debian MongoDB How to encrypt data in Debian MongoDB Apr 12, 2025 pm 08:03 PM

Encrypting MongoDB database on a Debian system requires following the following steps: Step 1: Install MongoDB First, make sure your Debian system has MongoDB installed. If not, please refer to the official MongoDB document for installation: https://docs.mongodb.com/manual/tutorial/install-mongodb-on-debian/Step 2: Generate the encryption key file Create a file containing the encryption key and set the correct permissions: ddif=/dev/urandomof=/etc/mongodb-keyfilebs=512

What are the tools to connect to mongodb What are the tools to connect to mongodb Apr 12, 2025 am 06:51 AM

The main tools for connecting to MongoDB are: 1. MongoDB Shell, suitable for quickly viewing data and performing simple operations; 2. Programming language drivers (such as PyMongo, MongoDB Java Driver, MongoDB Node.js Driver), suitable for application development, but you need to master the usage methods; 3. GUI tools (such as Robo 3T, Compass) provide a graphical interface for beginners and quick data viewing. When selecting tools, you need to consider application scenarios and technology stacks, and pay attention to connection string configuration, permission management and performance optimization, such as using connection pools and indexes.

See all articles