midnight-saci

Keep and back up run data

This page describes what the backend stores, how to remove old runs and how to back up the data.

Data directory

The backend keeps everything durable in backend.data_dir (default saci-data, relative to its working directory), created on start:

File Contents
saci.db (with saci.db-wal, saci.db-shm) SQLite database: runs, their event logs, evidence and reports.

Each run stores:

Runs are not deleted automatically. To remove old runs, stop the backend and delete or archive the data directory, or delete rows with the sqlite3 tool.

Back up by stopping the backend and copying the directory, or while it runs with sqlite3 saci-data/saci.db ".backup saci-backup.db".

The database carries a schema version. A backend upgrades older databases on start and refuses to open one written by a newer Saci.

All database work runs on blocking threads, off the backend’s async runtime.

Next steps