by rkangel · 2y ago · 0 comments
As the sibling comment describes, Nix can get a bit gnarly once you're off the beaten path, and having your whole OS subject to that is a pain.
But as an alternative approach I run Fedora, and install key stuff through the OS using dnf in the normal way, but then I have a home-manager config that covers all my key config, and a lot of the extra applications.
Yes, I don't get the full "value" of a whole system under version control. But I have a very stable, well proven system with few surprises. And I also have good version control of my config and day to day apps.
Plus the extra Nix stuff - if I want to try out a program, or use it temporarily I can just launch a shell with it and it's not cluttering up my system for ever (e.g. when exa was on HN yesterday, I could just do `nix-shell -p exa` to get a shell with exa in it. At some point in the future it'll get garbage collected again).
As the story goes, Ubuntu had just released 24.04 and I pushed to upgrade. My linux partition was on btrfs. I had been bitten by the snapshots-locking-my-system problem before so I cleared out all my snapshots (and backed up my drive to local NAS). During the update Ubuntu did ANOTHER SNAPSHOT, it took up all the space on device (256GB, yeah I should have had more space) and crashed the system. At that point I was finally done with all of the shenanigans that Ubuntu pulls with apt (not updating everything unless you have their subscription, forcing some installs to go through snapd, separate driver management from apt…), and this last update crashing my system’s boot, even though I could have recovered with my backup, was the last straw.
I considered my experience with Ubuntu, and MSFT’s actions to integrate Copilot into the OS, and decided to wipe the entire 1TB drive and go all in with NixOS. I was able to move my home-manager config right over, get my configs all converted to flakes, and get hyprland set up all in less than an hour. Smoothest transition in a long time. I even was able to jump to the 6.8 kernel and things just started working again. I was finally able to play steam games well on my system again. I may even have a path to get my VR to work in Linux again.
Are there still problems? Sure. Hyprland is a compromise because sway still won’t cooperate with Nvidia GPUs. But, when I have made changes that get me to a non-bootable state, I can boot to a previous generation directly from GRUB, see what went wrong, fix it, and get back to a good state. Having that ability to recover from a bad boot situation without hacking into a safe mode or GRUB console or rip the drive out and put it into another system was incredibly refreshing. I am not going back anytime soon.
This Fedora installation is 5 years old now. I have done a distro upgrade at least every year. It has worked extremely stabley and predictably all the way though, including the Fedora transition from X to Wayland.
I did not like my own Ubuntu experience when I was using few years before as well. I don't think its stable enough for newcomers as well.
For me, years and years ago, that 'pain' (having my whole 9S subject to Nix's constraints) is what pushed me to really learn it instead of just retreating to the traditional base system. It transformed learning Nix (and even sometimes writing packages or extending NixOS) into the path of least resistance to run the software I wanted or needed to use. And that was helpful for me.
For others (and for me at other times in my life) I understand that this is not always the right approach. But it can be really good.
Well, yes actually, you can get help in IRC/Matrix/etc. It's best effort and might not help, but it's not like commercial vendors promise fixes either.
In any event, Arch is in the same position so that's not really an argument in favor of either one.
I'm in my quest to find the "best supported" way to run ZFS on Linux and I've tried Ubuntu, Arch, RHEL, OpenSUSE. (I also tried FreeNAS (i.e. FreeBSD) in the past.)
Ubuntu has knowingly made a version of OpenZFS with (with their own patch causing) data corruption bug in the stable release. So since then I lost trust in them.
Arch Linux never officially supports it, and Arch's rolling release model with OpenZFS as kernel modules are not a good match for UX.
RHEL with kABI tracking kmod maintained by upstream seems to be a great, robust support combination, but later I found out that the kABI is not fully covered so it working relies on a bit of luck. AFAIK, it is still not completely resolved.
OpenSUSE with the "filesystem" project seems to be a semi-official support of seamless integration of OpenZFS with OpenSUSE. So far so good but I'm still evaluating.
In principle, nix and nixOS should be quite robust from its design (practically reproducible build). But I am not trusting nix that much yet and prefer something more battle tested. Coincidentally, I like the documentation of all the previous OSes I mentioned above (where Ubuntu falls a bit shorter among the crowd.) And from my limited experience, nix and friends are quite poorly documented.