21

I recently reinstalled ubuntu (about a month ago) and gnome-shell usually uses about 150-300 MB ram but suddenly from the last 2 days, gnome-shell is taking a lot of ram(Even jumps up to 2GB). I only have 4GB ram, so this is a big issue for me.

Screenshot

I can fix this by restarting gnome-shell but even after 10 minutes of use, I have to restart it again. Is there any way to fix/avoid this?

Note: I'm on ubuntu 20.04

Heisenberg
  • 1,626
  • 4
  • 19
  • 34
  • 2
    Do you have extension active? If so turn them off and switch them on one by one and see if any of them are the cause. If so report it :-) Also worth a shot: switch to another graphics card driver and see if that fixes it. – Rinzwind Aug 12 '20 at 07:56
  • My computer has 32GB of RAM. but gnome-shell with only the default extensions installed uses only 326MB RAM. I think your Ubuntu 20.04 has a software problem which is causing your gnome-shell to use too much RAM. – karel Aug 12 '20 at 08:04
  • 1
    You can file a bug report on Gnome or Ubuntu bugzilla and see this guide guide.But if you're curious to debug that yourself for now,you can run the command pmap `pgrep gnome-shell` | grep -v -i deleted > /tmp/gnome-pmap1.dump when you first starts the gnome-shell, then run that again after some time when the problem arises this time to the file gnome-pmap2.dump. – Parsa Mousavi Aug 12 '20 at 08:46
  • 1
    Then run diff -y --suppress-common-lines those-two-files.Then see what makes the difference.That might help you to file a decent bug report that helps the developers to figure out the problem more easily.But that's not needed when you use the ubuntu-bug program as mentioned in the above guide,because it collects relevant information automatically.Hope it helps :) – Parsa Mousavi Aug 12 '20 at 08:46
  • 2
    @Rinzwind I tried turning off all the extensions, the problem was didn't existed since, maybe it's an extension fault, I'll get back to you. – Heisenberg Aug 12 '20 at 09:06
  • 1
    @Heisenberg that is almost always the cause if it is software related ;-) – Rinzwind Aug 12 '20 at 09:44
  • @Rinzwind Thanks – Heisenberg Aug 12 '20 at 09:45
  • @Heisenberg Please post the fact that disabling all extensions solved the problem as an answer below. If you can figure out which of the extensions caused the problem in the first place, you can always improve the answer in the future. – pomsky Aug 12 '20 at 11:00
  • Can @Rinzwind post the answer since he was one who suggested disabling the extensions? – Heisenberg Aug 12 '20 at 11:03
  • @Heisenberg sure :) but I do not really need the rep. It is perfectly fine by me for you to make one :) – Rinzwind Aug 12 '20 at 13:05
  • @Rinzwind I didn't ckecked your reputation but as you were the one who suggested the answer it's yours. – Heisenberg Aug 12 '20 at 13:22

3 Answers3

13

To disable an extension, first get a list with

gnome-extensions list

To list only enabled extensions, use

gnome-extensions list --enabled

To disable an enabled extension, use e.g.

gnome-extensions disable ubuntu-appindicators@ubuntu.com
  • 2
    gnome-extensions: command not found on Ubuntu 18.04 – Nfettinger Sep 15 '21 at 15:50
  • 3
    worked for me 20.04, but is there a way to find out how much memory those are taking. it seems a bizarre way to implement software if one cannot get that information but have to do a trial and error enabling/disabling and still not have a name for the corrupting process per ps command. – pierrely Dec 29 '21 at 21:15
9

General methods to investigate issues with gnome shell:

  1. Disable all extensions and check if that solves it.
  2. If so enable 1 extension at a time and find the culprit.
  3. If you find a culprit visit the extensions page and file a bug report if there is not one filed yet.

If 1. is not the answer switch the video card driver to another and check if that fixes it.

Rinzwind
  • 299,756
0

This is an old thread but for what it's worth, I think I've solved a similar problem by installing Gnome Tweaks, then unchecking the visual effects. CPU and memory usage has reduced, and does not appear to be progressively accumulating, as happened before. Ubuntu 18.04.

Ranger
  • 23