<div dir="ltr">Hi,<div><br></div><div>I am working on finding ways to indentify ref leaks in glusterfs.</div><div><br></div><div>Description of Issue : <a href="https://bugzilla.redhat.com/show_bug.cgi?id=1417539">https://bugzilla.redhat.com/show_bug.cgi?id=1417539</a></div><div><br></div><div>Goal : To make script which could detect all kind of ref leaks.</div><div><br></div><div>Script : <a href="https://github.com/SonaArora/Tracing-userspace-app/blob/master/ref-leak/try8-modified">https://github.com/SonaArora/Tracing-userspace-app/blob/master/ref-leak/try8-modified</a></div><div>The above script is a POC program to depict the idea of how to identify leaks. Script is probing dict_ref() and dict_unref() and keeping a track of the pointers, back traces which are referenced/dereferenced by above functions. If the count of refs is unequal to unrefs for each pointer,it will print all the traces corresponding to the leaked pointer.</div><div>Output : <a href="https://github.com/SonaArora/Tracing-userspace-app/blob/master/ref-leak/output-refleak">https://github.com/SonaArora/Tracing-userspace-app/blob/master/ref-leak/output-refleak</a></div><div>I am working on post processing the output - to filter only the leaked traces and to write the output after every few hours into a file.<br></div><div>The script can be extended to all objects being referenced (like inodes/fds).</div><div><br></div><div>End Goal : Future goal is to make it more versatile, dynamic and light weight so that it can be even utilized on production environments without utilizing much of the system resources.</div><div><br></div><div>Request your comments and suggestions.</div><div><br></div><div>Best</div><div>-Sonal</div><div><br></div><div><br></div></div>