Tails upgrader left garbage in Tails partition
When Tails Upgrader fails or is interrupted while doing an upgrade, the USB stick might end up with:
- Some garbage in it, like
/lib/live/mount/medium/tmp/tmp.SEbvQlhqGJ/tar. For example, if the upgrade failed during the download. It would be nice to remove this garbage as it otherwise forces the user to perform a full upgrade sooner than expected.
- A USB stick in a weird state between the old and the new version if the upgrade failed while applying the upgrade, with possible security implications. It would be nice to prevent such a USB stick to even start. For example, by failing safe in Tails Greeter and display an error message.
In both cases (“failed while downloading” and “failed while applying upgrade”) an error message is displayed to the user, but this doesn’t take into account that the computer might be turned off by mistake before the error message.
Both improvements could be implemented using flags, added and removed in the system partition when doing the upgrade.
- Related to #7073