On 09/03/2015 12:56 PM, Jakub Hrozek wrote:
On Thu, Sep 03, 2015 at 12:48:20PM +0200, Pavel Březina wrote:
Hi, due to recent memory leak issues, I think it would be good to provide a built-in way to store talloc full report in a file. It proved to be very helpful in detection of the location where memory leak occurs, but we always obtained it from custom built.
I would very much like to write a patch, but I'd like to hear your opinion on how it should be obtains. I have few ideas:
- Periodic task -- periodically (1 hour?) store talloc full report into a
file.
+1 for periodic task
Generate report on signal.
Generate report on D-Bus method.
Provide a tool that would do 2) or 3).
I personally favor 1).
Do you plan to use a new debug level to avoid the cost associated with walking the talloc hierarchy and printing the output? This debug aid must be free of cost for anyone not using it..
New debug level is not bad, but I would personally prefer completely new option. Something like: talloc_report_period = 60
That would start the periodic task every 60 minutes. 0 would be a special (and default) value, which would disable this feature.
Michal