@@ -240,8 +240,8 @@ The command:
240240 ` schema_meta.role = "global" ` before checkpointing or changing the file .
2412413. Requires a non - busy ` wal_checkpoint(TRUNCATE) ` . Stop any remaining OpenClaw
242242 process and retry if the checkpoint is busy .
243- 4. Sets ` auto_vacuum ` to ` INCREMENTAL ` , runs a full ` VACUUM ` , and checkpoints
244- again .
243+ 4. Sets ` auto_vacuum ` to ` INCREMENTAL ` , runs a full ` VACUUM ` , then refreshes
244+ SQLite planner statistics with ` ANALYZE ` and completes a final checkpoint .
2452455. Runs ` quick_check ` , ` integrity_check ` , and ` foreign_key_check ` , then
246246 reapplies owner - only permissions to the database and SQLite sidecar files .
247247
@@ -315,8 +315,9 @@ expected target count; a nonexistent explicit store path selects no targets.
315315SQLite deletes reclaim pages inside the database first ; they do not necessarily
316316shrink the database file immediately . After deleting or archiving large
317317transcripts , run ` openclaw doctor --session-sqlite compact --session-sqlite-all-agents `
318- to checkpoint WAL files , run ` VACUUM ` , and report before / after database and WAL
319- sizes . Compaction requires a regular file with the current agent schema , the
318+ to checkpoint WAL files , run ` VACUUM ` , refresh SQLite planner statistics with
319+ ` ANALYZE ` , complete a final checkpoint , and report before / after database and
320+ WAL sizes . Compaction requires a regular file with the current agent schema , the
320321selected agent ' s durable owner metadata, and no open handle in the doctor
321322process . The destructive ` import ` , ` compact ` , ` recover ` , and ` restore ` modes
322323hold the same state ownership lock as Gateway startup for their full operation ;
0 commit comments