I’m redoing my home server. I’m moving from arch to fedora server to force myself to learn that stuff.
I also want to use the bcachefs subvolume and compression features. I am presented with a couple issues I need smarter people to explain to me though.
subvolumes: My understanding is subvolumes in bcachefs dont get mounted separately like you would expect. they are just folders that you can isolate a snapshot to. so I dont need to mount a subvolume, just mount the filesystem it exists in already and it comes along for the ride. but what happens if I want to rollback? Lets say I want to rollback to a previous snapshot on the / but not mess with anything in the subvolume /home/thatuser. wouldn’t rolling back to the previous root also rollback the subvolumes contained within? perhaps I should create a separate partition just for root afterall.
mount: I can mount with
mount -t bcachefs /dev/device1:/dev/device2:/dev/device3
and everything works. However, if I mount with
mount -t bcachefs UUID=(externalUUIDfromshow-super)
not all devices in the pool will attach. some stay detached. so how am I supposed to mount them all at boot? I can’t just refer to them by device path because if I add more drives later, those paths may change.
compression: the documentation is kind of out-of-sync on different sites but what I was able to piece together is you can set different rules for compression recursively for different directories/subvolumes like this…
sudo bcachefs set-file-option /mnt/tempy/ --compression=zstd:3 --background_compression=zstd:12
then read back what was already set with…
getfattr -d -m 'bcachefs_effective\.' /mnt/tempy
so while the above makes sense for a root or user home folder, for VM disk images, I might want to set…
sudo bcachefs set-file-option /mnt/tempy/vmstorage/ --compression=none --background_compression=none --nocow
or even do something similar without the nocow for media folders within the compressed home user folder…
sudo bcachefs set-file-option /mnt/tempy/home/thatuser --compression=zstd:3 --background_compression=zstd:12
sudo bcachefs set-file-option /mnt/tempy/home/thatuser/media --compression=none --background_compression=none
mount at boot: okay, I know I need the DKMS and userspace tools installed as separate packages since Kent was naughty and got his project booted out of the kernel. but I’m not entirely certain how to convey to fedora it needs to bundle those pieces with the initiramfs. I know arch uses something different from fedora to do that, with fedora using dracut. I need to learn how to use dracut.
install: this I have no idea what to do. Fedora’s anaconda expects something very different and will not eat what I’m trying to feed it. so I need to find a way to bootstrap a fedora server install on to this system. Supposedly theres a way to do that with DNF.
Anyway, could someone explain the subvolume puzzle to me and maybe give pointers on bootstrapping fedora server and teaching it to mount all the devices in the pool at boot?


Well once upon a time I did. I used arch back then and I didn’t use subvolumes. It was a simpler setup and worked fine. It also wasn’t exposed to WAN. Now I want to learn about subvolumes and I want to learn fedora.
I like picking projects just a bit out of reach for me to focus on and really dig into. It gives me something to obsess over other than, well, -gestures broadly-.
Arguing with this pile of micro center parts is basically therapy for me.