[Samba] Debug SMBD memory leak/usage
Timur I. Bakeyev
timur at freebsd.org
Tue Mar 6 03:29:41 UTC 2018
I've got numerous reports that SMBD on FreeBSD in some situations eats a
lot of (all) memory and as a last resort thought about using memory
allocation debugging to get better picture of where the memory leaks.
I guess I haven't done that for quite a while, as '--enable-dmalloc' option
from Samba 3.x has disappeared in Samba .4.x and supplying -DENABLE_DMALLOC
to CFLAGS doesn't add -ldmalloc to the list of libs to link with and hence
Samba build fails.
So, how should I make Samba to be build with dmalloc? And is this setup
At least smbcontrol still has options:
pool-usage Display talloc memory usage
Showed ridiculously small memory usage footprint by talloc, like 300Kb for
the 12Gb smbd process.
So, what are the current options to debug and trace down memory over-usage
and leaks in Samba?
With best regards,
More information about the samba