removing snapd fails on zfsroot install
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
snapd (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
when installed with a zfs root on Ubuntu 20.04, the installer creates a filesystem for /var/snap. however, the postrm script of the snapd tries to remove that directory, and it can't, because it's a mounted filesystem. the script should do the correct thing (destroy the filesystem and remove the dir) on zfs root installs.
ProblemType: Bug
DistroRelease: Ubuntu 20.04
Package: snapd (not installed)
ProcVersionSign
Uname: Linux 5.4.0-40-generic x86_64
NonfreeKernelMo
ApportVersion: 2.20.11-0ubuntu27.3
Architecture: amd64
CasperMD5CheckR
Date: Tue Jul 14 20:24:07 2020
InstallationDate: Installed on 2020-07-15 (0 days ago)
InstallationMedia: Ubuntu 20.04 LTS "Focal Fossa" - Release amd64 (20200423)
ProcEnviron:
LANGUAGE=en_CA:en
TERM=xterm-
PATH=(custom, no user)
LANG=en_CA.UTF-8
SHELL=/bin/bash
SourcePackage: snapd
UpgradeStatus: No upgrade log present (probably fresh install)
```
root@boxxy:~# apt remove --purge snapd
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following package was automatically installed and is no longer required:
libllvm9
Use 'apt autoremove' to remove it.
The following packages will be REMOVED:
snapd*
0 upgraded, 0 newly installed, 1 to remove and 6 not upgraded.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Requesting to save current system state
Successfully saved as "autozsys_dqsrt5"
(Reading database ... 165648 files and directories currently installed.)
Purging configuration files for snapd (2.45.1+20.04) ...
Final directory cleanup
rm: cannot remove '/var/snap': Device or resource busy
dpkg: error processing package snapd (--purge):
installed snapd package post-removal script subprocess returned error exit status 1
Errors were encountered while processing:
snapd
```