Tailscale Database Corruption
- Tailscale discovered a 16-year-old SQLite bug causing database corruption.
- The bug was isolated using an open-source SQLite VFS shim.
- Tailscale funded the development of the shim to track down similar bugs.
The Issue
Tailscale found that a single Go process accessing the database could still cause data corruption due to a race condition.
We funded the open-source SQLite VFS shim that helped isolate the race condition almost immediately, and will help track down similar bugs in the future.
Technical Details
The bug details on the SQLite page outline that it can only ever occur if there are multiple connections open.
SQLite: 92 million lines of tests Dijkstra: Tests can only prove the presence of bugs, never their absence!
The Internet’s Verdict: 70% Hyped, 30% Skeptical
Focus Keyword: Tailscale SQLite