LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 02-20-2015, 04:49 PM   #1
mpyusko
Member
 
Registered: Oct 2003
Location: Rochester, NY, USA
Distribution: Salckware ver 10.1 - 14.1, Debian too.
Posts: 432
Blog Entries: 1

Rep: Reputation: 41
Chrome Memory Leak on Debian Jessie


I have Chrome Stable Debug installed on my Debian Jessie Laptop (hal9000 in signature). It will start up and within a couple minutes chrome will eat up several Gigabytes of memory and slow the computer to nearly an unusable state. A pretty impressive feat considering it is only one tab open and my Laptop is a Core i5-540M with 8GB physical DDR3 1333 RAM.

I have tried systematically disabling extensions but it makses no difference. The core Chrome process goes nuts. The interesting part is the same issue happens with Chromium. The latest stable chrome will bring KDE to a screeching halt. The latest Chromium will bog the computer about 2 minutes after opening for about an additional 15 minutes. I surmize it is because it has gone and used up all my physical ram and is then fighting for read/writes to the swap partition (which in most cases is completely empty until Chrome/ium starts. I have a video (you can mute the playback, FF once it hits 3.2 GB, I pan the camera around so you can see details about my system if needed.) https://www.youtube.com/watch?v=cIUinTuvz3w showing what happens. Note two key points.... 1, the mouse pointer, it is still other than arranging windows, so I'm not opening other applications nothing major is running in background. The CPU was stable at around 9% prior to opening chrome. 2, The computer virtually freezes once Chrome hits 3.2GB. I click "Stuff for Nerds and it shoots up to over 6GB by the time that page loads. (I ended the video long before then, see attached image.) Longer after, the computer became usable again and I refreshed the page (after taking that screenshot) and it seemed to pan out at 3.2GB. I also ran the following....

Code:
root@hal9000:/# top -bn1 |grep chrome
19371 mpyusko   20   0 11.729g 3.214g  28308 S   0.0 41.8   6:30.20 chrome
19423 mpyusko   20   0    6376    668    668 S   0.0  0.0   0:00.00 chrome-sandbox
19424 mpyusko   20   0  364656   3056   2584 S   0.0  0.0   0:00.07 chrome
19436 mpyusko   20   0    6376    616    616 S   0.0  0.0   0:00.00 chrome-sandbox
19479 mpyusko   20   0  372852   2792   2068 S   0.0  0.0   0:00.03 chrome
19815 mpyusko   20   0  761628  13080   7880 S   0.0  0.2   0:01.55 chrome
19888 mpyusko   20   0  744376   6432   4824 S   0.0  0.1   0:01.05 chrome
20008 mpyusko   20   0  748176  12812   7688 S   0.0  0.2   0:01.16 chrome
20113 mpyusko   20   0  745400  14008   7936 S   0.0  0.2   0:01.20 chrome
20116 mpyusko   20   0  748176  23584  11064 S   0.0  0.3   0:03.35 chrome
20120 mpyusko   20   0  814044  36984  14476 S   0.0  0.5   0:04.88 chrome
20136 mpyusko   20   0  741304  11244   6696 S   0.0  0.1   0:01.10 chrome
21632 mpyusko   20   0  920816 145780  17136 S   0.0  1.8   0:37.85 chrome
21916 mpyusko   20   0  710180   5392   3928 S   0.0  0.1   0:32.64 chrome
22137 mpyusko   20   0  754156  35936  23360 S   0.0  0.4   0:00.82 chrome
root@hal9000:/#
So what can I do to track down the issue? Is there any way I can limit how much memory chrome is able to use? I have 8G phsyical RAM and an 8GB swap. That is more than I should ever really need. I have no issues running win7x64pro in Virtualbox with 4GB physical ram allocated and unlimited CPU resources. It barely touches the swap even then.

Thanks
Attached Thumbnails
Click image for larger version

Name:	Chrome leak1.jpg
Views:	47
Size:	102.5 KB
ID:	17620   Click image for larger version

Name:	Chrome leak2.jpg
Views:	43
Size:	98.6 KB
ID:	17621  
 
Old 02-21-2015, 01:20 PM   #2
yooy
Senior Member
 
Registered: Dec 2009
Posts: 1,387

Rep: Reputation: 174Reputation: 174
Have you tried to disable extenstions?
 
Old 02-24-2015, 10:00 AM   #3
mpyusko
Member
 
Registered: Oct 2003
Location: Rochester, NY, USA
Distribution: Salckware ver 10.1 - 14.1, Debian too.
Posts: 432

Original Poster
Blog Entries: 1

Rep: Reputation: 41
Quote:
Originally Posted by yooy View Post
Have you tried to disable extenstions?
Yes.

Quote:
Originally Posted by mpyusko View Post
I have tried systematically disabling extensions but it makses no difference.
 
Old 03-02-2015, 01:33 PM   #4
mpyusko
Member
 
Registered: Oct 2003
Location: Rochester, NY, USA
Distribution: Salckware ver 10.1 - 14.1, Debian too.
Posts: 432

Original Poster
Blog Entries: 1

Rep: Reputation: 41
I started Chrome about 40 minutes ago after disabling all the extension s before I closed it the previous session. Here is a screenshot from when it essentially froze my system. (Cpu usage is low, but drive activity is monopolized). I'm still waiting for it to free up. My 8GB of physical ram and all 8GB of swap is now in use.

Also see attached photo of the console....
Attached Thumbnails
Click image for larger version

Name:	Chrome leak3.jpeg
Views:	46
Size:	214.0 KB
ID:	17720   Click image for larger version

Name:	IMG_20150302_142840442.jpg
Views:	37
Size:	271.3 KB
ID:	17721  
 
Old 03-02-2015, 02:06 PM   #5
mpyusko
Member
 
Registered: Oct 2003
Location: Rochester, NY, USA
Distribution: Salckware ver 10.1 - 14.1, Debian too.
Posts: 432

Original Poster
Blog Entries: 1

Rep: Reputation: 41
One hour and seventeen minutes later, Chrome finally became responsive and I can now use my laptop again. Here is the info from the command line...
Code:
mpyusko@hal9000:/opt/Minecraft$ top -bn1 |grep chrome
  704 mpyusko   20   0 15.172g 4.661g  59388 S   6.4 60.7   7:16.99 chrome
  714 mpyusko   20   0    6376    420    420 S   0.0  0.0   0:00.00 chrome-sandbox
  715 mpyusko   20   0  364656   1940   1212 S   0.0  0.0   0:00.05 chrome
  719 mpyusko   20   0    6376    416    416 S   0.0  0.0   0:00.00 chrome-sandbox
  779 mpyusko   20   0  372852   2568   1668 S   0.0  0.0   0:00.01 chrome
  865 mpyusko   20   0  463972  75804  48460 S   0.0  0.9   0:05.14 chrome
  982 mpyusko   20   0  357708   3852   3784 S   0.0  0.0   0:00.00 chrome
 1031 mpyusko   20   0  861176 115408  31296 S   0.0  1.4   0:18.92 chrome
 1036 mpyusko   20   0  779848  30772  12184 S   0.0  0.4   0:04.31 chrome
 1040 mpyusko   20   0  790772  44040  19548 S   0.0  0.5   0:07.08 chrome
 1043 mpyusko   20   0  759680   7476   5660 S   0.0  0.1   0:00.69 chrome
 2367 mpyusko   20   0  710180   4772   3344 S   0.0  0.1   0:27.52 chrome
13563 mpyusko   20   0  824728 113368  41404 S   0.0  1.4   0:12.21 chrome
mpyusko@hal9000:/opt/Minecraft$
Notice in the attached screenshot I only added a tab to make this post.
Attached Thumbnails
Click image for larger version

Name:	Chrome leak4.jpg
Views:	32
Size:	65.5 KB
ID:	17722  
 
Old 03-02-2015, 03:28 PM   #6
yooy
Senior Member
 
Registered: Dec 2009
Posts: 1,387

Rep: Reputation: 174Reputation: 174
If you really want to use chromium-browser you may need to try several versions, this seems to me like a chromium bug.

You can also submit this bug or search if submitted before.
 
Old 03-02-2015, 04:54 PM   #7
mpyusko
Member
 
Registered: Oct 2003
Location: Rochester, NY, USA
Distribution: Salckware ver 10.1 - 14.1, Debian too.
Posts: 432

Original Poster
Blog Entries: 1

Rep: Reputation: 41
Generally, by the time I figure out its a bug and not just me, someone else has already complained about it and its been deemed a low priority because I'm like the second person to ever have the problem. I was kind hoping with the vast phenomenal cosmic powers of Linux, I could limit the amount of memory it is allowed to consume. It's a bit ridiculous that I have to wait nearly an hour and a half to use my laptop after I open a browser. Chromium wasn't much better. Iceweasel burns up the CPU which isn't as big of a deal on a desktop, but it sure is on a laptop when the TM kicks in and the system crawls.
 
Old 03-03-2015, 11:18 AM   #8
mpyusko
Member
 
Registered: Oct 2003
Location: Rochester, NY, USA
Distribution: Salckware ver 10.1 - 14.1, Debian too.
Posts: 432

Original Poster
Blog Entries: 1

Rep: Reputation: 41
Lightbulb

Well this isn't just a Debian Jessie thing I guess. If you take a look at this screen cap, it's 4.5GB on Slackware 14.1.

Code:
bash-4.2$ top -bn1 |grep chrome
28287 mpyusko   20   0  784m  73m  11m S    2  0.9   3:32.81 chrome                                                                           
 1843 mpyusko   20   0  409m  15m 6624 S    0  0.2   1:34.39 chrome                                                                           
 2104 mpyusko   20   0  301m 1576 1576 S    0  0.0   0:00.02 chrome                                                                           
 2201 mpyusko   20   0     0    0    0 Z    0  0.0   0:00.00 chrome-sandbox <defunct>                                                         
 5073 mpyusko   20   0  301m 1592 1592 S    0  0.0   0:00.01 chrome                                                                           
 5076 mpyusko   20   0     0    0    0 Z    0  0.0   0:00.00 chrome-sandbox <defunct>                                                         
 9461 mpyusko   20   0  301m 1592 1592 S    0  0.0   0:00.01 chrome                                                                           
 9464 mpyusko   20   0     0    0    0 Z    0  0.0   0:00.00 chrome-sandbox <defunct>                                                         
15090 mpyusko   20   0  790m  99m  48m S    0  1.2   0:12.41 chrome                                                                           
21041 mpyusko   20   0 6593m 4.1g  45m S    0 52.6  17:44.61 chrome                                                                           
21150 mpyusko   20   0  6500  388  308 S    0  0.0   0:00.00 chrome-sandbox                                                                   
21151 mpyusko   20   0  362m  12m 4348 S    0  0.2   0:00.10 chrome                                                                           
21198 mpyusko   20   0  6500  388  308 S    0  0.0   0:00.00 chrome-sandbox                                                                   
21588 mpyusko   20   0  370m 9228 1140 S    0  0.1   0:00.02 chrome                                                                           
21758 mpyusko   20   0  670m 165m  98m S    0  2.1   1:50.81 chrome                                                                           
21824 mpyusko   20   0  359m  12m  324 S    0  0.2   0:00.00 chrome                                                                           
21963 mpyusko   20   0  850m 134m  24m S    0  1.7   3:07.32 chrome                                                                           
21992 mpyusko   20   0  771m  75m  17m S    0  0.9   0:38.84 chrome                                                                           
21996 mpyusko   20   0  765m  90m  18m S    0  1.1   3:17.70 chrome                                                                           
22000 mpyusko   20   0  737m  44m  17m S    0  0.6   0:14.15 chrome                                                                           
25250 mpyusko   20   0  736m  35m  18m S    0  0.4   0:00.23 chrome                                                                           
bash-4.2$
Maybe this post belongs under a different area?

Thanks.
Attached Thumbnails
Click image for larger version

Name:	Chrome_Leak_Slack.jpg
Views:	34
Size:	110.0 KB
ID:	17724  
 
Old 03-06-2015, 01:02 PM   #9
mpyusko
Member
 
Registered: Oct 2003
Location: Rochester, NY, USA
Distribution: Salckware ver 10.1 - 14.1, Debian too.
Posts: 432

Original Poster
Blog Entries: 1

Rep: Reputation: 41
Here is an interesting bit of info. I just noticed that Facebook seems to be the culprit. My start pages were set to include FB. I have systematically removed pages form the startup list (I had 4 tabs open). As long as I don't browse to FB, Chrome and Chromium work properly and my laptop stays happy. I installed Google's lastest Chrome version as a troubleshooting method, despit the versioning differences, they both act the same in this case. Sooooo.... besides endlessly cursing FB, what can I do to restrict it's usage?
 
Old 03-30-2015, 10:25 AM   #10
mpyusko
Member
 
Registered: Oct 2003
Location: Rochester, NY, USA
Distribution: Salckware ver 10.1 - 14.1, Debian too.
Posts: 432

Original Poster
Blog Entries: 1

Rep: Reputation: 41
Exclamation

I've been using the chrome-beta branch in the hopes the 'bug' is fixed in newr versions. Honestly, I've been avoiding using chrome all together in recent weeks, giving Arora a try. Decent browser, but not very SSL friendly as it seems to be missing a lot of root certificates. Back to Chrome...

Code:
mpyusko@hal9000:/$ time ./opt/google/chrome-beta/google-chrome-beta
Failed to create secure directory (/run/user/1000/pulse): Permission denied
[32313:32313:0330/104747:ERROR:url_pattern_set.cc(240)] Invalid url pattern: chrome://print/*
Failed to create secure directory (/run/user/1000/pulse): Permission denied
Failed to create secure directory (/run/user/1000/pulse): Permission denied
Failed to create secure directory (/run/user/1000/pulse): Permission denied
[WARNING:flash/platform/pepper/pep_module.cpp(63)] SANDBOXED
[32313:32734:0330/104956:ERROR:get_updates_processor.cc(240)] PostClientToServerMessage() failed during GetUpdates
[32313:32734:0330/105008:ERROR:get_updates_processor.cc(240)] PostClientToServerMessage() failed during GetUpdates                                                                                                              
[32313:32513:0330/105750:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105750:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105751:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105751:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105751:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105751:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105758:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105758:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105758:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105758:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105759:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
[32313:32513:0330/105759:ERROR:media_stream_dispatcher_host.cc(229)] MSDH: Renderer requested a URL it's not allowed to use.
^CTerminated

real    15m48.735s
user    4m41.804s
sys     0m21.504s
mpyusko@hal9000:/$
I'd like to point out is took 9 minutes to switch back to the console window so I could kill the browser. Just before I killed it....

Code:
mpyusko@hal9000:/$ top -bn1 |grep chrome
 1499 mpyusko   20   0 1596644 544864   9676 S   0.0  6.8   1:44.66 chrome
 7368 mpyusko   20   0  971240 254048  20900 S   0.0  3.2   2:35.48 chrome
30806 mpyusko   20   0  917476 209212  19372 S   0.0  2.6   0:10.21 chrome
32313 mpyusko   20   0 7146108 5.123g  16012 D   0.0 66.7   4:57.54 chrome
32369 mpyusko   20   0  357172   7300   6312 S   0.0  0.1   0:00.04 chrome
32406 mpyusko   20   0  365368   3632   2588 S   0.0  0.0   0:00.02 chrome
32516 mpyusko   20   0  595148 153592  66032 S   0.0  1.9   0:24.04 chrome
32522 mpyusko   20   0  365264   3860   3700 S   0.0  0.0   0:00.00 chrome
32628 mpyusko   20   0  952144 117444  11164 S   0.0  1.5   0:44.85 chrome
32632 mpyusko   20   0  787412  35560  10004 S   0.0  0.4   0:04.17 chrome
32636 mpyusko   20   0  788928  20400   9208 S   0.0  0.3   0:16.26 chrome
32640 mpyusko   20   0  760332  12168   7804 S   0.0  0.2   0:00.71 chrome
32644 mpyusko   20   0  826172  41960  10292 S   0.0  0.5   0:02.72 chrome
mpyusko@hal9000:/$ killall chrome
mpyusko@hal9000:/$ killall chrome
mpyusko@hal9000:/$ killall chrome
chrome: no process found
mpyusko@hal9000:/$
 
Old 04-16-2015, 04:10 PM   #11
oneeyed
LQ Newbie
 
Registered: Apr 2015
Posts: 1

Rep: Reputation: Disabled
Quote:
Originally Posted by mpyusko View Post
Here is an interesting bit of info. I just noticed that Facebook seems to be the culprit. My start pages were set to include FB. I have systematically removed pages form the startup list (I had 4 tabs open). As long as I don't browse to FB, Chrome and Chromium work properly and my laptop stays happy. I installed Google's lastest Chrome version as a troubleshooting method, despit the versioning differences, they both act the same in this case. Sooooo.... besides endlessly cursing FB, what can I do to restrict it's usage?
I'm also using Chrome (Version 42.0.2311.90 64-bit) and there are multiple things that can eat up your memory unnecessarily.

* Extensions. You already noted that it seems not to be the cause of your problems, but they usually are in most cases. Unstability, and tab crashing too... My advice : limit yourself to only a few especially if they interact with the pages since memory can quickly increase with each tab (Ad-blockers are notable for that).

* Plugins. Another likely culprit, you should disable them by default or use the play to click feature.

* Images. This is probably the cause of your problems. From experience, I know that animated GIFs for example eat up memory seemingly without ever stopping. There's no good solution to this, Google has always refused to even provide the option to disable animation in its API so extensions doing it work poorly. My advice : avoid websites using them if you can, and do close their tabs quickly if you cannot.

* Poorly scripted websites. Javascript in some cases when badly programmed can lead to lag and memory problems too. My advice : use a NoScript equivalent, the only reliable extension I've seen on Chrome doing that is uMatrix.

Other tips to reduce memory usage although if there is a leak, it only delays the problem :
* In Settings : uncheck "Use hardware acceleration when available"
* In Settings : uncheck "Continue running background apps when Google Chrome is closed"
* Add --process-per-site to your lancher's command line (http://www.chromium.org/developers/d...ocess_per_Site)

Last edited by oneeyed; 04-16-2015 at 04:35 PM.
 
  


Reply

Tags
chrome, chromium, debian jessie, memoryleak



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Debian's new Art Theme (Jessie aka Debian 8.x). jens Debian 2 11-11-2014 02:48 AM
google chrome asks for login keyring -- jessie, xfce radiodee1 Debian 5 06-28-2014 12:17 PM
[SOLVED] Memory leak: How risky not to free allocated memory. kaz2100 Linux - General 1 12-24-2008 12:00 AM
Inactive memory issue, Freebsd (memory leak?) JasperB *BSD 7 08-12-2008 03:19 AM
Memory Leak when using memory debugging C program on SuSE SLES8 babalina Linux - Distributions 0 10-06-2003 09:39 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 02:28 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration