0

I found that whenever I leave my laptop idle for a while (no suspend because of Caffeine)it gets stuck and I need to force reboot the system by the power button. I tried disabling all the startup applications, disabling and even uninstalling the extensions which appear on syslog, etc. I enabled a system monitor extension and I found whenever I leave the system idle, RAM usage is getting higher until everything gets stuck. So, before I lose control of everything I used system monitor and found that Gnome-shell is using 2.3GB RAM! I restarted the shell (alt-F2 then r) and the RAM usage reduced down to 237MB. using tail -f /var/log/syslog gives me errors like this:

gnome-shell[4646]: #0   5572a9982f20 i resource:///org/gnome/shell/ui/dateMenu.js

and using pmap pgrep gnome-shell | grep -v -i deleted > /tmp/gnome-pmap1.dump will give me errors like this related to the calendar:

2057:   /usr/libexec/gnome-shell-calendar-server

Using memstat (mentioned here I found that the problem is mostly made by chrome_crashpad_handler and when I kill this process everything is fine. but I dont know how to disable or totally remove it, and I dont know what it is at all!

Before-after picture is attached.

P.S. Ubuntu 22.10, Gnome 43.1, X11, on a Dell thinkpad Inspiron 7348: 4GB RAM, Core i5 CPU, Intel Graphics

before restarting shell

after

Masoud Borbor
  • 621
  • 2
  • 7
  • 17
  • 3
    Does this answer your question? [Gnome-shell is taking a lot of ram](https://askubuntu.com/questions/1266498/gnome-shell-is-taking-a-lot-of-ram) – Maximilian Ballard Feb 22 '23 at 17:41
  • 1
    @MaximilianBallard nope. even disabling all extensions doesnt fix the problem. but reviewing the logs makes me beleive it is somehow related to the gnome calendar. I will edit my question to add the notes – Masoud Borbor Feb 22 '23 at 19:36
  • Run `top` or `htop` in terminal and sort by memory usage, and you might also want to set it to tree mode which will indent child processes making it easier to view. The subprocesses of gnome-shell should be shown, if not then it could be a memory leak. In that situation you might want to look at [this](https://askubuntu.com/questions/152716/how-to-detect-a-memory-leak) question. – Maximilian Ballard Feb 22 '23 at 22:36
  • 2
    Does this answer your question? [How to detect a memory leak?](https://askubuntu.com/questions/152716/how-to-detect-a-memory-leak) – karel Feb 23 '23 at 03:39
  • @karel I couldn't understand how to use memprof but using memstat I found that the problem is mostly made by chrome_crashpad_handler and when I kill this process everything is fine. but I don`t know how to disable or totally remove it – Masoud Borbor Feb 23 '23 at 21:34
  • @MasoudBorbor I found a question on Ask Ubuntu about this topic: [Ubuntu 21.10 Chrome won't open](https://askubuntu.com/questions/1403003/ubuntu-21-10-chrome-wont-open). An answer to this question said that deleting `~/.config/google-chrome` with `rm -rf ~/.config/google-chrome` worked. – karel Feb 23 '23 at 22:02

1 Answers1

0

After disabling everything suspicious, I still had the issue but before getting ram usage too much that I can't check anything, I used tail -f /var/log/syslog and faced too many errors like this:

Feb 26 20:46:46 thinkpad-lap gnome-shell[2087]: #0   55c0fea1a048 i   resource:///org/gnome/shell/ui/dateMenu.js:370 (34058da3b830 @ 55)

Feb 26 20:46:45 thinkpad-lap gnome-shell[2087]: Object .Gjs_ui_dateMenu_EventsSection (0x55c0f7150cd0), has been already disposed — impossible to set any property on it. This might be caused by the object having been destroyed from C code using something such as destroy(), dispose(), or remove() vfuncs.

Feb 26 20:46:46 thinkpad-lap gnome-shell[2087]: == Stack trace for context 0x55c0f38d1190 ==

there was a lot of errors and things like these, so I started to search one by one, and found this bug and solution

after backing up my clock setting:

dbus-launch dconf dump / > gnome-desktop.dconf

I did reset all clocks settings with:

dbus-launch dconf reset -f /org/gnome/clocks/

dbus-launch dconf reset -f /org/gnome/shell/world-clocks/

and it relieved me of an old disgusting problem.

Masoud Borbor
  • 621
  • 2
  • 7
  • 17
  • now I have only this error in log (which is not a bothering problem yet, just eager to know about it): gnome-shell[2087]: Ignoring length property that isn't a number at line 1, col 67 – Masoud Borbor Feb 26 '23 at 18:05
  • You may want to come a bug report so that it gets fixed for Ubuntu. – user68186 Feb 26 '23 at 18:08
  • [Better use](https://askubuntu.com/questions/249887/gconf-dconf-gsettings-and-the-relationship-between-them) `gsettings reset`/`reset-recursively` – Pablo Bianchi Feb 27 '23 at 20:50