mongodb - Ubuntu机器上的XFS或ext4文件系统mongodb服务器?

标签 mongodb ubuntu filesystems ubuntu-16.04

由于 XFS 是 MongoDb 从以下链接推荐的:https://docs.mongodb.com/manual/administration/production-notes/

MongoDB on Linux

Kernel and File Systems

When running MongoDB in production on Linux, you should use Linux kernel version 2.6.36 or later, with either the XFS or EXT4 filesystem. If possible, use XFS as it generally performs better with MongoDB.

With the WiredTiger storage engine, use of XFS is strongly recommended to avoid performance issues that may occur when using EXT4 with WiredTiger.

With the MMAPv1 storage engine, MongoDB preallocates its database files before using them and often creates large files. As such, you should use the XFS or EXT4 file systems. If possible, use XFS as it generally performs better with MongoDB.

来自 Ubuntu 的链接:https://askubuntu.com/questions/690360/help-me-choose-the-best-filesystem-for-my-pc

Ext4 文件系统推荐用于所有 Linux 操作系统,因为它向后兼容其前身,您可以将 Ext2 和 Ext3 挂载为 Ext4 文件系统 分机4

reduces file fragmentation
employs delayed allocation which helps with flash memory life as well as fragmentation.
Good choice for SSDs and HDD

XFS

Good for a media file server because of constant throughput for large files.
Most distributions require separate /boot partition because XFS and GRUB can be unpredictable
Performance with small files is not as good.

那么在 ubuntu 16.04 上哪个更适合用于 mongodb .

最佳答案

XFS 为 better in general使用 WT,作为 MongoDB production notes建议。

我针对 AWS EC2 上的 MongoDB 运行了 XFS 和 EXT4 的性能基准测试,以找出您想知道的确切内容。 Here是我的结果。观察结果是,当您的机器具有 XFS 可以利用的多个内核和快速磁盘时,XFS 很有用。在中低端系统上,文件系统并没有什么不同。

关于mongodb - Ubuntu机器上的XFS或ext4文件系统mongodb服务器?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42431954/

相关文章:

node.js - Mongoose 递归填充

ubuntu - Ubuntu 13.10 上的 GCC 4.8.1 + Binutils 2.23.52

php - 具有文件系统功能的测试对象

android - 如何访问Android设备的根文件夹(/)的数据?

c# - 尝试使用带有 GUID 的 C# 持久化的 mongodb 读取 nodejs 中的数据

mongodb - 查询 mongoose 中最后 10 条减去最后 5 条记录

MongoDB "limit"运算符负值

python - 运行 python 脚本时出错

linux - 如何递归地将文件夹及其所有子文件夹和文件设置为 drwxrwxrwx

windows - 从 Win32 应用程序和 IBM RDZ/Eclipse 对大型机文件的一致访问?