Difficulty starting continuous replication with child process #263
-
I have noted stale data in the app I have set up, with long lag periods. I'm running a Go app using v0.3.7 with the subprocess -exec command on Fly.io, and streaming to Backblaze. Do I need to modify the configuration for continuous sync? My impression is that changes to the database are not being automatically streamed, and that I have not successfully started the replicate command. My second impression is I've misunderstood how it updates, but anticipated essentially syncs on change with up to 10s (by default) of delay. For example, this evening: if I run litestream generations snapshots, or wal, I saw data with only one older generation listed:
I can manually force a sync by:
Litestream generations/snapshots/wal then show me a more up-to-date copy, at the time the container shut-down or when I SSH-ed in to run the command. The log messages I can find around replication/restoration are on start only: My setup is inspired by the example at https://github.com/benbjohnson/litestream-docker-example, using a static binary. run.sh
litestream.yml
Thank you! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
@kurtis-poole Sorry for the delay getting back to you. I got my booster shot on Wednesday and it knocked me out pretty good. Hmm, that is an odd behavior. It's strange that Litestream picks up the snapshot but nothing else. A couple questions to help debug:
|
Beta Was this translation helpful? Give feedback.
@kurtis-poole Sorry for the delay getting back to you. I got my booster shot on Wednesday and it knocked me out pretty good.
Hmm, that is an odd behavior. It's strange that Litestream picks up the snapshot but nothing else. A couple questions to help debug:
Is your application updating the journal mode? Litestream sets the database to WAL mode but I could see it breaking if you're reseting
journal_mode
to something else.Do you see a file called
/data/db-wal
and is it growing as you're making transactions against your database?Can you run a
tree
command against the/data/.db-litestream
directory and see what it shows? I'm curious if Litestream is copying out the WAL pages but not r…