On 4/13/07, Alan Robertson <[EMAIL PROTECTED]> wrote:
Hariharan Jayaraman wrote:
> Hi All,
>
> We are using linux ha for achieving HA solution for a 2 node system. We
> have
> observed memory leaks in the crmd process and seen it grow to beyond 700MB.
>
> I am currently running 2.0.8 with a patch that fixes a few memory leak
> issues in crmd. I am trying to use valgrind and efence to nail down more
> memory leaks.
>
> To this effect i complied heartbeat with --enable-crm-force-malloc and now
> the system does not come up, looking at the error log seems that there
> is an
> inconsistency in the call and free function, even with this flag set, i see
> that while reading cib, i use crm_malloc0 to allocate and free using
> cl_free
> which fails in GUARD_IS_OK macro.
>
>
> My questions are:
>
> 1> Does --enable-crm-force-malloc work ?
> 2> How can use valgrind effectively, crmd is started by heartbeat so how do
> i make it work with valgrind?
> 3> Will using efence cause any problem, i see that code has varied
> allocation logic implemented.
>
> Incase this is not a place for this, should i post this in the dev list?
Andrew is really the right person to answer this, but he's really busy
at the moment. The -dev list probably is a slightly better place to ask
this.
I think the memory leaks have been fixed in the current Hg tip. Have
you tried it?
Right, testing against the latest development code (which will be
released with hopefully minimal changes soon) is the best idea.
Otherwise you're likely to be reporting things that are already fixed
- which isn't an effective use of anyone's time :-)
To enable valgrind, make sure you pass the following configure options:
--enable-libc-malloc
(turns off our internal allocator so valgrind can do its job)
--with-valgrind-suppress=/path/to/exceptions.supp
(a file with a list of false positives)
--with-valgrind-log=--log-socket=yourhost:1234
(the location and port where valgrind-listener is running)
After that, just add "crm valgrind" to ha.cf (instead of "crm yes") to
enable it.
This method has the advantage of being easy to enable/disbale without
needing to recompile.
_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems