Created attachment 14108 [details] git-am fix for master. On Fri, Apr 06, 2018 at 04:40:44PM -0400, Andrew Walker via samba-technical wrote: > Hi all, > I encountered an issue where several FreeNAS users on samba 4.7 were > experiencing memory leak resulting in single smbd process consuming all > available RAM and swap space. Disabling the getwd cache significantly > increased rate of leak, and enabling widelinks / disabling unix extensions > made the leak apparently stop. Investigation indicated that the leak was in > vfswrap_getwd(). > > The attached patch resolved the issue.
Created attachment 14109 [details] git-am fix for master. I think this one is a simpler change.
Created attachment 14112 [details] git-am fix for master. Confirmed fixed by submitter.
(In reply to Jeremy Allison from comment #3) Should we put similar warning to the `vfswrap_realpath` then, as `sys_realpath()` suffered from exactly the same problem?
No, only change the function that needed addressing. If we refactor later we can add this.
Quick confirmation that your patch fixes the issue I was seeing. Thanks for your prompt response. Next time I will generate a corresponding bug report.
Created attachment 14115 [details] git-am fix for 4.7.next, 4.8.next. Cherry-picked from master. Applies cleanly to 4.7.next, 4.8.next.
Reassigning to Karolin for inclusion in 4.7 and 4.8.
Pushed to autobuild-v4-[7,8]-test.
(In reply to Karolin Seeger from comment #9) Pushed to both branches. Closing out bug report. Thanks!