this post was submitted on 12 Jul 2023
9 points (100.0% liked)

Gentoo Linux

452 readers
1 users here now

The Gentoo Linux community for discussions, tips and tricks, and general kernel compiling

founded 1 year ago
MODERATORS
 

Posted something similar on the NixOS sublemmy, but it basically boils down to the fact that I tend to switch back and forth between both distros, and I enjoy both very much as both Gentoo and NixOS provide an immense degree of control over my system and allow me to go wild and do whatever I want. But I feel the need to settle on one system and tinker with the other on a VM instead, as this switching back and forth is becoming a time sink and hindering my studies somewhat. The question is, which to use as the main desktop system? Gentoo feels more intuitive to me, but NixOS is definitely powerful at managing complex systems, but then again, I only have a simple desktop system. Another thing that I thought of is that maybe I can somewhat replicate NixOS' rollback feature, which is my absolute favourite feature of it, using a combination of Git and ZFS snapshots? I'd like to hear your thoughts on this.

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 3 points 1 year ago (1 children)

Another thing that I thought of is that maybe I can somewhat replicate NixOS’ rollback feature, which is my absolute favourite feature of it, using a combination of Git and ZFS snapshots? I’d like to hear your thoughts on this.

While I don't know what exactly NixOS' rollback feature entails, I run / on btrfs and use a cronjob to create snapshots of the "rootfs" subvolume. I maintain a history for the last 48h. This allows me to roll back when something goes wrong, which basically never happens though. That way though there is basically nothing to fear when doing large updates.

[–] [email protected] 2 points 1 year ago

NixOS is immutable: once you build your system, you cannot change it. If you want to modify anything, you build an entirely new system, and boot into that, making a new generation. Rollbacks simply involve booting into a previous generation, which means that system configurations (and user configurations if you have home-manager) is left perfectly intact the exact way you set it up before.