VACUUM INTO: The SQLite Backup Command Most People Skip
VACUUM INTO is the safest way to back up and compact a SQLite database while it is running. Here is how it works, when it fails, and why I use it over file copies.
VACUUM INTO is the safest way to back up and compact a SQLite database while it is running. Here is how it works, when it fails, and why I use it over file copies.
A daily SQLite backup you never have to think about: a systemd timer running VACUUM INTO, plus retention and a restore-test hook. Real config included.
The honest path between 'keep it in SQLite' and 'run your own Postgres': move the part that needs it to a managed database and keep the rest in the file.
I corrupted SQLite databases on purpose and integrity_check passed on one that was actually broken. Here is the verified boundary of what this check can and cannot see.
A practical look at SQLite indexes: when they help, when they hurt, and how to find the queries that actually need one.
The clean ways to get data out of SQLite — JSON via sqlite3 CLI, CSV with proper headers, and the escaping traps that corrupt exports.
The tradeoff between speed and durability in SQLite: what WAL and synchronous=NORMAL actually mean, and when FULL is the right call.
A calm comparison between SQLite and MySQL from someone who runs both: when the zero-ops file wins, when you need a database server, and the honest middle.
Every database incident I have caused traces back to skipping one of these steps. Stop, back up, work on a copy, verify, swap — the ritual that prevents disasters.
A verified, step-by-step recovery of a corrupted SQLite database using VACUUM INTO, integrity_check, and backups — including what SQLite's integrity check can and cannot catch.