0

I have been getting into the warm waters of Nixos...

One of the questions the Nixos document does not appear to address is application state. There is, of course, application configuration, which is static and lives fine in the immutable nix-store; however both user and system mutable states aren't address. In particular, state format version changes during upgrades and rollbacks aren't mentioned. Presumably, upgrades are migrated fine from early format versions but what happens for rollbacks?

I am somewhat aware of HomeManager but it does not appear to address state format version changes nor does it appear applicable to system wide application states such as database structures.

Granted, configuration formats do not change frequently. However, is there documentation I am missing?

Thanks for your attention.

2
  • 3
    System state migrations are pinned to system.stateVersion, which should stay static as the system is upgraded. Commented Apr 15, 2024 at 8:33
  • Ok. So, system.stateVersion is the version of the format version of the mutable structures of the system or application. I expect rollbacks are problematic and moderated by this value, which seems very sensible. Wish is was more clearly documented. Commented Apr 16, 2024 at 16:19

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.