Runtime data location
Slowave isolates runtime data under the OS user’s native application-data directory. The database, PID file, logs, and backup archive all live beneath this root.
Run
slowave doctor to print the effective root and database path for your current environment.
To relocate the complete runtime tree, set SLOWAVE_HOME before starting any Slowave process. See Configuration for all environment variable options.
Creating a backup
Thebackup command writes a gzip-compressed snapshot of the live database into the backups/ subdirectory of the runtime root.
Backup uses the SQLite online backup API and is safe to run while the daemon and worker are active. It does not lock or pause either service.
Automatic daily backups
slowave setup installs a daily backup service alongside the daemon and worker. The service creates one snapshot per day and prunes older archives automatically according to the --keep value (or SLOWAVE_BACKUP_KEEP).
Restoring from a backup
1
Stop daemon and worker
The HTTP MCP daemon is stopped if it is running. The background worker is also terminated to prevent any writes during the swap.
2
Clear WAL sidecar files
Stale SQLite sidecar files (
-wal, -shm, -journal) are removed so they do not contaminate the restored database.3
Atomically replace the database
The compressed snapshot is decompressed into a temporary file in the same directory as the live database, then atomically renamed into place. The restore validates the result with a basic SQLite integrity read before completing.
<db-path>.bak so you can recover manually. On a successful restore the .bak is removed.
If the restored database was created by an older Slowave version, the engine will perform an automatic rebuild the next time it starts — replaying raw events to reconstruct derived state. This rebuild can take several minutes for large databases and is a normal, one-time cost.
After a successful restore, restart the daemon manually:
--yes only in unattended scripts where you are certain about the target path:
Migrating from a legacy ~/.slowave installation
Older Slowave installations stored data in ~/.slowave. The migrate-data command moves this data to the native per-user root through a staged SQLite online backup and integrity check.
1
Preview the migration
Run a dry run to see exactly what will be moved and where, without writing any files.
2
Run the migration
Execute the migration. The command will ask for confirmation unless Migration stops the legacy daemon if one is running, copies the SQLite database through the online backup API, validates
--yes is supplied.PRAGMA integrity_check, then promotes the staged directory to the new root.3
Verify the result
Confirm the new installation is healthy.
Migration refuses to proceed if the destination is non-empty. It always preserves the
~/.slowave source tree intact so you can roll back by stopping the new daemon and running commands with SLOWAVE_HOME=~/.slowave (or pointing SLOWAVE_DB at the exact legacy database path).Backup configuration
The backup directory and retention count can be overridden with environment variables:
These variables are read by both the manual
slowave backup command and the scheduled service installed by slowave setup.
