snap has broken after one of recent system updates. For example, telegram desktop stopped working. I managed to remove telegram, but cannot reinstall that. The reason is in broken core22 module:
error: cannot perform the following tasks:
- Run configure hook of "telegram-desktop" snap if present (run hook "configure": cannot locate base snap core22: No such file or directory)
I tried to remove core22 to repair that, but it didn't work:
error: cannot perform the following tasks:
- Remove data for snap "core22" (522) (failed to remove snap "core22" base directory: remove /var/snap/core22: directory not empty)
I couldn't repair that neither. I tried sudo snap refresh core22 --edge
, though it doesn't work:
error: cannot refresh "core22": refreshing disabled snap "core22" not supported
Attempt to enable core22 with sudo snap enable core22
fails:
error: cannot perform the following tasks:
- Setup snap "core22" (522) security profiles (cannot find installed snap "core22" at revision 522: missing file /snap/core22/522/meta/snap.yaml)
System info:
5.19.0-32-generic #33~22.04.1-Ubuntu
snap list --all
Name Version Rev Tracking Publisher Notes
bare 1.0 5 latest/stable canonical✓ base
chromium 110.0.5481.100 2333 latest/stable canonical✓ -
chromium 110.0.5481.77 2319 latest/stable canonical✓ disabled
core 16-2.58 14447 latest/stable canonical✓ core,disabled
core 16-2.58.2 14784 latest/stable canonical✓ core
core18 20230118 2679 latest/stable canonical✓ base,disabled
core18 20230207 2697 latest/stable canonical✓ base
core20 20230126 1822 latest/stable canonical✓ base
core20 20221212 1778 latest/stable canonical✓ base,disabled
core22 - 522 latest/stable canonical✓ disabled,broken
cups 2.4.2-5 872 latest/stable openprinting✓ -
cups 2.4.2-4 836 latest/stable openprinting✓ disabled
cura-slicer 4.13.2 100 latest/stable glasen disabled
cura-slicer 4.13.2 102 latest/stable glasen -
firecamp 2.7.1 202 latest/stable nishchit14 -
firefox 109.0.1-1 2311 latest/stable/… mozilla✓ disabled
firefox 110.0-3 2356 latest/stable/… mozilla✓ -
gnome-3-28-1804 3.28.0-19-g98f9e67.98f9e67 161 latest/stable canonical✓ -
gnome-3-34-1804 0+git.3556cb3 77 latest/stable canonical✓ -
gnome-3-38-2004 0+git.891e5bc 115 latest/stable/… canonical✓ disabled
gnome-3-38-2004 0+git.6f39565 119 latest/stable/… canonical✓ -
gnome-42-2204 0+git.0c1a50b 56 latest/stable canonical✓ -
gtk-common-themes 0.1-81-g442e511 1535 latest/stable/… canonical✓ -
gtk-common-themes 0.1-79-ga83e90c 1534 latest/stable/… canonical✓ disabled
pdftk 2.02-4 9 latest/stable smoser -
slack 4.28.184 67 latest/stable slack✓ disabled
slack 4.29.149 68 latest/stable slack✓ -
snap-store 41.3-68-gf43d07e 681 latest/edge canonical✓ -
snap-store 41.3-66-gfe1e325 638 latest/edge canonical✓ disabled
snapd 2.58.3+git520.gb0848d7 18621 latest/edge canonical✓ snapd
snapd 2.58.2 18357 latest/edge canonical✓ snapd,disabled
snapd-desktop-integration 0.1 49 latest/stable/… canonical✓ -
Response to ls -la /var/snap/core22
total 12
drwxr-xr-x 3 root root 4096 helmi 24 11:50 .
drwxr-xr-x 22 root root 4096 helmi 26 11:53 ..
drwxr-xr-x 2 root root 4096 heinä 24 2022 504
Is there any way to fix core22
without complete re-installation of snap on the system? Thanks
Upd: added info about removal attempt.
Upd2: added ls -la /var/snap/core22