Score:-1

Ubuntu won't boot because of broken Snap

ch flag

my Ubuntu refuses to boot with the following messages:

/var/lib/snapd... Can't open blockdev ... Failed to mount Mount unit for ...

In addition, my / partition is full. It was full before, before rebooting, which I tried to solve by removing some snap files (older revisions) by hand. The snaps themselves were working, so I thought: "Alright". Only after reboot I realized my mistake.

What I usually try when I cannot boot is to rewind to an earlier snapshot with Timeshift. However this time it didn't work; it fails to boot and my / part is still full, even though I went back to an earlier snapshot.

I also tried formatting the partition, installing Ubuntu over and then restoring the snapshot -> same thing. Deactivating faulty snaps in Recovery mode -> same thing. 'sudo apt remove snapd' -> same thing.

I don't understand how a snapshot from the time when the / part had enough free space restores into a full part. Do you know how to fix this?

Context: Ubuntu 22.04 / 22 Gb /home 19 Gb

EDIT#1: ckhan: https://cryptpad.fr/file/#/2/file/vXQds-PSdWI+GVZPa23QkDk6/ I am not conflating them; I simply don't know which one of them caused the problem.

popey: I don't remember deleting anything besides the Snaps (and a folder outside snaps folder which Docker snap created to store some files).

EDIT#2: Interesting observation: when I click Browse files in any of the snapshots, it shows that the snapshot is over 32 Gb, even though the partition never had more than 22 Gb. It may be some kind of snapshot corruption.

ckhan avatar
ph flag
I'm worried that you're conflating the software program Timeshift (which does backups called "snapshots") and the Canonical Snapcraft packaging system (which has a component called [`snapd`](https://snapcraft.io/docs/installing-snapd)). Can you paste a screenshot of exactly what you seen on screen when your system tries to boot?
pl flag
Did you perchance delete more than just old snaps, and perhaps removed a critical part of the filesystem?
zaiac avatar
ch flag
ckhan: https://cryptpad.fr/file/#/2/file/vXQds-PSdWI+GVZPa23QkDk6/ I am not conflating them; I simply don't know which one of them caused the problem. popey: I don't remember deleting anything besides the Snaps (and a folder outside snaps folder which Docker snap created to store some files).
zaiac avatar
ch flag
Interesting observation: when I click Browse files in any of the snapshots, it shows that the snapshot is over 32 Gb, even though the partition never had more than 22 Gb. It may be some kind of snapshot corruption.
zaiac avatar
ch flag
Trying 'sudo snap list' and 'sudo apt remove snapd' also don't work with following errors: https://cryptpad.fr/file/#/2/file/snkSyj6dnsELIFhd1r4dla+E/
ckhan avatar
ph flag
Can you boot the system directly into recovery mode or from a live USB like https://www.system-rescue.org/? All signs seem to indicate we need to repair the root filesystem and get a consistent picture of available space on it.
zaiac avatar
ch flag
I could boot into live CD. In the end, I readjusted the disk so that I could increase the part size to 32 Gb and recovered the giant snapshot. System was working and removing Docker snap freed the 10+ Gb of space! However snaps are not working after refreshing neither after reinstalling snapd.
Score:-1
ch flag

The way to solve this was to get enough space available so the big image could be restored. Then freeing up ~10 Gb of space taken up by ****ing Docker and completely reinstalling snapd. I'm welcome.

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.