Filesystem Tuning

From Notes

Jump to: navigation, search

There are a couple of key tuning parameters that might give greater performance on an ext3 filesystem.

Creating an index of all directories on the filesystem will improve the search speed. This must be done in two steps. The first step is to enable the directory index with tune2fs.

tune2fs -O dir_index <volume>

The second step is to perform the indexing. This step must be performed when the filesystem is not mounted.

e2fsck -D <volume>

Another option that may improve performance at a slight risk of old data appearing after a recovery is enabling journal_data_writeback. This only requires one step to perform.

tune2fs -o journal_data_writeback /dev/vg01/lvolVM

Man page notes

dir_index

Use hashed b-trees to speed up lookups in large directories.

journal_data_writeback

When the filesystem is mounted with journalling enabled, data may be written into the main filesystem after its metadata has been committed to the journal. This may increase throughput, however, it may allow old data to appear in files after a crash and journal recovery.

Personal tools