SlackwareThis Forum is for the discussion of Slackware Linux.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I am about to install slackware 14.0 64-bit and have to choose between ext2 and ext4 (more precisely between journaling and non journaling). The last time I installed 14.0 (it was the 32-bit version) I chose ext4, and soon I regretted, but I do not remember why. What are the possible disadvantages of ext4/ext3 as compared with ext2?
"The only time I regretted using a filesystem was years ago, I was using ReiserFS and it deleted a bunch of files and killed my family."
Hell, I hope this is sarcasm only.
Last time I had to set a server up for non critical data, I used ext2. This filesystem has survived some power supply shutdowns with no critical data loss.
Ext4 is nice, but you have to be careful with the options. Barrirers, journal mode if any, delayed allocation etc. can cause data loss if set wrong. Don't assume defaults are sane! If you have to use Ext4, you'd better know how to do so. I have had to recover from backups some times precisely because a "performance feature" of an ext4 filesystem was enabled when it would have been better to shut it down...
One thing no one here has mentioned is that ext4 is an add-on (with, hopefully, more efficient and reliable code) to ext3, and ditto for ext3 to ext2 (more or less just journalling in that case). In the kernel, there is an option (which I think is the default on Pat's kernels) for the ext4 driver to also be used for any ext3/2 filesystems.
I mention this because you can tune ext4 to do anything you want with the proper options, including acting just like ext3 and 2. Likewise, if absolute data integrity is your goal, ext4 has some non-default settings (because you'll take a performance hit). Check out the tune2fs(8) man age: in particular, the mount option "journal_data_ordered" is the default, but "journal_data" (no suffix) is is the slowest, but safest (if memory from reading discussions on the subject serves correctly). If you're really paranoid, you can also turn off TRIM support (no "discard" entry or even "^discard" if you're exceptionally paranoid).
Btrfs and zfs have even more data-integrity options (block FEC if I recall correctly?), but btrfs had some regressions recently and still underperforms ext4 (but getting ever closer).
Personally, I've been using ext4 for years now on my laptop, and I haven't had a data loss yet even running the battery down to the point where the BIOS forces hard-shutdown!
(Of course, it's just a laptop, not a server...)