Announcement

Collapse
No announcement yet.

Plasmashell memory leak

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • GreyGeek
    replied
    Originally posted by jpeg729 View Post
    I got home today to find plasmashell using 5.5Gb swap and 2.3Gb ram on Kubuntu 18.04. WHY?

    Other threads suggest that certain widgets leak memory, now I do have a custom layout - a single panel on the left hand side, so that could be a factor. So I am going to have to remove them one at a time until I figure out which one is eating my ram. As a long-time linux user this is seriously disheartening. Why can't plasmashell monitor and limit the memory usage of its widgets? Why does the end user have to debug this largely on their own?

    Influential Linux nerds recommended KDE Plasma to me as being a light-weight stable functional desktop environment, but I find it to be over-complicated (it took me over half an hour to find the only way to remove a widget from a panel, why isn't it an option in the right-click menu?), buggy (I have to restart kwin every other day because the entire desktop freezes up) and way to greedy in the memory department.

    Is there any hope or should I install Unity which has the reputation of using rather a lot of ram from the get-go, but which is as stable as a rock?
    With absolutely no info to go on it is impossible to say what your problems are. The "Influential Linux nerds"? I agree with them 100%. Kubuntu 18.04 has been and is as stable as a rock since I installed it right after it went gold. I'm running three internal HDs with 16GB of RAM, an i7 CPU and an NVidia GT 650M GPU that is not settable in the BIOS as the primary but behaves as the primary because of nvidia-390, and runs faultlessly everything I throw at it. BTW, I'm running sddm. (Simple Desktop Display Manager). Here is my kwin usage:
    Code:
    Process 1274 - kwin_x11
    
    Summary
    
    The process kwin_x11 (with pid 1274) is using approximately 64.9 MB of memory.
    It is using 53.6 MB privately, and a further 65.4 MB that is, or could be, shared with other programs.
    Dividing up the shared memory between all the processes sharing that memory we get a reduced shared memory usage of 11.3 MB. Adding that to the private usage, we get the above mentioned total memory footprint of 64.9 MB.
    Library Usage
    
    The memory usage of a process is found by adding up the memory usage of each of its libraries, 
    plus the process's own heap, stack and any other mappings, plus the stack of its 5 threads. 
    Private
    more
    24300 KB    [heap]
    16612 KB    /dev/nvidiactl
    4176 KB    /usr/lib/x86_64-linux-gnu/libnvidia-glcore.so.390.48
    2732 KB    /usr/lib/x86_64-linux-gnu/libkwin.so.5.12.6
    1028 KB    /usr/lib/x86_64-linux-gnu/libkwin4_effect_builtins.so.1.0.0
    Shared
    more
    10740 KB    /usr/lib/x86_64-linux-gnu/libnvidia-glcore.so.390.48
    4472 KB    /usr/lib/x86_64-linux-gnu/libQt5Gui.so.5.9.5
    4008 KB    /usr/lib/x86_64-linux-gnu/libQt5Core.so.5.9.5
    3376 KB    /usr/lib/x86_64-linux-gnu/libQt5Qml.so.5.9.5
    2852 KB    /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5.9.5
    ...
    [SIZE=3][B]AND, MY Plasmashell[/B][/SIZE]
    Process 1278 - plasmashell
    
    Summary
    
    The process plasmashell (with pid 1278) is using approximately 259.2 MB of memory.
    It is using 242.4 MB privately, and a further 86.0 MB that is, or could be, shared with other programs.
    Dividing up the shared memory between all the processes sharing that memory we get a reduced shared memory usage of 16.8 MB. Adding that to the private usage, we get the above mentioned total memory footprint of 259.2 MB.
    Library Usage
    
    The memory usage of a process is found by adding up the memory usage of each of its libraries, plus the process's own heap, stack and any other mappings, plus the stack of its 17 threads. 
    Private
    more
    149756 KB    [heap]
    69508 KB    /dev/nvidiactl
    2672 KB    /usr/lib/x86_64-linux-gnu/libQt5XmlPatterns.so.5.9.5
    2036 KB    /usr/lib/x86_64-linux-gnu/libnvidia-glcore.so.390.48
    1668 KB    /home/jerry/.cache/plasma_theme_default_v5.30.kcache
    Shared
    more
    10584 KB    /usr/lib/x86_64-linux-gnu/libnvidia-glcore.so.390.48
    4696 KB    /usr/lib/x86_64-linux-gnu/libQt5Gui.so.5.9.5
    4360 KB    /usr/lib/x86_64-linux-gnu/libQt5Core.so.5.9.5
    3548 KB    /usr/lib/x86_64-linux-gnu/libQt5Qml.so.5.9.5
    3356 KB    /usr/lib/x86_64-linux-gnu/libQt5Quick.so.5.9.5

    As far as your suggestion that plasma developers "monitor and limit the memory usage of its widgets" ... that would be impractical if not impossible. How is a plasma developer supposed to know what the widget developer's intentions are with regard to memory usage? Some widget use a lot of memory and some do not. The KDE dev crew is not responsible for what widget developers do or don't do.

    It could be that 5.5GB of swap and 2.5GB of RAM is normal.
    Last edited by GreyGeek; Aug 23, 2018, 10:18 PM.

    Leave a comment:


  • Snowhog
    replied
    Originally posted by jpeg729 View Post
    I got home today to find plasmashell using 5.5Gb swap and 2.3Gb ram on Kubuntu 18.04. WHY?
    You aren't giving us much; heck, you aren't giving us anything; to go on. Are you leaving your PC on 24/7? What do you have running? What applications/widgets have you installed? What are your PC specs?

    Leave a comment:


  • jpeg729
    replied
    I got home today to find plasmashell using 5.5Gb swap and 2.3Gb ram on Kubuntu 18.04. WHY?

    Other threads suggest that certain widgets leak memory, now I do have a custom layout - a single panel on the left hand side, so that could be a factor. So I am going to have to remove them one at a time until I figure out which one is eating my ram. As a long-time linux user this is seriously disheartening. Why can't plasmashell monitor and limit the memory usage of its widgets? Why does the end user have to debug this largely on their own?

    Influential Linux nerds recommended KDE Plasma to me as being a light-weight stable functional desktop environment, but I find it to be over-complicated (it took me over half an hour to find the only way to remove a widget from a panel, why isn't it an option in the right-click menu?), buggy (I have to restart kwin every other day because the entire desktop freezes up) and way to greedy in the memory department.

    Is there any hope or should I install Unity which has the reputation of using rather a lot of ram from the get-go, but which is as stable as a rock?

    Leave a comment:


  • GreyGeek
    replied
    That probably explains why your memory use is greater!

    Leave a comment:


  • bschelst
    replied
    16Gb over here

    Leave a comment:


  • GreyGeek
    replied
    I have only 6GB of RAM. Do you have more?

    Leave a comment:


  • bschelst
    replied
    mine is even bigger...

    ptime;ps -u $USER -wo rss=,comm= --sort -rss | while read -r rss comm ; do echo $((rss/1024))"MB -" $comm; done && free -m
    20:06:35 up 7:30, 3 users, load average: 1,02, 0,91, 0,90
    3112MB - plasmashell
    713MB - akonadi_ews_res
    629MB - chrome
    532MB - TeamViewer
    408MB - chrome
    402MB - mysqld
    383MB - kmail
    368MB - chrome
    364MB - chrome

    Leave a comment:


  • GreyGeek
    replied
    Originally posted by chimak111 View Post
    Code:
    $ ps -u $USER -wo rss=,comm= --sort -rss | while read -r rss comm ; do echo $((rss/1024))"MB -" $comm; done && free -m
    Could you please explain ^^^

    I've usually just looked at free -m. Understanding RAM usage in Linux can get pretty difficult for us non-technical users: https://www.linuxatemyram.com/
    It's output is a listing of the total RAM used for each running process, and totals for each of the parts RAM is divided into. For a complete listing of possible command sequences see "man ps". It is a lot easier to get totals this way rather than using a calculator on ksysguard's output and trying to total them manually.
    Code:
    :~$ ps -u $USER -wo rss=,comm= --sort -rss | while read -r rss comm ; do echo $((rss/1024))"MB -" $comm; done && free -m
    319MB - plasmashell
    301MB - firefox
    199MB - Web Content
    103MB - kwin_x11
    84MB - Web Content
    78MB - krunner
    63MB - kgpg
    62MB - konsole
    61MB - hp-systray
    60MB - blueman-applet
    58MB - evolution-calen
    55MB - kded5
    52MB - evolution-alarm
    52MB - klauncher
    51MB - ksmserver
    50MB - kdeconnectd
    48MB - evolution-calen
    48MB - evolution-calen
    46MB - polkit-kde-auth
    45MB - kwalletd5
    44MB - kaccess
    43MB - org_kde_powerde
    42MB - kglobalaccel5
    32MB - kactivitymanage
    27MB - kuiserver
    27MB - gmenudbusmenupr
    27MB - xembedsniproxy
    25MB - distro-release-
    24MB - kscreen_backend
    24MB - hp-systray
    24MB - kio_http_cache_
    23MB - evolution-sourc
    22MB - kdeinit5
    18MB - evolution-addre
    18MB - evolution-addre
    16MB - hp-systray
    11MB - pulseaudio
    9MB - obexd
    7MB - gnome-keyring-d
    6MB - kwrapper5
    6MB - gnome-keyring-d
    6MB - at-spi2-registr
    6MB - gvfsd
    5MB - gconfd-2
    5MB - bash
    5MB - at-spi-bus-laun
    5MB - bash
    4MB - systemd
    4MB - dconf-service
    4MB - dbus-daemon
    4MB - gconf-helper
    3MB - dbus-daemon
    3MB - ps
    2MB - dbus-launch
    2MB - (sd-pam)
    1MB - ksysguardd
    1MB - bash
    1MB - startkde
    0MB - gpg-agent
    0MB - ssh-agent
    0MB - start_kdeinit
                  total        used        free      shared  buff/cache   available
    Mem:           5801        1094        2440          56        2266        4290
    Swap:             0           0           0

    Leave a comment:


  • pemartins
    replied
    @chimak111 thank you so much for the info, I really hope that link about the disk cache on ram is the explanation. Stuff like a 1 GB virus running on the background crossed my mind...

    I'd love to be able to explain that command but unfortunately is most probable that we see Trump and Hillary dancing salsa together before I can understand what's on it It's a copy and paste from somewhere made some time ago, all I recall is that the command intents to display the ram use per application in the user session.

    Leave a comment:


  • chimak111
    replied
    Code:
    $ ps -u $USER -wo rss=,comm= --sort -rss | while read -r rss comm ; do echo $((rss/1024))"MB -" $comm; done && free -m
    Could you please explain ^^^

    I've usually just looked at free -m. Understanding RAM usage in Linux can get pretty difficult for us non-technical users: https://www.linuxatemyram.com/

    Leave a comment:


  • pemartins
    replied
    The math is not right in my ram usage, if I do a total on all processes shown it should perhaps return a sum of about 600 MB or so; but as it shows in the printscreen, how can it be taking 1.6 GB of ram? What is using the extra 1 GB of ram not shown anywhere?



    It just does not add up...

    edit:
    Code:
    $ ps -u $USER -wo rss=,comm= --sort -rss | while read -r rss comm ; do echo $((rss/1024))"MB -" $comm; done && free -m
    265MB - plasmashell
    80MB - kded5
    73MB - konsole
    56MB - kwin_x11
    27MB - krunner
    27MB - ksmserver
    24MB - http.so
    24MB - http.so
    22MB - firetools
    15MB - kactivitymanage
    15MB - klauncher
    11MB - kdeconnectd
    10MB - org_kde_powerde
    10MB - python
    10MB - polkit-kde-auth
    10MB - kglobalaccel5
    9MB - kwalletd5
    9MB - kaccess
    9MB - kuiserver5
    9MB - pulseaudio
    6MB - kdeinit5
    5MB - xembedsniproxy
    5MB - kscreen_backend
    4MB - bash
    3MB - xbindkeys
    3MB - kio_http_cache_
    3MB - ps
    2MB - dbus-daemon
    2MB - at-spi2-registr
    2MB - gvfsd
    2MB - redshift
    2MB - systemd
    2MB - at-spi-bus-laun
    2MB - (sd-pam)
    2MB - gconfd-2
    1MB - dconf-service
    1MB - bash
    1MB - dbus-daemon
    1MB - ksysguardd
    0MB - gconf-helper
    0MB - startkde
    0MB - kwrapper5
    0MB - ssh-agent
    0MB - start_kdeinit
                 total        used        free      shared  buff/cache   available
    Mem:           3528        1649        1296           3         583        1654
    Swap:          3672           2        3670
    Last edited by pemartins; Jun 14, 2018, 08:48 PM.

    Leave a comment:


  • GreyGeek
    replied
    You can use ksysguard (K System Monitor) and sort by %CPU usage or total memory, or run top in a Konsole, to see which process is using the most memory or CPU. If you set ksysguard to the tree display mode then you can follow a process down the tree to locate the guilty party (if it is in a treed process).

    Leave a comment:


  • pemartins
    replied
    I really can't tell. I have file search disabled, also unchecked search folder updater from autostart, both are off since I installed Kubuntu. But I do not know if there are other indexing services running like updatedb or something similar, nor do I know if they are stored at plasmashell.

    Leave a comment:


  • GreyGeek
    replied
    Was it "abnormal" activity, or normal indexing?

    Leave a comment:


  • pemartins
    replied
    I just remembered that yesterday I also did a lot of moving and deleting files on Dolphin. Usually when I do that and when a lot of files (and big amount of data) are moved or deleted, I notice that the panel hangs for a bit (noticed once that the clock was delayed a couple of minutes) after the action is done; then I get the activity notification of files being moved, but actually the job is already done and nothing is being moved and I have to close (press stop on the icon in the notifications) the notification because it only shows a transfer but no file names are displayed.

    Today I've been using the pc normally and plasmashell remains as usual without signs of any memory leak. So I'll mark this one as solved since the abnormal activity seems to be what caused the memory leak and it's hard to reproduce the steps in order to try to replicate it.

    Leave a comment:

Users Viewing This Topic

Collapse

There are 0 users viewing this topic.

Working...
X