我在每次启动时重置根目录的经验

  • Three Years of Ephemeral NixOS: After fresh OS install, digital debris remains. The impermanence project for NixOS allows listing files/dirs to persist across reboots.
  • What Survives Reboot: /boot, WiFi connection data, SSH host keys, Nix store, private Git repos, NAS data, various service state dirs, DHCPv4 leases, systemd timer/clock data, Restic cache, Signal Desktop data, Emacs config, GPG keys, Password Store repo, Rustup, SSH key, browser downloads, personal files.
  • What Doesn't Survive Reboot: Most of /etc, /var/cache, most of /var/lib, /var/log, NixOS-specific /var/nixos, most of ~/.config, stateless Firefox profile.
  • What's Worked Well: Gives peace of mind with small system state, allows fearless experimentation, eases bug reporting, makes backups easy, shows path to statelessness.
  • What's Worked Poorly: Requires conscious effort to persist data, adds complexity to installation, has undefined app behaviour, may cause performance problems with bindfs.
  • Is it Worth It: Declarative management reduces anxiety but costs time. Aim is to simplify maintenance by expanding what persists, starting with Firefox profile.
阅读 7
0 条评论