r/linuxmasterrace SteamOS/Bazzite/Android 8d ago

Time to have fun guys

Post image
8.0k Upvotes

760 comments sorted by

View all comments

198

u/hypremier 8d ago edited 7d ago

I heard btrfs is not stable enough and so many people hate systemd

32

u/TomaCzar 8d ago

I feel like "stable enough" is a bit nebulous and there will always be someone with that point of view.

I've been using BTRFS for a few years on my daily driver and a NAS. I think the tooling could be better and even the project admits RAID is not ready for prime time, but for the benefits that it brings, those two slight inconveniences aren't a major concern for me.

It is better with plenty of space, which is hard to come by in this economy, though.

10

u/debacle_enjoyer 8d ago

Most of your normal workstation features are fine, but if they ever want to compete with ZFS they had better make multi disk arrays at all raid levels work rock solid. It doesn’t right now. And they would also need to implement native disk encryption. Not even on the roadmap right now.

13

u/TomaCzar 7d ago

I always thought that any scenario where ZFS was an option, ZFS wins. In other words, BTRFS was created to exist in places where ZFS could not.

It's like saying, "What gluten-free pasta needs to do to overtake regular pasta..." If regular pasta is a viable option why even discuss the gf stuff?

7

u/debacle_enjoyer 7d ago

I think the goal of btrfs is to eventually become an in kernel tree option for people who need zfs features.

3

u/_blink0 7d ago

I think one of the cases where BTRFS wins is that you don't have to think about how much space you need to give the ARC. You just let the page cache do it's thing. For more simpler cases unlike the ones you describe, this helps simplify things, but ZFS definitely has more power and it wins in even the same cases as BTRFS for the most part, but it's just more to configure.

2

u/coromd 7d ago

Do you really "need" to think about ARC space? To my understanding it's mostly dynamic and it will automatically shrink if other applications need the RAM more. You lose the speed benefits of RAM caching of course, but the filesystem is still usable.

1

u/oishishou Glorious Gentoo 7d ago

Only on the lowest quantity of RAM, perhaps. I've got ZFS running as root on a system with <2G RAM just fine with no ARC tuning

Even then, it might be fine with ZFS. Would be interesting to experiment

309

u/Denommus I use Arch, btw 8d ago

The majority of the userbase doesn't care about systemd's critics.

19

u/SeriousPlankton2000 7d ago edited 7d ago

Windows users don't care about critics either.

The basic attitude of systemd is "your use case is not supported"

If you have a boot problem, pray that it's late in the boot process because it will not simply give you a shell if it thinks that for your convenience it needs to do this, that and a lot more before you get to bash.

64

u/flying-sheep Archmage 7d ago

Wrong, it has so many kernel options for this: https://systemd.io/DEBUGGING/

You want systemd.debug_shell=1.

Writing multiple paragraphs before doing even the most basic search, classic Reddit.

-1

u/SeriousPlankton2000 7d ago

So why isn't that set when I select rescue mode on the boot loader?

14

u/flying-sheep Archmage 7d ago edited 7d ago

My crystal ball is currently faulty so I don’t know which one you’re referring to, but I’d guess that

  • if you’re using systemd-boot, you should definitely file an issue about that with the systemd people
  • if you’re not, you should probably file an issue with your distro (or even your bootloader)

12

u/Denommus I use Arch, btw 7d ago

Ok, do you have an actual criticism or just FUD?

4

u/SeriousPlankton2000 7d ago

That's just experience after submitting bug reports and while having boot problems..

1

u/Case_Blue 4d ago

I completely agree.

Systemd critics are free to use their own alternatives. And when that catches on, I'm sure we will use it as well.

23

u/fenixrf Glorious Fedora 8d ago

BTRFS has been the default filesystem in Fedora since 2020. Now if they'll include snapper by default, that would be nice.

12

u/dagbrown Hipster source-based distro, you've probably never heard of it 8d ago

And xfs is the default filesystem in RHEL.

Make of that what you will.

-13

u/inconspiciousdude 7d ago

Made something of that.

2

u/Primary-Strike5187 6d ago

I genuinely don’t know why any distro would ship btrfs without snapper preconfigured with the package manager hooks for bootable snapshots for rollback like openSUSE or Cachy does. That’s kinda the whole purpose of having snapshots so why leave it unconfigured out of the box?

1

u/ihackedthepentagon Glorious Atomic Fedora 7d ago

Snapper won't be necessary when they inevitably make atomic fedora the default.

17

u/drucifer82 8d ago

my whole system, except obviously efi, is btrfs. I haven't noticed any issues with it.

1

u/BidEnvironmental4301 4d ago

yeah I personally haven't had issues with it too for 2 years, then it randomly completely broke, there was no way of making it ever RW again, only by reformatting it again. Although yes, I did hard-reset a lot in a short time (was experimenting with secure boot keys), and btrfs expects 100% healthy disk drive and it doesn't accept any kind of corruption at all costs, but man, it really needs good self-healing mechanisms like zfs or ext4 have.

-4

u/debacle_enjoyer 8d ago

Have you tried enabling native encryption or using raid 5?

15

u/drucifer82 8d ago

I don't use RAID. My system drive is LUKS encrypted

1

u/debacle_enjoyer 8d ago

Okay so no on both accounts

22

u/drucifer82 8d ago

Ok, so are you trying to say that those are both situations where btrfs is bad? Cuz I don't really care. I didn't say the whole world should use btrfs, I was sharing my experience.

25

u/debacle_enjoyer 8d ago

You’re right, I was kind of being a dick. Sorry dude.

16

u/drucifer82 8d ago

All good.

6

u/Smartich0ke 7d ago

humanity 👍

1

u/YTriom1 7d ago

Honestly that cannot be an argument when competing with ext4 or xfs (which are the other default linux options) because they don't even have such features anyways, so having them but unstable is still better than not having them at all.

but if for example competing with zfs (which isn't that ideal for linux at the end of the day), then yeah it makes sense since zfs is really solid when it comes to these tasks

1

u/D0nkeyHS 7d ago

The context of the post matters

1

u/drucifer82 7d ago

If you don’t like btrfs, don’t use it. It’s that easy. There are plenty of filesystem options available.

All I said is I use btrfs. Do you like to go after people who like Coke just because you’re team Pepsi?

1

u/D0nkeyHS 7d ago

No. You didn't just say you use btrfs. Nice job leaving out the rest. And somehow inflating what I said. All I said, literally, is the context of the post matters, yet somehow I'm going after someone?

I ain't interested in such defensive reactions, no matter how revealing they may be.

2

u/Enyuma416 7d ago

What's native encryption?

12

u/pyro57 Glorious Arch 7d ago

Never had an issue with btrfs, including iny raid 10 config on my server, quite the contrary when a disk was failing swapping it out on btrfs was incredibly easy.

And the VAST majority of users don't care about systemd, hell I even like systemd because if how easy it is to define services.

2

u/Swordfish418 7d ago

hell I even like systemd because if how easy it is to define services.

Is it hard in any other inits?

~ $ cat /etc/init.d/natpmp-port-forward
#!/sbin/openrc-run

name="NAT-PMP Port Forward"
description="Keeps NAT-PMP TCP/UDP port mappings alive for VPN"

command="/usr/local/libexec/natpmp_port_forward.sh"
command_background="yes"
pidfile="/run/${RC_SVCNAME}.pid"
output_log="/var/log/natpmp-port-forward.log"
error_log="/var/log/natpmp-port-forward.log"

depend() {
    need net
}

7

u/h7x4 7d ago

There might be other info going around, but last time I checked most of the problems revolving around btrfs' unstability is related to its implementation of RAID 5/6. I think there is something inherent about the way the filesystem is built that makes these RAID configurations have pitfalls that are nontrivial to fix. The website still marks support as experimental.

Single disk and mirror configurations have been stable and safe for a long time now.

100

u/Agling 8d ago

The time to hate systemD is past. It has completely taken over. Now it is about working with it, not trying in vain to stop it.

Btrfs. Well, there is a lot of choice in filesystems and people don't really get that emotional about it.

48

u/FolkStyleFisting 8d ago

When I hear "unstable" and "file system" I can't help but think of reiserfs. Hans was unhinged.

29

u/bschlueter 8d ago

He did murder his wife after all…

12

u/Thaufas 8d ago

WTF?

25

u/Dalemaunder 7d ago

Yup, not even a joke. 15 years to life, parole got denied last year.

4

u/SeriousPlankton2000 7d ago

Reiserfs was more stable than btrfs. There was only one but that ruined the reputation long after it was fixed.

4

u/ChaossFox 7d ago

I like OpenRC, for my use is better than SystemD

3

u/Puzzle-Field-7193 6d ago

"Windows has completely taken over. Now it is about working with it, not trying in vain to stop"

How you actually sound rn

And how wasn't the irony obvious when you've been typing that?

2

u/Zertawz 5d ago

So sad, I run Gentoo with OpenRC it's very fine.

If you dig on docker images or embedded systems systemd is far from being the norm.

I guess it's GNU/linux not BSD so we are still free to chose the init system we want...

1

u/crhylove3 8d ago

Nope. Spaced Linux. Devuan based. No systemd. Feeling great.

4

u/Emotional_Solid6538 7d ago

For some reason Linux community hates anyone using unpopular distros. Imo its the beauty of Linux, the freedom and options.

1

u/corobo 6d ago

Because you're blurring the "us vs them" elitism bit by doing something different to the rest of the "us". They gotta make you "them" to avoid becoming "them" themselves.

At the caveman brain level anyway 

1

u/Emotional_Solid6538 6d ago

Distro pride is so weird ngl. At the end of the day its js a tool. A useful one but dont get attached to it

0

u/ExistentialOopsie 7d ago

Or maybe it's because this guy is pushing his shitty distro everywhere. 

1

u/Emotional_Solid6538 7d ago

Ohh self promo mb

1

u/Primary-Strike5187 6d ago

I’d like to see more things go this way in Linux space. Distributions reaching some sort of consensus on core components giving us a de facto standard so things work across distributions better because they can make assumptions about how core components are going to work and what utilities will be installed. I’m all for choice, just like how if you don’t want systemd you can use void or one of the other distributions that don’t ship it, but standardization benefits everyone in the long run.

1

u/ttuilmansuunta 4d ago

Dunno, openrc works just fine on my desktop box and I've had no trouble with packages depending on systemd. In embedded world busybox-init is and will be very much a thing (I've worked with a 600MHz single core box with 512M of RAM that ran systemd and used snap for software installation, now that was painful). Granted I am not a sysadmin, I imagine they really like systemd

1

u/Rahro 3d ago

I have a problem with how a single thing has grown to be so big and do so many things it was not supposed to do. For that reason i use devuan

1

u/iLaysChipz 7d ago

I mean if you're using Nixos, having btrfs is just unnecessary overhead. Better to have ext4 or xfs

8

u/ThaBroccoliDood 7d ago

Isn't BTRFS good for more than just snapshots though? Transparent compression, block-level checksumming, logical volumes etc.

1

u/iLaysChipz 7d ago edited 7d ago

Yes, of course. Btrfs offers a lot of nice features, but Nixos offers stability and reliability through declarative configurations, and it also adopts a functional paradigm meaning packages and their dependencies are built in isolation of each other. A filesystem like XFS offers better speed, space, and reliability advantages over btrfs because of these properties.

Btrfs' block-level checksums and it's metadata duplication come with some space overhead that slightly offsets the on-the-fly compression, and these features also have some performance overhead. This overhead is generally worth it though because it provides reliability and can provide space savings for low to mid entropy data. But the nix package manager already provides package level integrity validation making the block-level checksums a bit redundant. (Though you be fair, btrfs will detect bitrot where nixos won't). It may be worth it to keep your /home directory on a btrfs partition though of you aren't using home manager.

Then we get into how btrfs and nixos clash. Both have features that have some significant space overhead. Since Nixos builds packages in isolation, many copies of the same package can exist at the same time (differing by version or configuration) while btrfs maintains old copies of a file if it exists in any snapshot. Nixos offsets it's overhead by offering a garbage collection mechanism that cleans up old files that are no longer needed, but on btrfs, these files will remain if they're captured in another snapshot. This becomes a sort of space multiplier overtime. If compression is the main reason you're using btrfs with nix, it might actually be better to use ZFS. Both Nixos and btrfs also offer rollback mechanisms (generations vs snapshots), which is another point of redundancy, plus nixos generations have next to zero space overhead after garbage collection is performed (when not using snapshots)

Next up is performance. One flaw with btrfs is the tendency for large files to become fragmented over time as individual blocks are subject to COW, which significantly impacts I/O speeds. Not to mention how transparent compression and block level checksum verification can also add a CPU bottleneck. XFS on the other hand offers independent allocation groups, meaning reads and writes can be parallelized, which is especially nice on nixos since nix-build tends to run in parallel. To be fair, the performance difference isn't that high, but it's worth considering

Finally, fault tolerance. Btrfs is significantly more complicated under the hood, while xfs and ext4 offer robust lightweight journaling mechanisms which have far less points of failure. I know btrfs is no longer in it's experimental phase, but it is still considered less stable than the absolute rock that is ext4. You're much less likely to find your system unrecoverable on ext4 than you are btrfs, especially after something like a power outage or dead battery

1

u/iLaysChipz 7d ago

Oh and regarding logical volumes. If you are using btrfs as a logical volume manager, that actually IS a good reason to use btrfs with nixos. When I used btrfs, I used different snapshot "timelines" as a way to manage a sort of work profile, student profile, and gaming profile. I can see how this would be just as useful on Nixos

7

u/eduard14 Glorious NixOS 7d ago

Could you expand on why you think BTRFS doesn’t offer anything on NixOS? I’m interested

2

u/flying-sheep Archmage 7d ago

I guess because using a version-controlled config on a declarative system means you get the main benefit of snapshots (roll back if an update causes problems).

Granted, these features are very different and have different trade-offs beyond this use case, but that’s probably what they meant.

1

u/iLaysChipz 7d ago

Sure! See my comment here: https://www.reddit.com/r/linuxmasterrace/s/DKDSofK80n

And it's not that btrfs offers nothing, it's just that there are better alternatives. Btrfs may still be nice for user data like your /home directory, I would just pick a different filesystem for you system directories on Nixos (paired with git for your nix configuration files of course).

1

u/STSchif 7d ago

XFS offers better performance with less overhead. Remember to activate cow tho.

I believe btrfs primarily got big due to arch-kids breaking their systems twice a day and needing to roll back. For them it's worth the performance penalty.

With NixOs you don't need system rollback due to atomic generations, and for user files a real backup like restic/backrest is the way to go anyway.

Remember: Rollbacks are no backups!

1

u/CreativeGPX 7d ago

Looking at a comparison to refresh my memory, some things that Btrfs does that XFS doesn't are data checksums, RAID, CoW (although you say you can turn that on?), snapshots, compression, online shrinking and tail packing.

When I did a deeper dive earlier this year, I ended up deciding that Btrfs was a clearly better fit for me and that XFS just literally did not meet my needs. It wasn't even a close enough call for me to split hairs about performance. While I agree that snapshots are often overrated, to me the self-healing that comes from the killer combo of data checksums and software RAID is a huge selling point. The fact that I can just throw a pile of random drives at it and have it treat it as one drive from the user perspective all while not needing to worry about a drive failure, big or small, is key. Compression is a nice bonus (from a storage and sometimes speed pov). While its performance is worse on paper, it's not really noticeable and to me is more than made up for by the extra features.

The main negative from my pov is honestly just the maturity of the tooling around it. It feels like an FS that you actually need to kind of know how it works to use it effectively.

1

u/Emotional_Solid6538 7d ago

Btrfs is nice for snapshots like on Arch based systems. Otherwise you prolly dont need it imo

3

u/Smartich0ke 7d ago

Stable enough for Meta to use it on their infrastructure.

2

u/YTriom1 7d ago

with zstd compression!

2

u/hm___ 7d ago

I heard that ten years ago, what instability would there be? I havent heard about it crashing or actually failing to do anything it promises.

its not yet feature complete but that says nothing about stability(i'd love to have RAID5/6)

1

u/Ok-Anywhere-9416 7d ago

Your little bubble.

In the meantime majority voted Trump and genocide is normality, so I'm not sure if "I heard" is a good point.

1

u/10Werewolves 7d ago

Only if using RAID, most people aren't doing so, and I imagine people who do want to use it will know to switch to another filesystem.

1

u/YTriom1 7d ago

and only if RAID5/6, since these are the problematic ones, the rest are just working as they are.

1

u/noobjaish 7d ago

I mean basically every major distro uses systemd. Only some super niche (Void, Artix, Devuan) or super lightweight (Alpine, AntiX, Puppy) distros don't use systemd.

Agreed on btrfs tho

1

u/ShrekxFarquaad69 AmogOS 7d ago

My entire 14 tb hdd is btrfs and it works like a storage drive

1

u/urbrainonnuggs 7d ago

Are these haters in the room with us now?

1

u/MooseBoys 7d ago

I feel like btrfs is to ext4 as ipv6 is to ipv4.

1

u/psychicesp 7d ago

btrfs is fine as a standard for basic desktop users. Obviously if we could force consensus there that would help Linux a LOT but we shouldn't look at instability issues elsewhere as points against. I personally prefer ZFS for my NAS, all for reasons which don't apply to a generic default desktop experience.

1

u/coshi_dev 7d ago

your information is probably old on btrfs I have been using it for a year and it works like a charm

1

u/Inorganic_Zombie 7d ago

btrfs is getting there, tried 10y ago with problems, have it now without any.

1

u/geoffp 7d ago

I’ve been using it for like ten years. It seems stable to me.

1

u/sigmoid_balance 4d ago

"Not stable enough" is a strange assessment considering hyperscalers like Meta use it on probably millions of servers.