View previous topic :: View next topic |
Author |
Message |
tkzv Tux's lil' helper
Joined: 22 Aug 2014 Posts: 83
|
Posted: Wed May 13, 2015 1:05 am Post subject: X Window consumes all memory |
|
|
Recently I started getting an odd problem. The computer would hang or reboot after a few weeks of uptime. The last 2 times I noticed that shortly before it /usr/bin/X would eat all available memory, which is 12-15 gigabytes.
Once I managed to start htop when the system got sluggish, but hasn't frozen yet, and saw who got all memory; the other time /var/log/kernel/current had a line: Code: | [kernel] Out of memory: Kill process 13179 (X) score 639 or sacrifice child |
What could be causing this? How do I stop it?
x11-base/xorg-server-1.17.1-r1 and before that 1.16.4
x11-base/xorg-drivers-1.17 and before that 1.16
x11-drivers/ati-drivers-15.1 and before that either 14.4_p1 or 14.12-r3
kernel 3.12.13 AMD64
KDE 4.14.3
emerge --info: http://pastebin.com/QurDT4C8
The only programs running at the moment when it happened were Firefox, Skype, Konsole, MC, and often qbittorrent. I use xrandr to rotate the image by 90 degrees when X Window starts. I have launched mplayer many times, but it wasn't necessarily working when the system crashed. |
|
Back to top |
|
|
Naib Watchman
Joined: 21 May 2004 Posts: 6051 Location: Removed by Neddy
|
Posted: Wed May 13, 2015 12:18 pm Post subject: |
|
|
my money would be on Skype... this has eaten all my RAM on the odd occasions _________________
Quote: | Removed by Chiitoo |
|
|
Back to top |
|
|
tkzv Tux's lil' helper
Joined: 22 Aug 2014 Posts: 83
|
Posted: Wed May 13, 2015 8:09 pm Post subject: |
|
|
Naib wrote: | my money would be on Skype... this has eaten all my RAM on the odd occasions |
I understand your desire to blame everything on Microsoft, but the time I started htop Skype occupied only 20-something megabytes, and it wasn't Skype that got OOM-killed.
Or can there be a situation when a bug in Skype causes memory leak in X? |
|
Back to top |
|
|
Naib Watchman
Joined: 21 May 2004 Posts: 6051 Location: Removed by Neddy
|
Posted: Wed May 13, 2015 8:13 pm Post subject: |
|
|
Looking over my post I don't recall mentioning Microsoft.
If fact post Microsoft buying Skype and releasing an update I had not experienced the same memory leak that ground my system to a halt a number of times _________________
Quote: | Removed by Chiitoo |
|
|
Back to top |
|
|
tkzv Tux's lil' helper
Joined: 22 Aug 2014 Posts: 83
|
Posted: Wed May 13, 2015 8:19 pm Post subject: |
|
|
Then it's not Skype. I'm using net-im/skype-4.3.0.37-r5
On another forum another user has had a similar trouble with X. When CPU load was high, X would start grabbing memory and actively using disk until it got OOM-killed. His troubles stopped after he reconfigured the kernel. Do you have any suggestions what to change in the kernel configuration? |
|
Back to top |
|
|
Naib Watchman
Joined: 21 May 2004 Posts: 6051 Location: Removed by Neddy
|
Posted: Wed May 13, 2015 10:30 pm Post subject: |
|
|
why can't it be that? there was nothing in recent patchnotes to say a memory leak was fixed. I was just informing you that I had issue with skype and memory leaks prior to MS purchase refuting your claim it was because it was microsoft
https://bugs.kde.org/show_bug.cgi?id=296473 _________________
Quote: | Removed by Chiitoo |
|
|
Back to top |
|
|
tkzv Tux's lil' helper
Joined: 22 Aug 2014 Posts: 83
|
Posted: Wed May 13, 2015 11:44 pm Post subject: |
|
|
Quote: | why can't it be that? |
If skype eats 16G of RAM, what would be auto-killed? skype or X?
Quote: | https://bugs.kde.org/show_bug.cgi?id=296473 |
How does htop determine memory associated with X? does it include plasma-desktop, if plasma-desktop has its separate lines? |
|
Back to top |
|
|
franzf Advocate
Joined: 29 Mar 2005 Posts: 4565
|
Posted: Thu May 14, 2015 6:14 am Post subject: |
|
|
Could you install and run xrestop and look (and post ) the top consumers? |
|
Back to top |
|
|
tkzv Tux's lil' helper
Joined: 22 Aug 2014 Posts: 83
|
Posted: Sat May 23, 2015 11:24 pm Post subject: |
|
|
franzf wrote: | Could you install and run xrestop and look (and post ) the top consumers? |
It took me over a week until I felt the symptoms again.
xrestop:
Code: |
res-base Wins GCs Fnts Pxms Misc Pxm mem Other Total PID Identifier
1600000 38 9 0 28 239 41634K 6K 41641K 3326 kwin
2a00000 13 12 0 30 188 30890K 4K 30895K 3546 skype
0000000 2 0 2 0 120 19003K 4K 19007K ? <unknown>
1000000 10 10 0 24 82 18149K 2K 18151K 3368 oleg : xrestop �~@~T Konsole
1c00000 23 23 0 87 156 16005K 4K 16009K 3340 plasma-desktop
3000000 39 44 1 109 302 15141K 10K 15151K 16877 Gentoo Forums :: Post a reply - Moz
2400000 4 4 0 7 39 14076K 1K 14077K 3671 GoldenDict
1a00000 7 3 0 91 126 8049K 3K 8052K 3337 krunner
0c00000 4 4 0 4 15 64K 552B 64K 3329 kactivitymanagerd
0e00000 3 3 0 2 363 32K 8K 40K 3319 kglobalaccel
0a00000 4 3 0 2 13 32K 480B 32K 3316 kded4
2000000 3 3 0 2 11 32K 408B 32K 3365 polkit-kde-authentication-agent-1
1800000 3 3 0 2 11 32K 408B 32K 3364 knotify4
1200000 4 3 0 1 11 256B 432B 688B 3324 Qt-subapplication
1e00000 3 3 0 1 11 256B 408B 664B 3351 kuiserver
2e00000 1 1 0 0 0 0B 48B 48B ? <unknown>
2600000 1 1 0 0 0 0B 48B 48B ? xrestop
0800000 1 1 0 0 0 0B 48B 48B ? <unknown>
0400000 1 1 0 0 0 0B 48B 48B ? <unknown>
2c00000 0 1 0 0 0 0B 24B 24B ? <unknown>
2200000 0 1 0 0 0 0B 24B 24B ? <unknown>
1400000 0 1 0 0 0 0B 24B 24B ? <unknown>
0600000 0 1 0 0 0 0B 24B 24B ? <unknown>
0200000 0 1 0 0 0 0B 24B 24B ? <unknown>
|
When I ran another Firefox profile, with more open tabs, it consumed around 150 000 K in "Pxm mem". I had to stop it, because the system was starting to get sluggish. The one with only 6 tabs takes only 15 141K.
Top, sorted by "%MEM":
Code: |
top - 02:20:41 up 9 days, 3:21, 6 users, load average: 0,30, 0,13, 0,22
Tasks: 179 total, 1 running, 178 sleeping, 0 stopped, 0 zombie
%Cpu(s): 1,2 us, 0,6 sy, 0,0 ni, 98,2 id, 0,0 wa, 0,0 hi, 0,0 si, 0,0 st
KiB Mem: 16430856 total, 14016548 used, 2414308 free, 21304 buffers
KiB Swap: 0 total, 0 used, 0 free. 352852 cached Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
3264 root 20 0 12,257g 0,012t 308256 S 6,0 76,5 314:23.97 X
16877 oleg 20 0 956928 307784 53376 S 1,3 1,9 0:29.83 firefox
3523 oleg 20 0 225288 172624 472 S 0,0 1,1 0:37.41 mc
3546 oleg 20 0 579084 170536 32872 S 2,3 1,0 295:15.49 skype
3340 oleg 20 0 2990860 119608 22604 S 2,7 0,7 42:10.83 plasma-desktop
3326 oleg 20 0 2885224 71612 10560 S 1,7 0,4 33:36.41 kwin
3368 oleg 20 0 485440 67224 24528 S 1,3 0,4 30:19.81 konsole
3671 oleg 20 0 1837924 46616 17672 S 0,0 0,3 0:15.81 goldendict
3337 oleg 20 0 1622132 21772 1492 S 0,0 0,1 0:22.65 krunner
3319 oleg 20 0 320332 10028 1988 S 0,0 0,1 0:01.30 kglobalaccel
3316 oleg 20 0 335912 8616 1116 S 0,0 0,1 0:00.98 kded4
3324 oleg 20 0 404300 8500 1072 S 0,0 0,1 0:01.16 ksmserver
3313 oleg 20 0 254916 6272 704 S 0,0 0,0 0:00.07 kdeinit4
3314 oleg 20 0 257280 6224 728 S 0,0 0,0 0:00.03 klauncher
3364 oleg 20 0 272892 5996 1556 S 0,0 0,0 0:01.21 knotify4
3329 oleg 20 0 585808 5100 1212 S 0,0 0,0 0:01.71 kactivitymanage
3365 oleg 20 0 219752 4740 1104 S 0,0 0,0 0:01.07 polkit-kde-auth
3351 oleg 20 0 192516 4532 1184 S 0,0 0,0 0:00.96 kuiserver
3246 oleg 20 0 108308 4392 556 S 0,0 0,0 0:02.38 gdnc
16995 oleg 20 0 22836 1716 1092 R 0,3 0,0 0:00.14 top
3525 oleg 20 0 23208 1264 704 S 0,0 0,0 0:00.30 bash
3370 oleg 20 0 23408 1260 712 S 0,0 0,0 0:00.10 bash
16849 oleg 20 0 22728 1020 452 S 0,0 0,0 0:12.62 xrestop
3529 oleg 20 0 23200 800 152 S 0,0 0,0 0:00.31 bash
2273 root 20 0 39324 788 156 S 0,0 0,0 0:00.15 systemd-udevd
3307 oleg 20 0 17500 744 344 S 0,0 0,0 0:00.28 dbus-daemon
5341 root 20 0 23200 704 140 S 0,0 0,0 0:00.15 bash
3379 oleg 20 0 23200 688 136 S 0,0 0,0 0:00.10 bash
3247 oleg 20 0 23212 652 96 S 0,0 0,0 0:00.00 bash
5332 oleg 20 0 23084 616 100 S 0,0 0,0 0:00.09 bash
3229 root 20 0 64920 612 164 S 0,0 0,0 0:00.01 login
3541 oleg 20 0 23084 612 100 S 0,0 0,0 0:00.09 bash
3241 oleg 20 0 23080 528 60 S 0,0 0,0 0:00.09 bash
5338 root 20 0 46820 504 144 S 0,0 0,0 0:00.00 su
3306 oleg 20 0 24292 480 184 S 0,0 0,0 0:00.00 dbus-launch
5367 root 20 0 19132 428 96 S 0,0 0,0 0:00.00 vsftpd
3272 oleg 20 0 14532 420 136 S 0,0 0,0 0:00.00 startkde
3042 root 20 0 8840 308 136 S 0,0 0,0 0:00.02 metalog
3230 root 20 0 15388 292 136 S 0,0 0,0 0:00.00 agetty
3231 root 20 0 15388 292 136 S 0,0 0,0 0:00.00 agetty
3234 root 20 0 15388 292 136 S 0,0 0,0 0:00.00 agetty
3233 root 20 0 15388 288 136 S 0,0 0,0 0:00.00 agetty
3232 root 20 0 15388 284 136 S 0,0 0,0 0:00.00 agetty
3120 root 20 0 6464 272 68 S 0,0 0,0 0:00.97 dhcpcd
3081 at 20 0 16748 252 88 S 0,0 0,0 0:00.00 atd
3263 oleg 20 0 15872 244 92 S 0,0 0,0 0:00.00 xinit
1 root 20 0 4176 220 120 S 0,0 0,0 0:04.89 init
3044 root 20 0 8824 132 0 S 0,0 0,0 0:00.00 metalog
3002 root 20 0 7332 112 0 S 0,0 0,0 0:09.37 gpm
3323 oleg 20 0 4152 76 0 S 0,0 0,0 0:00.00 kwrapper4
2 root 20 0 0 0 0 S 0,0 0,0 0:00.02 kthreadd
3 root 20 0 0 0 0 S 0,0 0,0 0:00.28 ksoftirqd/0
5 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 kworker/0:0H
7 root rt 0 0 0 0 S 0,0 0,0 0:00.07 migration/0
8 root 20 0 0 0 0 S 0,0 0,0 0:00.00 rcu_bh
9 root 20 0 0 0 0 S 0,0 0,0 1:07.16 rcu_sched
10 root rt 0 0 0 0 S 0,0 0,0 0:00.07 migration/1
11 root 20 0 0 0 0 S 0,0 0,0 0:00.24 ksoftirqd/1
13 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 kworker/1:0H
14 root rt 0 0 0 0 S 0,0 0,0 0:00.06 migration/2
15 root 20 0 0 0 0 S 0,0 0,0 0:00.33 ksoftirqd/2
17 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 kworker/2:0H
18 root rt 0 0 0 0 S 0,0 0,0 0:00.06 migration/3
19 root 20 0 0 0 0 S 0,0 0,0 0:00.27 ksoftirqd/3
21 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 kworker/3:0H
22 root rt 0 0 0 0 S 0,0 0,0 0:00.06 migration/4
23 root 20 0 0 0 0 S 0,0 0,0 0:00.27 ksoftirqd/4
25 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 kworker/4:0H
26 root rt 0 0 0 0 S 0,0 0,0 0:00.10 migration/5
27 root 20 0 0 0 0 S 0,0 0,0 0:02.97 ksoftirqd/5
29 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 kworker/5:0H
30 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 khelper
31 root 20 0 0 0 0 S 0,0 0,0 0:00.00 kdevtmpfs
989 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 writeback
991 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 bioset
993 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 kblockd
1108 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 ata_sff
1118 root 20 0 0 0 0 S 0,0 0,0 0:00.03 khubd
1127 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 md
1142 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 cfg80211
1248 root 0 -20 0 0 0 S 0,0 0,0 0:00.00 rpciod
1274 root 20 0 0 0 0 S 0,0 0,0 0:00.25 khungtaskd
|
Output of "xrestop -b": http://pastebin.com/yr981m4i |
|
Back to top |
|
|
tkzv Tux's lil' helper
Joined: 22 Aug 2014 Posts: 83
|
Posted: Mon May 25, 2015 1:03 am Post subject: |
|
|
Opening more than 2 GPicView windows simultaneously also causes memory leaks in X. This one-liner eats about 770K per cycle (385K per window?):
Code: |
for f in {1..10000}; do echo $f; gpicview image1.jpg & gpicview image2.jpg & gpicview image3.jpg & gpicview image4.jpg & sleep 1; killall gpicview; done
|
I wonder if it's a coincidence that xrestop gives Pxm mem = 393K per gpicview instance. |
|
Back to top |
|
|
tkzv Tux's lil' helper
Joined: 22 Aug 2014 Posts: 83
|
Posted: Tue May 26, 2015 8:46 pm Post subject: |
|
|
Memory leaks stopped (or got very small) after I replaced closed driver with the free one. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|