From de25ed2aac8dc6be1ce062ba58cc7b4bea0dc9ebd0fea170e9e2ef14fb1ace2b Mon Sep 17 00:00:00 2001 From: kira Date: Wed, 9 Sep 2026 16:33:37 +0200 Subject: [PATCH] Smol initial work --- src/index.md | 3 +++ src/updates.md | 17 +++++++++++++++++ 2 files changed, 20 insertions(+) create mode 100644 src/index.md create mode 100644 src/updates.md diff --git a/src/index.md b/src/index.md new file mode 100644 index 0000000..68e97ea --- /dev/null +++ b/src/index.md @@ -0,0 +1,3 @@ +Documentation for Kira Linux + +[Update Process](updates.md) diff --git a/src/updates.md b/src/updates.md new file mode 100644 index 0000000..0137819 --- /dev/null +++ b/src/updates.md @@ -0,0 +1,17 @@ +[Back to index](index.md) +# Update process + +Main feature of Kira Linux is atomic (to some degree) update process that allows roll back of unsuccessful or broken updates. + +We achieve this by relying on bcachefs snapshots and subvolumes. + +The main routine is as follows: +1. Before update process snapshot /usr and /var directories. +Put snapshots to **/bzz-snaps** directory named as **bzz-usr-yyyy-mm-ddTHH-MM-SS** and **bzz-var-yyyy-mm-ddTHH-MM-SS** +2. Set update status in /var/lib/hive-up/hyve-db.json as failed (update_status = false) +3. Perform update (pacman -Su) +4. If update was successful, set update status in /var/lib/hive-up/hyve-db.json to true. +5. Process with reboot. +6. On boot Nyanit reads update status from /var/lib/hive-up/hyve-db.json and if it is false roll back latest snapshots from /bzz-snaps dir. +7. Otherwise boot as usual. +