gnome-shell icon indicating copy to clipboard operation
gnome-shell copied to clipboard

Memory leak gnome-shell

Open Guyv-dev opened this issue 2 years ago • 8 comments

Distribution (run cat /etc/os-release): NAME="Pop!_OS" VERSION="21.10" ID=pop ID_LIKE="ubuntu debian" PRETTY_NAME="Pop!_OS 21.10" VERSION_ID="21.10" HOME_URL="https://pop.system76.com" SUPPORT_URL="https://support.system76.com" BUG_REPORT_URL="https://github.com/pop-os/pop/issues" PRIVACY_POLICY_URL="https://system76.com/privacy" VERSION_CODENAME=impish UBUNTU_CODENAME=impish LOGO=distributor-logo-pop-os

Issue/Bug Description:

I experience extensive ram usage from gnome-shell (GNOME Shell 40.5). I used heap track without any user extension enabled - logs attached. The only extension that was left enabled (Cosmic Dock - DISABLED):

  1. Cosmic Workspaces
  2. Pop COSMIC
  3. Pop Shell
  4. Ubuntu Appindicators

2.4GB usage: leak2 leak


5.7GB usage:

leak57 leak571 leak572

Guyv-dev avatar Mar 27 '22 13:03 Guyv-dev

You'd have to build the gnome-shell package from source and install the dbgsym package to get the debug symbols that are missing.

git clone https://github.com/pop-os/gnome-shell
cd gnome-shell
git checkout master_impish
sudo apt build-dep gnome-shell
dpkg-buildpackage -b
sudo dpkg -i ../*gnome-shell*deb

But with 22.04 so close and that will be shipping with GNOME 42, there's a chance that the issue may be fixed in GNOME 42 already.

mmstick avatar Mar 27 '22 14:03 mmstick

I am still facing a memory leak (I upgraded to pop_os 22.04 with gnome 42). I tried to build gnome-shell just like you suggested, and I am getting an error when I run dpkg-buildpackage -b:

dpkg-checkbuilddeps: error: Unmet build dependencies: libgnome-bluetooth-dev (>= 3.9.0) libmutter-8-dev (>= 40.0)
dpkg-buildpackage: warning: build dependencies/conflicts unsatisfied; aborting
dpkg-buildpackage: warning: (Use -d flag to override.)

Guyv-dev avatar May 06 '22 09:05 Guyv-dev

sudo apt build-dep gnome-shell will install all development dependencies of gnome-shell.

mmstick avatar May 09 '22 10:05 mmstick

if I am not wrong, master_impish is gnome 40 (I am now on pop 22.04 with 42), so maybe it could explain why sudo apt build-dep gnome-shell doesn't install these dependencies (libmutter-8-dev - doesn't have release for 22.04).

i tried once again with master branch, now i get:

 signfile gnome-shell_42.0-2ubuntu2pop1_amd64.buildinfo
gpg: skipped "Michael Aaron Murphy <[email protected]>": No secret key
gpg: dpkg-sign.gQ9PR1Ct/gnome-shell_42.0-2ubuntu2pop1_amd64.buildinfo: clear-sign failed: No secret key

Guyv-dev avatar May 09 '22 11:05 Guyv-dev

GNOME 42 on 21.10 wouldn't be a supported configuration. Try 22.04

mmstick avatar May 09 '22 13:05 mmstick

I installed the built gnome, now what should i do? run valgrind / heaptrack ?

Guyv-dev avatar May 31 '22 18:05 Guyv-dev

Screenshot from 2022-06-12 16-24-44 Screenshot from 2022-06-12 16-24-31 Screenshot from 2022-06-12 16-24-00

Guyv-dev avatar Jun 12 '22 13:06 Guyv-dev

Are the screenshots help to identify the problem?

Guyv-dev avatar Jun 21 '22 19:06 Guyv-dev