backuppc / rsync-bpc

Rsync-bpc is a customized version of rsync that is used as part of BackupPC
GNU General Public License v3.0
28 stars 17 forks source link

Possible memory leak in rsync_bpc #28

Open opoplawski opened 2 years ago

opoplawski commented 2 years ago

Looks like rsync_bpc grew to a very large size and was killed:

kernel: [ pid ]   uid  tgid total_vm      rss nr_ptes swapents oom_score_adj name
kernel: [19879] 40001 19879 16685899 13895036   32541  2745607             0 rsync_bpc

rsync-bpc-3.1.3.0-1.el7.x86_64

sistason commented 1 year ago

can reproduce, I have to build and use rsync-bpc-3.1.2.2, which does not leak memory (latest makes it impossible to use BackupPC, as all backups will use 100% memory and get killed by oom-killer).

Using BackupPC:4 on Alpine in Docker on a Ubuntu22-VM.

eguaj commented 8 months ago

I'm also experiencing this problem using BackupPC 4.4.0 from Ubuntu 22.04 (backup-4.4.0-5ubuntu2 + backuppc-rsync-3.1.3.0-3build1).

I consistently reproduce the problem on a newly installed BackupPC server (not yet in production) by manually triggering a backup with BackupPC_serverMesg backup all and a set of 6 hosts.

If I replace the rsync_bpc v3.1.3.0 binary bundled by Ubuntu with a manually built rsync_bpc v3.1.2.2, then I do not reproduce the problem (after resetting the stored files {cpool,pc,log}/* and re-running a BackupPC_serverMesg backup all).

TheNetworkIsDown commented 3 months ago

We've had these issues with both v3.1.2.2 and v3.1.3.0 manually built. Tens of millions of files.