• @netwren@lemmy.world
    link
    fedilink
    191 year ago

    Honestly this is the reason I want an immutable build of Arch like NixOS.

    Let me roll back my mistakes and I could live more happily with rolling release.

    • @seaQueue@lemmy.world
      link
      fedilink
      141 year ago

      When I started using Arch I just set it up on a btrfs filesystem and wrote a simple btrbk hook to take a snapshot before any package updates. That made it trivial to unfuck anything that broke after an update. I can’t remember the last time I had to roll the system back but it’s nice for peace of mind.

      • @CarlosCheddar@lemmy.world
        link
        fedilink
        31 year ago

        That’s quite clever, are there any guides for getting that set up? I’m using btrfs but haven’t gotten into snapshotting yet.

        • @seaQueue@lemmy.world
          link
          fedilink
          10
          edit-2
          1 year ago

          Start by playing with subvolumes and snapshots so you can get a feel for how they work. Once you’ve got that down you can break down your root filesystem into sensible subvolume chunks (/, /home, /var/log, /var/cache etc) so that you only snapshot relevant content during each update. I wrote a btrbk config at that point, tested it a few times and then wrote a pacman hook to fire it on install, update or package remove events and went from there.

          Here’s what I use to take snapshots - you’ll need to write an appropriate btrbk config file for your subvolume layout but it’s otherwise feature complete. https://gitlab.com/arglebargle-arch/btrbk-autosnap

          Like I mentioned above, I haven’t actually needed to roll the system back in ages but I get a lot of mileage out of being able to reach back in time and grab old versions of files for comparison.

          Time shift is a lot easier if you’re just starting out but it also requires a specific subvolume structure and isn’t very flexible.

          Edit: pro tip: don’t make /var a separate subvolume from /, it’s way, way, way too easy to roll one or the other (/ or /var) back without the other. If you do that by accident pacman’s state becomes out of sync with the running system and everything breaks. Stick to splitting frequently rewritten data like /var/cache and /var/log off, leave /var itself in the root subvolume.

    • @PainInTheAES@lemmy.world
      link
      fedilink
      7
      edit-2
      1 year ago

      I feel like I keep posting this everywhere but there’s a project called AstOS that attempts this. Also someone clued me in on this distro neutral solution. AshOS. Full disclosure I haven’t used either.

        • @PainInTheAES@lemmy.world
          link
          fedilink
          11 year ago

          Oh totally fair, it doesn’t have a huge maintainer base for sure. But it’ll never be anyone’s daily driver if no one knows about it.

      • @takeda@lemmy.world
        link
        fedilink
        0
        edit-2
        1 year ago

        It looks like solutions like these miss the whole point of what Nix is trying to do. Nix comes with the belief: “Unix has some fundamental issues, because it was designed in specific way. If we store things differently it works really well, and we even get those cool properties for free”.

        The authors of those projects instead of thinking “this looks interesting, and it is a paradigm shift but it might be worth to to try feel like Linux noob for some time and start thinking a bit differently how the file system is structured to see if this change is really worth it”

        Instead it is: “I don’t need to be PhD in Computer Science (whatever that means), here is how I can force this Nix feature or two on traditional Linux, with ansible, bubble gum and some duct tape and make it immutable-ish, which fails sometimes but, hey, it has the same feature on paper.”

        • @PainInTheAES@lemmy.world
          link
          fedilink
          21 year ago

          Well to be fair I think it’s because they aren’t trying to be NixOS. You could leverage those arguments against any distro that’s trying out an immutable flavor. Which is mostly accomplished through btrfs features.

          I agree that Nix/NixOS does a lot more and it’s a genuinely impressive and paradigm shifting project but it does break with traditional Linux layouts and thinking in a way that immutability doesn’t necessarily have to do.

          You could also make the same argument with the systemd and non-systemd crowd.

          Either way I look forward to the future of both immutability projects and NixOS. I feel like both areas still need a bit of work but they’re both really exciting fields.

      • @netwren@lemmy.world
        link
        fedilink
        11 year ago

        Well yeah obviously like NixOS. My reason for not using it is that they use a non standard Linux filesystem and it renders a # of packages I want to install incompatible.

        • @iopq@lemmy.world
          link
          fedilink
          11 year ago

          Which packages?

          1. Check nixpkgs unstable, they might have been added in the last few months before stable release
          2. Try steam-run, it will run binaries like you’re in a normal distro

          I ended up packaging the thing myself, actually. The best part is my pull request was approved and I was able to contribute my work

          • @netwren@lemmy.world
            link
            fedilink
            11 year ago

            Yeah you could put some together I think, possibly with OverlayFS as well.

            I feel like the value those distros add is not just the rolling mechanism but the package manager being tied into it.

            So you just use the package manager like any other and it works.

    • @takeda@lemmy.world
      link
      fedilink
      41 year ago

      I love it, because you can also get best out of both worlds in relation to the comic discusses. You can personalize OS to your liking, and the entire configuration is in a file, so you can redeploy the same setup again.