borgbackup / borg

Deduplicating archiver with compression and authenticated encryption.
https://www.borgbackup.org/
Other
11.05k stars 737 forks source link

sometimes slow backup of unchanged files on NFS #6019

Open ThomasWaldmann opened 2 years ago

ThomasWaldmann commented 2 years ago

Note: debugging this on a specific system right now, keeping some notes here.

Is this a BUG / ISSUE report or a QUESTION?

Unclear yet.

System information. For client/server mode post info for both machines.

Your borg version (borg -V).

1.1.17

Operating system (distribution) and version.

Redhat or rh-derivate.

Hardware / network configuration, and filesystems used.

6(?) cores, 32GB RAM

How much data is handled by borg?

TBD

Full borg commandline that lead to the problem (leave away excludes and passwords)

Roughly this:

borg create --compression lz4 --list --files-cache=ctime,size ... /mnt/localhdd::repo /mnt/remotenfs/

Describe the problem you're observing.

Sometimes backup slows down from the usual 100..1000 unchanged files per second (status U) to only a few per second.

Usually when run as a nightly cronjob. When trying to reproduce interactively, it is hard to reproduce.

Analysis / Suspicions

When processing lots of unchanged files, borg is doing:

Other stuff coming to mind as difference between cron use and interactive use:

Notes

Added now --numeric-owner --noatime --noacls --noxattrs --nobsdflags to try if this resolves the issue.

Also considering monitoring with atop and doing a timestamped strace when it's running slowly.

FabioPedretti commented 2 years ago

For the record I experienced similar slowdowns on NFS, with many previous releases which got some fixes in the later 1.1 releases, and again with borg 1.2, this was discussed at https://github.com/borgbackup/borg/issues/4498. See also https://github.com/borgbackup/borg/issues/3039. Thanks for looking at it!