Possible memory leak in DRBD 8.4.11

Reginald Cirque <[email protected]> Thu, 24 Apr 2025 11:22:52 -0400
Newsgroups dev.linux.lists.drbd-dev
Message-ID <CANA-72DMWg-UwGBVbM9y-p9zUJu_4LqZk3V9qOEZCM0nSHzq=Q@mail.gmail.com>
Good day,
I was syncing a 300 GB LVM volume from a DRBD primary to a newly-built
secondary, and noticed that the sending host (primary) had 300G of
"untracked", used, memory (not visible in slab, cached, or associated
with any application(s), simply shown as "kernel dynamic memory" in
"smem -twk" output) for long (many hours) after the sync had
completed, suggesting that DRBD buffers/page-pool were not reclaimed.

When I ran "drbdsetup down" to disconnect the secondary, I observed a
kernel log message:
"block drbd3: net_ee not empty, killed 291226 entries", which further
suggests to me that DRBD buffers are not being properly reclaimed.

The memory was returned back to the system ~instantly after
disconnecting the secondary.

I am running Linux kernel 6.1.128-1.el8.x86_64 and patching-in the
8.4.11 DRBD module in-tree.