Same issues here.
Is it safe to remove (some of) the contents of the appstream directory at least. At least some people seem to have done so without things going awry.
There appears to be a lot of dross in there, and I wouldn’t mind a couple of extra gigs of space.
I’ve found the information that: the …/aarch64 folder “is only supposed to have (in the steady state), one “active” symlink pointing to a non-dot prefixed check-summed file, and a .timestamp file”. Here is a discussion about that.
I’ve deleted all other stuff and apparently everithing is working properly. Recovered about 7GB
If only it wasn’t so bloody hard to manipulate files in protected folders! Nemo does not allow copying files in these directories. Running nemo from the command line as root (sudo nemo) does not work. And I don’t know of an elegant way to do this from the comand line.
(I want to copy the three files needed to a new directory, and then delete the old flathub directory.)
I think I managed to do it.
I copied the ‘active’ directory, the giant (hex?) number without a dot, and the most recent giant (hex) number with a dot to a new /flathub/aarch64 directory. After renaming the original flathub dir.
So, now I can delete the original flathub dir?
Or maybe I don’t need the one with the dot(?)
Correct, you don’t need the one with the dot.
But ‘active’ isn’t a directory, it’s a link pointing to the non-dot prefixed dir (I had only one).
My folder currently contains:
active -> 9189a0c9b3c5495ad643b79bdd1b941df088ab3edc629172d4210b33d02c405a
It works … but I don’t take any responsibilities
No complaints yet about the new leaner one. I’ll wait a bit before I delete anything.
Where exaclty is Flatpak in the /home directory?
And where is that generaljournal cache at?
I think he means
sudo journalctl --vacuum-time=10d
it’s been explained above, on this thread
Ah, okay. Thanks.
Just checking whether it was the same journal cleaning instruction I had seen before, or another one. It’s the same.
And the cache in the flatpak dir is empty.
To follow up on this:
Can somebody please help us poor souls who have Librem 5 and want to install Flatpaks without unecessary bloat? I realize Purism has other things to do, but this is a silly issue.
Doing things on my own, again, I took a whim and used this command:
rm -r /var/lib/flatpak/appstream/flathub/aarch64
That deleted the whole directory and files in it. I got rid of about 2 GB of what appear to be unnecessary bloat.
Warning, I am a novice and I guarantee nothing! Run that command at your own risk.
I hope that helps someone. There have been no adverse effects on my us of Flatpak apps on the phone - yet.
I just reflash the latest Evergreen LUKS and DAS U-Boot images to deal with bloat or misconfigurations. Far more often I do it due to the latter than the former, since I hardly install anything to begin with.
Ok. Thank you. Can you make it easy on me and tell me how to easily do that?
The following official documentation may get you pointed in the right direction: https://docs.puri.sm/Librem_5/Troubleshooting/Reflashing.html
Here is a high-level overview:
Boot into the PureOS USB live image.
Follow the instructions listed by Irvine Wade above this post, or alternatively this one below.
- Remember to install
gitfirst before mirroring the repository. Also note the command
sudo apt build-dep .
- Remember to install
See flatsweep (use on own risk).
You just saved me 1.6 GB of space. Merci beaucoup!
I took the risk and did:
sudo rm -rf /var/lib/flatpak/appstream
This resulted in 4.3GB of extra storage. I did not notice any negative side effects, but use at own risk.
/var/lib/flatpak/appstream is a bug that is fixed in a newer flatpak release.
Doing a sudo rm -r .* in var/lib/flatpak/appstream/flathub/aarch64 works too, and it is somewhat less drastic.