Memory leak ~1GB/24 hours

Bug #1133202 reported by Anders Eriksson
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
System Load Indicator
New
Undecided
Unassigned

Bug Description

Running system load indicator 0.2 in unity on Ubuntu 12.10 with "CPU", "network" and "Hard disk" monitoring enabled causes the multiload-indicator process to grow with about 1 GB resident memory in 24 hours.

Looking at the memory maps in /proc/<pid>/maps it seems to be the [heap] that grows:

02512000-41c58000 rw-p 00000000 00:00 0 [heap]

I ran gnome classic mode (with compiz) before and I did not notice this behaviour then, but it may have been leaking more slowly as I have 16GB of RAM and may have missed the growth then.

What more information do you need?

Revision history for this message
Anders Eriksson (aen-launchpad) wrote :
Revision history for this message
Michael Hofmann (mh21) wrote :

Hi Anders,

thanks for filing the bug. This is a problem somewhere in the libappindicator library that the indicator uses :-(.

The indicator in raring (13.04) or at ppa:indicator-multiload/stable-daily (https://code.launchpad.net/~indicator-multiload/+archive/stable-daily) has been updated to work around that problem, so I suggest you upgrade to the version found there (gui or command line: sudo add-apt-repository ppa:indicator-multiload/stable-daily; sudo apt-get update; sudo apt-get install indicator-multiload).

There is a backport pending for getting this version also into 12.10 and 12.04, but this might still take some time.

Hope that helps!

Michael

Revision history for this message
Anders Eriksson (aen-launchpad) wrote : Re: [Bug 1133202] Re: Memory leak ~1GB/24 hours

Hi Michael,

Thank you for the prompt reply. I tried the new version (0.3) but before I
left work it still looked like it was leaking memory (although not quite
as quickly). I'll give you another update tomorrow.

Could this be caused by running on two screens perhaps?

I have also tried to disable network and hard disk monitors, but that did
not help either.

/Anders

On Tue, 26 Feb 2013, Michael Hofmann wrote:

> Hi Anders,
>
> thanks for filing the bug. This is a problem somewhere in the
> libappindicator library that the indicator uses :-(.
>
> The indicator in raring (13.04) or at ppa:indicator-multiload/stable-
> daily (https://code.launchpad.net/~indicator-multiload/+archive/stable-
> daily) has been updated to work around that problem, so I suggest you
> upgrade to the version found there (gui or command line: sudo add-apt-
> repository ppa:indicator-multiload/stable-daily; sudo apt-get update;
> sudo apt-get install indicator-multiload).
>
> There is a backport pending for getting this version also into 12.10 and
> 12.04, but this might still take some time.
>
> Hope that helps!
>
> Michael
>
>

--
http://faldor.mine.nu/~anders/ +46 (0)8 733 31 46
<email address hidden> www.umunet.org -- because uucp is becoming extinct

Revision history for this message
Michael Hofmann (mh21) wrote :

Hi Anders,

yeah it is still leaking but the indicator is restarting itself when its
resident size reaches 50MB; and the restart shouldn't be too noticable.

It would be better to fix the leak instead of the workaround, but I don't
know the code to well that seems to cause the leak :-(. I made a valgrind
log for the leak at
https://bugs.launchpad.net/indicator-multiload/+bug/1101810/comments/5, but
I'm not sure it is actually as bad as what you describe. Maybe the problem
only occurs under specific circumstances...

Michael

2013/2/26 Anders Eriksson <email address hidden>

> *** This bug is a duplicate of bug 905854 ***
> https://bugs.launchpad.net/bugs/905854
>
> Hi Michael,
>
> Thank you for the prompt reply. I tried the new version (0.3) but before I
> left work it still looked like it was leaking memory (although not quite
> as quickly). I'll give you another update tomorrow.
>
> Could this be caused by running on two screens perhaps?
>
> I have also tried to disable network and hard disk monitors, but that did
> not help either.
>
> /Anders
>
> On Tue, 26 Feb 2013, Michael Hofmann wrote:
>
> > Hi Anders,
> >
> > thanks for filing the bug. This is a problem somewhere in the
> > libappindicator library that the indicator uses :-(.
> >
> > The indicator in raring (13.04) or at ppa:indicator-multiload/stable-
> > daily (https://code.launchpad.net/~indicator-multiload/+archive/stable-
> > daily) has been updated to work around that problem, so I suggest you
> > upgrade to the version found there (gui or command line: sudo add-apt-
> > repository ppa:indicator-multiload/stable-daily; sudo apt-get update;
> > sudo apt-get install indicator-multiload).
> >
> > There is a backport pending for getting this version also into 12.10 and
> > 12.04, but this might still take some time.
> >
> > Hope that helps!
> >
> > Michael
> >
> >
>
> --
> http://faldor.mine.nu/~anders/ +46 (0)8 733 31 46
> <email address hidden> www.umunet.org -- because uucp is becoming extinct
>
> --
> You received this bug notification because you are a member of System
> Load Indicator developers, which is subscribed to System Load Indicator.
> https://bugs.launchpad.net/bugs/1133202
>
> Title:
> Memory leak ~1GB/24 hours
>
> Status in System Load Indicator:
> New
>
> Bug description:
> Running system load indicator 0.2 in unity on Ubuntu 12.10 with "CPU",
> "network" and "Hard disk" monitoring enabled causes the multiload-
> indicator process to grow with about 1 GB resident memory in 24 hours.
>
> Looking at the memory maps in /proc/<pid>/maps it seems to be the
> [heap] that grows:
>
> 02512000-41c58000 rw-p 00000000 00:00 0
> [heap]
>
> I ran gnome classic mode (with compiz) before and I did not notice
> this behaviour then, but it may have been leaking more slowly as I
> have 16GB of RAM and may have missed the growth then.
>
> What more information do you need?
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/indicator-multiload/+bug/1133202/+subscriptions
>
>

Revision history for this message
Anders Eriksson (aen-launchpad) wrote :

Hi Michael,

See reply inline

On Tue, 26 Feb 2013, Michael Hofmann wrote:

> *** This bug is a duplicate of bug 905854 ***
> https://bugs.launchpad.net/bugs/905854
>
> Hi Anders,
>
> yeah it is still leaking but the indicator is restarting itself when its
> resident size reaches 50MB; and the restart shouldn't be too noticable.

Ok, I see. Yes this workaround seems to solve the problem of the proces
using up all memory. I notice the PID is not changed when memory is freed
up again, so what do you mean by "restart"?

> It would be better to fix the leak instead of the workaround, but I don't
> know the code to well that seems to cause the leak :-(. I made a valgrind
> log for the leak at
> https://bugs.launchpad.net/indicator-multiload/+bug/1101810/comments/5, but
> I'm not sure it is actually as bad as what you describe. Maybe the problem
> only occurs under specific circumstances...

Yes, I think there is something special in my setup triggering this since
my colleague do not see the same problem.

Thanks again for the quick response and for a working solution.

/Anders

Revision history for this message
Michael Hofmann (mh21) wrote :

No problem. The indicator uses execvp (see e.g.
http://linux.die.net/man/3/exec), which replaces the current process with a
new one.

Michael

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.