this post was submitted on 04 May 2024
117 points (96.1% liked)

Linux

48187 readers
1254 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by AlpΓ‘r-Etele MΓ©der, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Just a simple question : Which file system do you recommend for Linux? Ext4...?

EDIT : Thanks to everyone who commented, I think I will try btrfs on my root partition and keep ext4 for my home directory πŸ˜ƒ

top 50 comments
sorted by: hot top controversial new old
[–] [email protected] 111 points 6 months ago (27 children)

If you’re just doing a vanilla Linux install, ext4 is the way to go.

load more comments (27 replies)
[–] [email protected] 44 points 6 months ago (8 children)

In my opinion, it depends. If a distro has BTRFS configured to automatically take a snapshot when upgrading (like OpenSuse Tumbleweed), then BTRFS.

If not, for a beginner, ext4 + timeshift to take snapshots of your system in case an upgrade goes wrong will be fine.

load more comments (8 replies)
[–] [email protected] 32 points 6 months ago (4 children)

ext4 has been battle-tested for many years and is very stable. Doesn't have the same fragmentation and data loss issues certain other filesystems like NTFS have.

[–] [email protected] 17 points 6 months ago

And it has repair tools that actually work and can make the filesystem usable again.

load more comments (3 replies)
[–] [email protected] 21 points 6 months ago (4 children)

As someone who ran BTRFS for years, I'm personally switching back to EXT4. Yes, the compression and other features are nice, but when things go wrong and you have to do a recovery, it's not worth the complexity

[–] [email protected] 11 points 6 months ago (1 children)

I've found it much easier and way more reliable. If I pull out the power on ext4 it is likely to cause corruption and sometimes you can't fix it.

Btrfs is pretty much impossible to completely corrupt. I've had drives fail and I didn't lose anything

[–] [email protected] 24 points 6 months ago

Lemme say this - While complex, I can vouch for recovering files on BTRFS. I can't vouch for recovering files on ext4, because I never had to.

load more comments (3 replies)
[–] [email protected] 21 points 6 months ago (1 children)

ext4 unless you need features offered by another FS.

load more comments (1 replies)
[–] [email protected] 20 points 6 months ago (1 children)

Btrfs. Just format as one big partition (besides that little EFI partition of course) and don't worry about splitting up your disk into root and home. Put home on its own subvolume so that root can be rolled back separately from it. You can have automatic snapshots, low-overhead compression, deduplication, incremental backups. Any filesystem can fsck its own metadata, but btrfs is one of the few that also cares if your data is also intact.

load more comments (1 replies)
[–] HarriPotero 18 points 6 months ago

btrfs every day of the week. The only scenario where I'd even consider something else is for databases that would suffer from CoW.

I've been running it on my home server since 2010. The same array has grown from 6x2TB to 6x4TB, one disk at a time as they've failed. Currently sitting at 2x18TB+1x4TB. No data loss even though many drives have failed.

[–] [email protected] 15 points 6 months ago (5 children)

Btrfs is cool because it supports snapshots, if you don't plan on using these, just go with ext4

[–] [email protected] 8 points 6 months ago

I don't use snapshots but i love the compression.

load more comments (4 replies)
[–] [email protected] 14 points 6 months ago

If you don't actually have an opinion, just go with the default, ext4 really is a very good file system, but if you want to have an opinion and not go with the default, zfs is truly a fantastic file system.

[–] [email protected] 13 points 6 months ago

I personally use ext4 everywhere but it is recommend to have BTRFS for your OS partition if you take snapshots often.

[–] [email protected] 12 points 6 months ago

Ext4 for most home users, because it's simple and intuitive. Btrfs for anyone who has important data or wants to geek out about file systems. It's got some really cool features, but to actually use most of them you'll have to do some learning.

[–] [email protected] 12 points 6 months ago* (last edited 6 months ago) (2 children)

How about bcachefs. I'm waiting for it to support swapfiles, which seems to be in the TODO list, but so far doesn't work. If you use swap partition[s], or prefer not to have swap at all (I never fell for this, and besides swap is required for hibernation if that's a thing for you), then bcachefs is ready for you. It's already part of linux since 6.7, and on Artix, current linux is 6.8.9...

To me is the FS to use. I'm still on luks + ext4 (no LVM) and do entire home backups with plain rsync to an external device. I'd have to learn new stuff, since ext4 is really basic and easy to configure if in need, but I think bcachefs is worth it, and as mentioned, just waiting for it to support swapfiles, :)

load more comments (2 replies)
[–] [email protected] 11 points 6 months ago

Btrfs. It was the default filesystem already when I used Fedora on both my personal and work laptops. Not a single problem. It is true I don't really make much use of most of its advanced features like snapshotting, CoW, etc., but I also didn't notice any difference whatsoever in stability compared to ext4 so I'm pretty happy with it as my new default.

[–] [email protected] 11 points 6 months ago (5 children)

I would recommend using btrfs on SSDs and ext4 on hard drives.

load more comments (5 replies)
[–] [email protected] 11 points 6 months ago (1 children)

Just go with whatever is the default of your distribution.

That said I've come to love the automatic snapshots OpenSUSE gives me with BTRFS. I think they use snapper to automate that. It does a snapshot before and after every packet install, update or removal. And it has some system to delete snapshots that aren't needed anymore but it always keeps enough to give you peace of mind, especially when you're experimenting.

I should look into keeping some snapshots of my ~ as well. And I should implement that especially for my family.

load more comments (1 replies)
[–] qui 10 points 6 months ago

I prefer using ext4 for stability. But if stability doesn't matter to you, you should use BTRFS.

[–] [email protected] 10 points 6 months ago* (last edited 6 months ago)

For standard use, ext4. If you want to tinker and use fancy features, btrfs (or maybe zfs?).

[–] [email protected] 8 points 6 months ago

Do what OpenSUSE Tumbleweed suggests, make a brtfs partition for your system and xfs/ext4 for home parition

[–] [email protected] 8 points 6 months ago

ext4, just keep it simple.

[–] Rustmilian 8 points 6 months ago

BTRFS &/OR EXT4

[–] hperrin 8 points 6 months ago (1 children)

I’ve been very happy with btrfs. Ext4 is basically rock solid, so you can’t really go wrong with it, but btrfs has some nice features that ext4 doesn’t have, like snapshots. And it’s fast. I have an extremely cheap SSD that’s too slow to run anything with ext4, but actually usable with btrfs.

load more comments (1 replies)
[–] [email protected] 6 points 6 months ago (4 children)

I have 3 drives in my pc. I have btrfs for root so I can do my snapshots, and the rest are on ext4. I've heard very good things about xfs, too, but I'm more familiar with btrfs and ext4

load more comments (4 replies)
[–] mholiv 6 points 6 months ago (2 children)

Btrfs or XFS.

No idea why people are into EXT4. XFS is more performant by far.

load more comments (2 replies)
[–] [email protected] 6 points 6 months ago (2 children)

Ext4 is, afaik, the fastest as it's the most understood

Btrfs has compression and you can make snapshots to roll back to if something goes wrong (not necessary on immutable distros or NixOS tho)

There are many other options, but I've only ever had a need for those two

load more comments (2 replies)
[–] [email protected] 6 points 6 months ago

If you don't care any will do. ext4 is fine but check the "use LVM" button during install if you do go with ext4 since it will give you better partitioning options later.

[–] [email protected] 6 points 6 months ago (2 children)

I love zfs. Started using it for my data storage pool and now I have it on root as well. It has some rough edges but overall it is very stable and has amazing features.

load more comments (2 replies)
[–] RustyNova 5 points 6 months ago (3 children)

I don't know what's the brand neW meta pick, but at least BTRFS over Ext4. BTRFS is just more stable and less corruptable than Ext4. Heck, fedora changed to it as default

load more comments (3 replies)
[–] [email protected] 5 points 6 months ago (1 children)

XFS. It fills the same role as ext4 but it's less likely to lose your data and that's probably the most important part of a file system. Not that ext4 is bad or anything, but XFS is good. The only downside to XFS is you can't shrink the filesystem size.

load more comments (1 replies)
load more comments
view more: next β€Ί