Will it be impossible to uninstall snaps in future?

Hi,

In 21.10 snap has succesfully invaded at least two core components of ubuntu-mate:

pulseaudio and cups.

It is still possible to rebuild them without the snap support. However how long will it remain this way?

Snap itself is a unecessary component eating a cinsiderable amount of internet bandwith and disk storage without any measurable advantage.

Is there any hope for a fully snapcraft free build of ubuntu-mate in the future?

regards bluedxca93

Could you please be more specific about your problem?

The below terminal output got from Ubuntu MATE 21.10:

$ head -n1 /etc/apt/sources.list
#deb cdrom:[Ubuntu-MATE 21.10 _Impish Indri_ - Release amd64 (20211012)]/ impish main multiverse restricted universe
$ snap list 
Name                  Version           Rev    Tracking         Publisher      Notes
core18                20211015          2246   latest/stable    canonicalâś“     base
gtk-theme-yaru-mate   21.04.6           6      latest/stable/…  flexiondotorg  -
icon-theme-yaru-mate  21.04.6           1      latest/stable/…  flexiondotorg  -
snapd                 2.52.1            13640  latest/stable    canonicalâś“     snapd
software-boutique     0+git.f633ffb     54     latest/stable/…  flexiondotorg  classic
ubuntu-mate-welcome   21.10.0-5b832ea8  646    latest/stable/…  flexiondotorg  classic

I do not see cups and pulseaudio here.

1 Like

Sure. It’s called Mint, Fedora, Arch, Debian, Solus, or KaOS to name a few. There may be more distributions out there that don’t use Snaps natively. Some or all may support Snaps but they are not using them as much as Ubuntu. Not sure the Snaps issue is as big of a problem as some are making it out to be. If it works right, I don’t see a problem but you have choice with Linux.

2 Likes

@Norbert_X

cups-daemon requires libsnapd-glib1

pulseaudio requires libsnapd-glib1

That is a problem if you want to purge snapcraft completly.
Currently its possible to build these packages without snap.

@HJV
well after ubuntu 22.04 i guess i'll have to do that switch back to debian. Hope that 22.04 can be patched without snapd bindings. On 21.10 it seems to be working without snapd if i patch these two packages or rather remove the unwanted snapd patches.

My patched receipes to build them without snapd are here for 21.10:

Nice finding. Now I see that

$ sudo apt autopurge snapd
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
  snapd* squashfs-tools*
0 upgraded, 0 newly installed, 2 to remove and 54 not upgraded.
After this operation, 94,3 MB disk space will be freed.
Do you want to continue? [Y/n] n

is safe, but

$ sudo apt autopurge gir1.2-snapd-1:amd64 libsnapd-glib1:amd64 snapd
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
  apturl* apturl-common* ayatana-indicator-sound* bluez-cups* cups*
  cups-browsed* cups-core-drivers* cups-daemon* cups-server-common*
  gir1.2-goa-1.0* gir1.2-snapd-1* hplip* hplip-data* libcanberra-pulse*
  libcupsimage2* libgutenprint-common* libgutenprint9* libhpmud0*
  libimagequant0* libpulsedsp* libsane-hpaio* libsbc1* libsnapd-glib1*
  libspeexdsp1* printer-driver-gutenprint* printer-driver-hpcups*
  printer-driver-postscript-hp* printer-driver-splix* pulseaudio*
  pulseaudio-module-bluetooth* pulseaudio-utils* python3-dateutil*
  python3-debconf* python3-olefile* python3-pil* python3-renderpm*
  python3-reportlab* python3-reportlab-accel* python3-software-properties*
  rtkit* snapd* software-properties-common* software-properties-gtk*
  squashfs-tools* ssl-cert* ubuntu-mate-core* ubuntu-mate-desktop*
  ubuntu-release-upgrader-gtk* update-manager* update-notifier*
  update-notifier-common*
0 upgraded, 0 newly installed, 51 to remove and 54 not upgraded.
After this operation, 144 MB disk space will be freed.
Do you want to continue? [Y/n] n

is not.

This is upstream (Ubuntu) decision targeted on user comfort.
For example CUPS provides drivers for printers which are released very fast (faster than LTS release cycle of course). So having CUPS as a Snap is a good idea, if we or Canonical care about the users. PPA maybe better, but they chose Snap...

I understand the frustration some people are having. I think I was on UM 20.10 around the time 21.04 came out and noticed some apps being slow but didn’t give it much thought. I was a happy camper with UM. I have always tried other distributions just to see what the differences are but never changed from UM on my laptop and Feren on my desktop - everything worked and both OS’s were reliable. One day I tried Manjaro KDE and GNOME. I was so surprised with GNOME, I switched. Since I could install Flatpaks or Snaps or apps from main repository or AUR, I was able to compare the differences and that made me stay with Manjaro. I think the startup times are the biggest issue with Snaps for most people like it was for me. Occasionally, they would just hang and not even start. Anyway, I was swayed to Manjaro because of that but really like UM but apparently the Snaps issue is becoming a greater concern.

2 Likes

I switched all my machines to OpenSUSE Tumbleweed during the last month mostly for that reason. I don't like how Canonical are forcing more and more snaps on us.
If I install some ressource-friendly distro on a computer with low specs, I don't expect performance to be hampered due to some unneeded (to me) packaging format.

3 Likes

Did now test a bit further.
Apturl, software-properties gtk and apturl does require snap.
However pulseaudio and cups can be build without snap as described earlier.

Played with an fresh xfce Core install:
First i chrooted to it and installed the patched snapd free cups and pulseaudio packages over the installed ones.
Then I did what @Norbert_X tried. Now the result is not very recommended but it works well enough that you can run synaptic cups and pulseaudio. Firefox is then a deb package to for now. It is a quick and dirty workaround but i have to say mate runs now very fast on virtualbox.

1 Like

Tried to report a bug

about Snapd-Glib "integration".

Did affect me too. Hopefully others can also increase the heat of the bug

Startup time is the least of the problems with snaps. That's so far down the list that it doesn't even register for me.

Regardless, Canonical is committed to the snap ecosystem, and the knock-on effects of that are going to make it either painful or impractical to be able to avoid them for much longer. I can do it, but the Firefox change alone is basically going to force every "normal" user to accept snaps. (Which, admittedly, is the only way such a clownshow is ever going to get traction).

So, realistically, the answer to OP's question - contrary to Betteridge's Law :stuck_out_tongue: - is unfortunately "Yes".
If you're determined enough, I expect you'll be able to avoid them for one more cycle, but that's probably going to be it, unless you're willing to build everything from source.

I get it. That is why I moved to Manjaro when I found their community edition of MATE. Although I am a big fan of UM, the Snaps issue along with a few small nit-noid things made me move. Along the way, I found their rolling release model appealed to me and settled on their Cinnamon community edition which is very much like UM. But UM wins with the ease of layout switching and the software boutique. Also, the Solus version of Mate is fantastic. Anyway, I hope the LTS for UM in a few months will bring me back but for now enjoying Manjaro’s Cinnamon.

Current progress once cups and pulseaudio is custom build:

sudo apt autopurge gir1.2-snapd-1:amd64 libsnapd-glib1:amd64 
Paketlisten werden gelesen… Fertig
Abhängigkeitsbaum wird aufgebaut… Fertig
Statusinformationen werden eingelesen… Fertig
Die folgenden Pakete werden ENTFERNT:
  apturl* apturl-common* gir1.2-goa-1.0* gir1.2-snapd-1* libsnapd-glib1* python3-dateutil* python3-software-properties* software-properties-common*
  software-properties-gtk* ubuntu-mate-core* ubuntu-mate-desktop* ubuntu-release-upgrader-gtk* update-manager* update-notifier* update-notifier-common*
0 aktualisiert, 0 neu installiert, 15 zu entfernen und 5 nicht aktualisiert.
2 nicht vollständig installiert oder entfernt.
Nach dieser Operation werden 4.759 kB Plattenplatz freigegeben.

Thats not ideal but it does at least not fully break the system. software-properties-gtk is the most critical point here. Sadly don`t know how to patch it.