On Tue, Mar 22, 2022, 09:16 Rich Shepard <rshep...@appl-ecosys.com> wrote:
> Last night's incremental backup for /home has an error: > Rsync-Errors (/media/backup/salmo-home/20220322-0030/tree/../rsync_error): > ========================================================================= > RSYNC_ERR: > RSYNC_ERR: > RSYNC_ERR: *** Execution cycle 0 *** > RSYNC_ERR: > RSYNC_ERR: file has vanished: > "/home/rshepard/.spamassassin/bayes.lock" > RSYNC_ERR: rsync warning: some files vanished before they could be > transferred (code 24) at main.c(1189) [sender=3.1.3] > > I want to understand this error. > > Looks to me that the bayes.lock is created when a new email message arrives > and is removed when spamassassin has processed the message. If that's the > case why would rsync be looking for a file that was removed? > . There is delay between a) when rsync collecting what needs to transfer and b) the actual transfer. Files changed between a) and b), that is what is happening. You could avoid it by 1) not writing/deleting stuff on the disk when your backup is in progress or 2) by making filesystem snapshot and backing up the snapshot. 1) is probably not practical. 2) would require filesystem change to COW filesystem such as btrfs on Linux or zfs on BSD. Common practice is to live with the errors or 2). Best, Tomas