The snap-store is using hundreds of MiBs of RAM.

Bug #1879137 reported by James
262
This bug affects 55 people
Affects Status Importance Assigned to Milestone
GNOME Software
New
Unknown
snap-store-desktop
Confirmed
Undecided
Unassigned
gnome-software (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

The snap-store process is intermittently using hundreds of megabytes of RAM. Is this normal? Is there a solution?

Ubuntu 20.04

Tags: memory
Revision history for this message
James (baker-james-jb) wrote :
Revision history for this message
giorgi shengelaia (g-shengelaia2001) wrote :

Same here on relatively fresh ubuntu 20.04 install.

Revision history for this message
John (john-mg-allen) wrote :

#metoo 400mb currently on a newish ubuntu 20.04 install. It's not even open...just sits in the background sucking down my ram.

James (baker-james-jb)
description: updated
Revision history for this message
Mike Leonis (mleonis) wrote :

I have also noticed this behavior.

Revision history for this message
Shinjan Saha (sahashinjan) wrote :

#MeToo, it happens for me as well. Currently it is taking up 250MB RAM while its not even open

Revision history for this message
Lisa Gentsch (polynomendivision) wrote :

Got the same here. snap-store sitting in the background and eating 200MB of RAM

Revision history for this message
Manuel Lañas (mlanas) wrote :

#MeToo, since I installed Ubuntu 20.04, snap-store process is taking even more than 300MB

Revision history for this message
John (john-mg-allen) wrote :

Just checked again, 475mb. This is getting an absolute joke and isn't on, why have they released ubuntu 20.04 with this RAM sucking monster? Not all of us are devs with 32GB machines, some of us are on laptops with 4GB/8GB and having a program/service doing absolute nothing sat in the background consuming 1/8th of available RAM is just a slap in the face.

Revision history for this message
Fabiano Silva (drhtcl) wrote :

Same here, 447Mb on a fresh ubuntu 20.04 install

Changed in snap-store:
status: New → Confirmed
Revision history for this message
Mantas Kriaučiūnas (mantas) wrote :

Snap-store on 20.04 uses more memory than gnome-shell and Xorg - about 30-25% more than original gnome-software 3.36 I just checked by installing with 'apt install gnome-software' !

Revision history for this message
gustav (gustavs) wrote :

Same here 352M on ubuntu 200.04 and it is not even open

Revision history for this message
Heraldo Madeira (heraldo-madeira) wrote :

Same problem here, 260M, with apparmor errors related to snap-store:

[Thu Jun 11 12:43:04 2020] audit: type=1400 audit(1591890185.710:1238): apparmor="DENIED" operation="open" profile="snap.snap-store.ubuntu-software" name="/var/lib/snapd/hostfs/usr/share/icons/Adwaita/scalable/categories/" pid=2785 comm="pool-org.gnome." requested_mask="r" denied_mask="r" fsuid=1002 ouid=0

Revision history for this message
Manish (manishmaharjan) wrote :

#metoo, It is using 288MB of my RAM memory when it is not even opened, but just running at the background.

Revision history for this message
Eduardo Santos (eduardoflsantos) wrote :

+1

255MB of RAM while it's not even open

Revision history for this message
Beloin Sena de Farias Rodrigues (beloin) wrote :

Me too almost 400MB

Revision history for this message
Doug (stingray74) wrote :

Fresh 20.04 install and mine is between 200 and 400 MB

Revision history for this message
Manoj Patel (mpatelpa) wrote :

snap-store is 430MB

Revision history for this message
Zbynek (ybznek) wrote :

Same problem on Xubuntu 20.04, using 825 MiB... There are some updates waiting to be installed.

Revision history for this message
Maxim Veksler (maxim-vekslers) wrote :

Top roller at 2.6%

Revision history for this message
Cecil Reed (reedce1) wrote :

Observed snap-store using over .5 GiB of ram

Revision history for this message
Richard Chamberlin (rjdchaim) wrote :

Also seeing this on a new (less than a week) install of 20.04. I run an older machine and this hogs my performance.

Revision history for this message
GrzesiekC (grzesiekc) wrote :

570 MiB here

Revision history for this message
Carlos Pita (carlosjosepita) wrote :

It doesn't seem intermittent to me. Isn't memory consumption always high (>300MB) for you?

Revision history for this message
Carlos Pita (carlosjosepita) wrote :

This probably has to be addressed upstream https://gitlab.gnome.org/GNOME/gnome-software/-/issues/942

Revision history for this message
Tryfon Farmakakis (farmakakistryfon) wrote :

Same here, 461MBs while running in the background on a relatively fresh, up-to-date Ubuntu 20.04.1 install. This is not OK.

Revision history for this message
Rado Smogura (rsmog) wrote :

I think:
1. Memory usage is too high when application is running.
2. Most important - the application stays in background after closing window and still consumes around 400MB of memory (this is a lot).

Revision history for this message
Bambu Fan (bambufan) wrote :

On my fresh Ubuntu 20.04LTS the snap store uses 1,1Gb of memory. I think that is insane and I will take action to disable or remove the program from my pc.

Théo (theo-thenault)
no longer affects: ubuntu
Revision history for this message
Simon B. (bemymonkey) wrote :

Still happening on a fully updated Ubuntu 20.04 LTS install.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in gnome-software (Ubuntu):
status: New → Confirmed
Paul White (paulw2u)
affects: ubuntu → gnome-software (Ubuntu)
Changed in gnome-software (Ubuntu):
status: New → Confirmed
Revision history for this message
tuca (cos-rj) wrote :

mee too 400mb

Revision history for this message
Dave Jones (waveform) wrote :

It appears to take 250MB resident (according to top) on my Raspberry Pi 400 even when the software is "closed". On a machine with 4GB, this is pretty significant. Even more so considering we now support the desktop on Pis with as little as 2GB of RAM.

Revision history for this message
ubuntu-user (katian) wrote (last edit ):

$ find /proc -maxdepth 2 -path "/proc/[0-9]*/status" -readable -exec awk -v FS=":" '{process[$1]=$2;sub(/^[ \t]+/,"",process[$1]);} END {if(process["VmSwap"] && process["VmSwap"] != "0 kB") printf "%10s %-30s %20s\n",process["Pid"],process["Name"],process["VmSwap"]}' '{}' \; | awk '{print $(NF-1),$0}' | sort -h | cut -d " " -f2-

snap-store eating my swap file

:(

Changed in gnome-software:
status: Unknown → New
Revision history for this message
John Pye (jdpipe) wrote :

I found that snap-store was consuming fully 1 GB of RAM on my system when I checked it just now. Such a huge memory use for something I *never* used. I would like to think that core elements of the a default Ubuntu system would be designed more carefully for low memory use.

Revision history for this message
Kirill Shustov (kirill-sustov) wrote :

I am running on fresh Ubuntu 22.10 installation.
snap-store consumes 500 MB of my system.

as a workaround I am closing this app manually. is there any better solution?

Revision history for this message
Akshat Kumar (kumar-ubuntu-enthusiast) wrote :

Hey Guys,
I am using Ubuntu 22.04.1 LTS x86_64. The problem still persists.

Revision history for this message
Alex Lutay (taurus) wrote :

On my Ubuntu 23.04 the snap-store uses ~26GB!!! of RAM in 7 days of uptime. o_0

> ps -p 6720 -o %cpu,%mem,cmd
%CPU %MEM CMD
 0.0 39.6 /snap/snap-store/959/usr/bin/snap-store --gapplication-service

> top -n 1 -p 6720
top - 00:54:56 up 7 days, 20:34, 2 users, load average: 1.83, 2.31, 2.60
Tasks: 1 total, 0 running, 1 sleeping, 0 stopped, 0 zombie
%Cpu(s): 0.0 us, 0.0 sy, 0.0 ni,100.0 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
MiB Mem : 64004.4 total, 19553.1 free, 42037.0 used, 6194.6 buff/cache
MiB Swap: 1952.0 total, 0.0 free, 1952.0 used. 21967.4 avail Mem

    PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
   6720 taurus 20 0 27.1g 24.8g 5604 S 0.0 39.6 4:39.30 snap-store

Happy to help tracing it! How?
P.S. It could be the separate issue...

Revision history for this message
Haui (haui111) wrote :

Ubuntu 23.04, issue still persists.

Revision history for this message
Dave Jones (waveform) wrote :

This appears to be partially fixed under Ubuntu 23.10. While the application (when running) still eats a few hundred meg of RAM, it does release that when closed, as opposed to hanging around persistently. Given apt usually eats over a hundred meg when processing the archive index, it's probably reasonable for a a graphical application processing a similar archive and including all the icons and pretty graphics to gobble a few hundred meg. However, it should definitely relinquish that memory when not in operation, which now appears to be the case.

In other words, my major objection (that it grabbed this RAM even when not in use), appears to be addressed. However, that's not the subject line of the bug; should this be closed / revised? Are others still encountering issues with the store on mantic?

Revision history for this message
Jeremy Bícha (jbicha) wrote :

Dave, this issue still affects gnome-software which is still used by some Ubuntu desktop flavors as of 23.10. I intend to propose soon that
1) those flavors switch to the firmware-updater snap or the GNOME Firmware app for 24.04 LTS
2) allowing me to drop the firmware support
3) perhaps it would then be possible to stop GNOME Software from continually running in the background.

- Ubuntu's unattended-upgrades, update-manager, etc. handle updating .deb's.
- Snaps automatically update themselves.
- The default install did not have a way to automatically check for firmware updates though, which was considered a critical enough need that the Ubuntu Desktop team did not override the app always running in the background.

However, it looks like Flatpak does not have its own auto update mechanism currently. Hmmm…

On a second note, this issue is also marked as affecting snap-store-desktop which is the project for the older Snap Store still used in Ubuntu 22.04 LTS.

Revision history for this message
Alex Lutay (taurus) wrote :

@waveform (Dave Jones)

The issue is still reproducible for me on 23.10 (see the new attached picture).

Snap-store used 2GB RAM my laptop with 1 day uptime only
(and the RAM usage is growing over the time,
please check my screenshot in https://bugs.launchpad.net/snap-store-desktop/+bug/1879137/comments/36
26GB RAM used by snap-store there !!!)

Happy to help with tracing it, feel free to ping me in MM!

Revision history for this message
Alex Lutay (taurus) wrote :

Polite ping...

JFYI: 4.5GB RAM usage by snap-store for 11 days uptime on Mantic:

> date
Tue Dec 5 05:43:26 PM CET 2023

> uptime
 17:43:29 up 11 days, 7:22, 2 users, load average: 2.63, 2.76, 2.70

> lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 23.10
Release: 23.10
Codename: mantic

> ps auxww | grep "snap-store\|MEM"
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
me 2329407 0.0 7.0 5602200 4607896 ? Sl Dec04 1:06 /snap/snap-store/959/usr/bin/snap-store --local-filename /home/me/...

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.