A tip regarding Flatpak

If you use Flatpak keep in mind that Flatpak lets old versions of a package just… lay around.
This eventually will cause problems, especially if you have say an nvidia card. It all works fine as long as there are gradual updates of the same version such as Nvidia 450 driver. But when you switch to the 455 driver Flatpak just leaves the latest 450 driver laying around. And nvidia drivers are rather large. I have seen people asking in Linux forums because their / partition is suddenly full, and realizing they have over two gig of NVIDIA drivers laying around.

To solve this, use the “uninstall --unused” option. Or, more efficiently, do like this:

flatpak update && flatpak uninstall --unused

Huh, that actually explains some stuff that I wanted to know but was affraid to ask.

Thx for the tip.


My understand of what is happening here is that the issue is with flatpak runtimes/dependencies. The different “versions” of some flatpaks are actually different flatpaks. By default, flatpak doesn’t remove unused dependencies so basically what you are doing is cleaning up orphans. The difference between pacman orphans and flatpak orphans is that the latter are much larger. :smile:


Yep. Every time a new major version comes out of say an NVIDIA driver it is counted as a separate flatpak.


Thank you, I don’t use Flatpaks but I’ve added this to my personal Wiki.