lantern icon indicating copy to clipboard operation
lantern copied to clipboard

Memory leak in Lantern UI

Open myleshorton opened this issue 12 years ago • 10 comments

After running in give mode overnight, Lantern was using almost 800MB of memory. I'm guessing the lines on the map are leaking memory

myleshorton avatar Aug 24 '14 17:08 myleshorton

Note the process that was taking up that much memory was the UI process itself - closing it both killed the process and associated memory.

myleshorton avatar Aug 24 '14 17:08 myleshorton

If you run it directly in Chrome, you can take a memory snapshot. You can also try forcing a GC to see what that does.

Cheers, Ox


"I love people who harness themselves, an ox to a heavy cart, who pull like water buffalo, with massive patience, who strain in the mud and the muck to move things forward, who do what has to be done, again and again."

  • Marge Piercy

On Sun, Aug 24, 2014 at 12:27 PM, myleshorton [email protected] wrote:

Note the process that was taking up that much memory was the UI process itself - closing it both killed the process and associated memory.

— Reply to this email directly or view it on GitHub https://github.com/getlantern/lantern/issues/1745#issuecomment-53200471.

oxtoacart avatar Aug 24 '14 19:08 oxtoacart

Good idea! I'll do that tonight.

On Sunday, August 24, 2014, oxtoacart [email protected] wrote:

If you run it directly in Chrome, you can take a memory snapshot. You can also try forcing a GC to see what that does.

Cheers, Ox


"I love people who harness themselves, an ox to a heavy cart, who pull like water buffalo, with massive patience, who strain in the mud and the muck to move things forward, who do what has to be done, again and again."

  • Marge Piercy

On Sun, Aug 24, 2014 at 12:27 PM, myleshorton <[email protected] javascript:_e(%7B%7D,'cvml','[email protected]');> wrote:

Note the process that was taking up that much memory was the UI process itself - closing it both killed the process and associated memory.

— Reply to this email directly or view it on GitHub https://github.com/getlantern/lantern/issues/1745#issuecomment-53200471.

— Reply to this email directly or view it on GitHub https://github.com/getlantern/lantern/issues/1745#issuecomment-53204715.

Adam pgp A998 2B6E EF1C 373E 723F A813 045D A255 901A FD89

myleshorton avatar Aug 24 '14 22:08 myleshorton

This also make Lantern super sluggish.

myleshorton avatar Aug 27 '14 18:08 myleshorton

I'm not able to reproduce this. I launched Lantern in give mode with the UI in Chrome. After a few hours, memory usage seems about the same. This may be because nobody is proxying through me, so no arcs? (This is what I understand @myleshorton means by "the lines on the map").

So one way to try and reproduce this (and thus know when I've fixed it) would be to make a fake backend that sends the frontend lots of traffic events. Hopefully this tool helps with future testing and troubleshooting of the UI.

Do you know if there's anything on these lines already? If not does it sound like something worth doing, or am I yak shaving?

aranhoide avatar Sep 09 '14 01:09 aranhoide

The mock backend does exist but also what's your IP? I can add you to the round robin, which is how I produced this originally.

On Monday, September 8, 2014, aranhoide [email protected] wrote:

I'm not able to reproduce this. I launched Lantern in give mode with the UI in Chrome. After a few hours, memory usage seems about the same. This may be because nobody is proxying through me, so no arcs? (This is what I understand @myleshorton https://github.com/myleshorton means by "the lines on the map").

So one way to try and reproduce this (and thus know when I've fixed it) would be to make a fake backend that sends the frontend lots of traffic events. Hopefully this tool helps with further testing and troubleshooting of the UI.

Do you know if there's anything on these lines already? If not does it sound like something worth doing, or am I yak shaving?

— Reply to this email directly or view it on GitHub https://github.com/getlantern/lantern/issues/1745#issuecomment-54912405.

Adam pgp A998 2B6E EF1C 373E 723F A813 045D A255 901A FD89

myleshorton avatar Sep 09 '14 01:09 myleshorton

@aranhoide it exists here: https://github.com/getlantern/lantern-ui/tree/master/mock -- it's what we are running off of some node servers on the website. See it live here: https://lantern-ui.nodejitsu.com/app/index.html

atavism avatar Sep 09 '14 01:09 atavism

Or shall I say, Chrome was using roughly the same amount of RAM. Lantern itself (reported as 'java' in the Ubuntu System Monitor's process view) was at 735 MB, over twice as much as it started with.

aranhoide avatar Sep 09 '14 01:09 aranhoide

This could be platform specific.

oxtoacart avatar Sep 09 '14 12:09 oxtoacart

(We're waiting for Todd's UI changes – #1768 –  to land in order to see whether this is still an issue.)

scouttle avatar Nov 19 '14 22:11 scouttle