Filesystem test: Reliability versus Speed

Filesystem Crash Test and Performance
Willem pretending being a computer expert
When installing linux, you have a great choice of filesystems. Popular filesystems for linux are: ext2, ext3, reiserfs, (XFS and JFS). These filesystems are different in many ways: Performance, CPU load and reliability. Unfortunaly, good complete filesystems tests on the internet don’t exist, are obsolete of very hard to find. Guess what we did on a sunday afternoon! A little filesystem test, with the purpose to compare reliability with performance.

Testing envoiriment:
Hardware: Dell Dimension 2400 P 4 2.0 Ghz 512 MB Ram.
Software: Gentoo Linux 2004.0 kernel 2.6.5 r2 sources

Tested filesystems:

How did we test the filesystems:

Software for testing:
On a fresh installed linux (Gentoo linux – stage3 pentiumIIII – kernel 2.6.5 t2 ) we created 4 partitions. A Boot, swap, root and a backup partition. After a clean non-X installation of gentoo, we copied the root and boot pratitions to a place on the backup partition. This way we easialy could format and change the filesystems of the boot and root partitions since we got a backup of the data in the backup partitions.

Every filesystem we tried got tested on two thing, speed and reliability.
Speed test:
With a tool called bonnie++ Bonnie’s website we tested the filsystems on speed. For the results click here.
summerized: ReiserFS is the fastest, all other show common benchmarks, all (including reiserFS) had a heavy CPU load, with the exeption of XFS.

More important, the crash test:
Just the same as the speed test, but this time the power went down during testing. In other words, what happens to the filesystem if the power goes down, but it’s very very busy with read/write files:

ext2: Damaged, and couldn’t be repaired without a bootable cd. The filesystem had to be checked with fsck.ext2 while it wasn’t mounted. After the check the filesystems worked again.

ext3: A little warning message, but after the check at startup (without the need of a boot cd) all the damage was repaired.

reiserfs: Same as ext3, a little warning and after the check everything went flawless.

JFS: Not very crash resistance. (wat gebeurde er ook alweer, kapot en niet meer te repareren?) After the crash test the filesystem was so damaged it couldn’t repair itself.

XFS: Couldn’t resist a heavy crash test. Besides the regular power-off while benchmarking test, we did something extra (something we should have done every time). While we compiled X, we pulled out the powerline again. System got damaged and couldn’t be repaired since the fix tool didn’t worked. (seemed like a empty file, nothing happend)


A good thing to know is that the tests depends on so many things, that you probaly get other results if you run the ’same’ test after a month (other kernel etc..) I can remember that reiserFS was damaged so badly after a system hang, that reinstalling was the only solution. Other benchmarks on the internet show different results. In other words: Tomorrow everything can be different, but for now: ReiserFS was the winner of the test.

ext2: Not very fast, not very crash-resistance (but repairable). Can be repaired but only if unmounted.

ext3: Not very fast, but hard to take down. This filesystem can repair itself at startup. Properly the best choise for a strong robust filesystem considering by all the resources on the net and our experience.

reiserfs: The fastest filesystem if we should believe bonnie++. And more important, reiserfs could repair itself after the crashtest. For me the winner of the test.

JFS: Performance are alright, but isn’t crash resistence. Got damaged so bad we couldn’t fix it.

XFS: The only filesystem which had a low CPU load on the benchmarks. Maybe a good choice if the fixtool (fsck.XFS) worked.

tested by: Dae Punt and Willem Hendriks