Ask HN: Why can't database files be safely synchronized, can we ever get there?

2 gausswho 0 7/24/2025, 5:39:43 PM
I'm currently using Syncthing for synchronizing data across my devices. It works really well for most things, but a huge exception are things that use a local database such as SQLite.

An example would be Firefox profiles, which are somewhat infamous for being corrupted due to this issue. I'd like to have the same profile across all my machines, but have learned this is practically not possible.

The maintainers of Syncthing explicitly warn against synchronizing databases as it's currently technically infeasible and can result in data loss.

My understanding is that this is an architectural problem. That synchronizing tools work at the file level, while database consistency requires an understanding of transactional boundaries.

My question is: This should be generally resolvable right? If so, how can we resolve this? Can SQLite or other databases be changed so that there is resilience and integrity expressed through the file system itself? Can SQLite data be structure such that its transactions be more safely merged? Can Syncthing recognize a database file and know to wait because it is not in a stable state for synchronizing?

Comments (0)

No comments yet