snapd hammers SSD for long periods

Bug #1831629 reported by Rkimber
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
snapd (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Snapd writes to SSD for very long periods. If I kill it, it restarts again later.

Ubuntu 19.04

snapd:
  Installed: 2.38+19.04
  Candidate: 2.38+19.04
  Version table:
 *** 2.38+19.04 500
        500 http://gb.archive.ubuntu.com/ubuntu disco/main amd64 Packages
        100 /var/lib/dpkg/status

ProblemType: Bug
DistroRelease: Ubuntu 19.04
Package: snapd 2.38+19.04
ProcVersionSignature: Ubuntu 5.0.0-15.16-generic 5.0.6
Uname: Linux 5.0.0-15-generic x86_64
NonfreeKernelModules: nvidia_modeset nvidia
ApportVersion: 2.20.10-0ubuntu27
Architecture: amd64
CurrentDesktop: MATE
Date: Tue Jun 4 14:49:57 2019
InstallationDate: Installed on 2018-10-01 (245 days ago)
InstallationMedia: Ubuntu-MATE 18.04.1 LTS "Bionic Beaver" - Release amd64 (20180725)
SourcePackage: snapd
UpgradeStatus: Upgraded to disco on 2019-04-25 (39 days ago)

Revision history for this message
Rkimber (rkimber) wrote :
Revision history for this message
John Lenton (chipaca) wrote :

Could you share with us whatever data you have that led you to the conclusion that it was snapd writing? Also the output of 'snap version' and 'snap list' might be helpful.

Changed in snapd (Ubuntu):
status: New → Incomplete
Revision history for this message
Rkimber (rkimber) wrote :

"snap changes"
gave:-

ID Status Spawn Ready Summary
29 Doing 2 days ago, at 17:48 BST - Auto-refresh snap "pulsemixer"

Doing:-
"snap abort 29"
stopped the disk activity, and it hasn't recurred since.

I then tried:-
"snap remove 29"
but got:-
error: snap "pulsemixer" has "auto-refresh" change in progress

"Snap version"
gives:-
snap 2.39
snapd 2.39
series 16
ubuntu 19.04
kernel 5.0.0-15-generic

"snap list"
gives:-
Name Version Rev Tracking Publisher Notes
core 16-2.39 6964 stable canonical✓ core
pulsemixer 1.4.0 23 stable/… georgefilipkin disabled
software-boutique 0+git.9cc961a 39 stable/… flexiondotorg classic
ubuntu-mate-welcome 19.10.0-c017529 335 stable/… flexiondotorg classic

Revision history for this message
Colin Ian King (colin-king) wrote :

Running fnotifystat will show file activity and maybe useful to see what is causing the I/O.

sudo apt install fnotifystat
sudo fnotifystat

or to look for a specific process use:

sudo fnotifystat -p snapd

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

[Expired for snapd (Ubuntu) because there has been no activity for 60 days.]

Changed in snapd (Ubuntu):
status: Incomplete → Expired
Revision history for this message
Claudio Matsuoka (cmatsuoka) wrote :
Download full text (4.3 KiB)

I experienced a similar problem, with constant disk writing at low rate (few hundred KB/s) and after inspecting the snapd process running on a container we found the following:

root@focal:/# snap changes
ID Status Spawn Ready Summary
234 Doing 2 days ago, at 16:40 UTC - Auto-refresh snap "snapd"

root@focal:/# snap change 234
Status Spawn Ready Summary
Done 2 days ago, at 16:40 UTC 2 days ago, at 16:40 UTC Ensure prerequisites for "snapd" are available
Doing 2 days ago, at 16:40 UTC - Download snap "snapd" (8008) from channel "latest/edge" (8.71%)
Do 2 days ago, at 16:40 UTC - Fetch and check assertions for snap "snapd" (8008)
Do 2 days ago, at 16:40 UTC - Mount snap "snapd" (8008)
Do 2 days ago, at 16:40 UTC - Run pre-refresh hook of "snapd" snap if present
Do 2 days ago, at 16:40 UTC - Stop snap "snapd" services
Do 2 days ago, at 16:40 UTC - Remove aliases for snap "snapd"
Do 2 days ago, at 16:40 UTC - Make current revision for snap "snapd" unavailable
Do 2 days ago, at 16:40 UTC - Copy snap "snapd" data
Do 2 days ago, at 16:40 UTC - Setup snap "snapd" (8008) security profiles
Do 2 days ago, at 16:40 UTC - Make snap "snapd" (8008) available to the system
Do 2 days ago, at 16:40 UTC - Automatically connect eligible plugs and slots of snap "snapd"
Do 2 days ago, at 16:40 UTC - Set automatic aliases for snap "snapd"
Do 2 days ago, at 16:40 UTC - Setup snap "snapd" aliases
Do 2 days ago, at 16:40 UTC - Run post-refresh hook of "snapd" snap if present
D...

Read more...

Changed in snapd (Ubuntu):
status: Expired → Confirmed
Revision history for this message
Beat Jörg (beat-joerg) wrote :

I see the same issue as reported above:

beat@dev01:~$ snap changes
ID Status Spawn Ready Summary
13 Doing today at 20:08 UTC - Auto-refresh snap "lxd"

beat@dev01:~$ snap change 13
Status Spawn Ready Summary
Done today at 20:08 UTC today at 20:08 UTC Ensure prerequisites for "lxd" are available
Doing today at 20:08 UTC - Download snap "lxd" (19647) from channel "4.0/stable/ubuntu-20.04" (38.53%)
Do today at 20:08 UTC - Fetch and check assertions for snap "lxd" (19647)
Do today at 20:08 UTC - Mount snap "lxd" (19647)
Do today at 20:08 UTC - Run pre-refresh hook of "lxd" snap if present
Do today at 20:08 UTC - Stop snap "lxd" services
Do today at 20:08 UTC - Remove aliases for snap "lxd"
Do today at 20:08 UTC - Make current revision for snap "lxd" unavailable
Do today at 20:08 UTC - Copy snap "lxd" data
Do today at 20:08 UTC - Setup snap "lxd" (19647) security profiles
Do today at 20:08 UTC - Make snap "lxd" (19647) available to the system
Do today at 20:08 UTC - Automatically connect eligible plugs and slots of snap "lxd"
Do today at 20:08 UTC - Set automatic aliases for snap "lxd"
Do today at 20:08 UTC - Setup snap "lxd" aliases
Do today at 20:08 UTC - Run post-refresh hook of "lxd" snap if present
Do today at 20:08 UTC - Start snap "lxd" (19647) services
Do today at 20:08 UTC - Remove data for snap "lxd" (19032)
Do today at 20:08 UTC - Remove snap "lxd" (19032) from the system
Do today at 20:08 UTC - Clean up "lxd" (19647) install
Do today at 20:08 UTC - Run configure hook of "lxd" snap if present
Do today at 20:08 UTC - Run health check of "lxd" snap
Doing today at 20:08 UTC - Consider re-refresh of "lxd"

Norbert (nrbrtx)
tags: removed: disco
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.