Following last month's Btrfs file-system tuning benchmarks, in this article are a similar set of tests when stressing the EXT4 file-system with its various performance-related mount options. Here are a number of EXT4 benchmarks from Ubuntu 12.10 with different mount option configurations.
Aside from testing the EXT4 file-system at its defaults on the Linux 3.5 kernel with Ubuntu 12.10, the common Linux file-system was tested with nobarrier, data=journal, data=writeback, nodelalloc, and discard. Here's the documentation on each mount option per the EXT4 documentation:
nobarrier: This disables the use of write barriers in the jbd code. This also requires an IO stack which can support barriers, and if jbd gets an error on a barrier write, it will disable again with a warning. Write barriers enforce proper on-disk ordering of journal commits, making volatile disk write caches safe to use, at some performance penalty. If your disks are battery-backed in one way or another, disabling barriers may safely improve performance. The mount options "barrier" and "nobarrier" can also be used to enable or disable barriers, for consistency with other ext4 mount options.
data=journal: All data are committed into the journal prior to being written into the main file system.
data=writeback: Data ordering is not preserved, data may be written into the main file system after its metadata has been committed to the journal.
nodelalloc: Disable delayed allocation. Blocks are allocated when the data is copied from userspace to the page cache, either via the write(2) system call or when an mmap'ed page which was previously unallocated is written for the first time.
discard: Controls whether ext4 should issue discard/TRIM commands to the underlying block device when blocks are freed. This is useful for SSD devices and sparse/thinly-provisioned LUNs, but it is off by default until sufficient testing has been done.
The testing occurred from a Lenovo ThinkPad W510 notebook with an Intel Core i7 720QM CPU and a 160GB Intel SSD. The EXT4 partition used for the benchmarking was re-formatted each time between testing the different mount option configurations. Here are the full system details:
All benchmarking was handled in a fully automated manner using the Phoronix Test Suite software.