snapd memory sizes grows huge over time
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
snapd (Ubuntu) |
Fix Released
|
High
|
Unassigned |
Bug Description
I observed that installing and removing snaps seemed to make snapd grow in size, so to see if this assertion was true I repeatedly installed and removed a small package over the course of a few hours and measured the memory footprint with smemstat.
Attached is the smemstat log, with samples taken every 60 seconds. As one can see the USS, PSS and RSS sizes grow steadily to over 90MB over time. This suggests either data is being cached too aggressively or there is a memory leak somewhere, or perhaps garbage collection is not occurring as expected.
Although my test case is rather artificial, it does show there is an issue with memory size on snapd on a long running system when snaps are installed and removed. This is concerning for small IoT embedded devices.
Notes:
USS = Unique Set Size
PSS = Proportional Set Size
RSS = Resident Set Size
AttachedL smemstat log + data in a LibreOffice spreadsheet with graph showing memory size growth.
Changed in snapd (Ubuntu): | |
status: | New → In Progress |
status: | In Progress → Triaged |
Changed in snapd (Ubuntu): | |
status: | Fix Committed → Fix Released |
could this be related to Bug 1636847 ?