In "Snapshotting a DigitalOcean Droplet while it's running" (https://dev.to/remdore/snapshotting-a-digitalocean-droplet-while-its-running-4m3c), Remdore restores a series of disk snapshots to compare three kinds of application state: committed PostgreSQL rows, file writes followed by fsync, and file writes left for the operating system to flush.
Compare the restored data
The test used one Frankfurt Droplet running Ubuntu 24.04 and PostgreSQL 16 with default settings. During the live snapshots, the database accepted numbered rows one transaction at a time. A separate process appended numbered lines to two files and called fsync after each line in one file only. The numbered records let Remdore compare the end of each restored stream and look for missing entries within it.
PostgreSQL replayed its write-ahead log after each of the six live restores. Remdore found no gaps in the restored row sequence, and the final row and final synced file entry were within seven milliseconds of one another. The unsynced file was between 0.7 and 26.4 seconds behind and had trailing zero bytes in each live restore. An application reading that file could therefore encounter a tail that looks different from a cleanly truncated stream.
Test recovery at the application boundary
After a powered-off snapshot, Remdore found all rows and lines present in the restored copy. The interval from requesting shutdown to regaining SSH access was 66 seconds for that run. The live tests kept the machine serving and showed no increase in 99th-percentile commit latency on this workload. Those timings describe a single machine and configuration. DigitalOcean's snapshot documentation still advises considering a shutdown when applications need time to write their data to disk.
The distinction matters when a service stores related state in multiple places. A database can come up and replay its log while a plain file used by the same service is missing recent contents. Remdore's restore check suggests a concrete test for that situation: identify the records that should agree across both stores and compare them after recovery.