Public bug reported: Error at the end of removing snapd, here is the output:
akem@akem-HP:~$ sudo apt-get remove --purge apparmor [sudo] password for akem: Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: linux-headers-4.18.0-21 linux-headers-4.18.0-21-generic linux-image-4.18.0-21-generic linux-modules-4.18.0-21-generic linux-modules-extra-4.18.0-21-generic Use 'sudo apt autoremove' to remove them. The following additional packages will be installed: gnome-software gnome-software-common Suggested packages: apt-config-icons-hidpi gnome-software-plugin-flatpak gnome-software-plugin-limba Recommended packages: gnome-software-plugin-snap The following packages will be REMOVED: apparmor* gnome-software-plugin-snap* snapd* The following packages will be upgraded: gnome-software gnome-software-common 2 upgraded, 0 newly installed, 3 to remove and 234 not upgraded. Need to get 2 966 kB of archives. After this operation, 69,6 MB disk space will be freed. Do you want to continue? [Y/n] Get:1 http://fr.archive.ubuntu.com/ubuntu bionic-updates/main amd64 gnome-software amd64 3.28.1-0ubuntu4.18.04.10 [484 kB] Get:2 http://fr.archive.ubuntu.com/ubuntu bionic-updates/main amd64 gnome-software-common all 3.28.1-0ubuntu4.18.04.10 [2 482 kB] Fetched 2 966 kB in 14s (206 kB/s) (Reading database ... 275783 files and directories currently installed.) Removing gnome-software-plugin-snap (3.28.1-0ubuntu4.18.04.8) ... Removing snapd (2.37.4+18.04.1) ... Removing apparmor (2.12-4ubuntu5.1) ... (Reading database ... 275692 files and directories currently installed.) Preparing to unpack .../gnome-software_3.28.1-0ubuntu4.18.04.10_amd64.deb ... Unpacking gnome-software (3.28.1-0ubuntu4.18.04.10) over (3.28.1-0ubuntu4.18.04.8) ... Preparing to unpack .../gnome-software-common_3.28.1-0ubuntu4.18.04.10_all.deb ... Unpacking gnome-software-common (3.28.1-0ubuntu4.18.04.10) over (3.28.1-0ubuntu4.18.04.8) ... Setting up gnome-software-common (3.28.1-0ubuntu4.18.04.10) ... Processing triggers for mime-support (3.60ubuntu1) ... Processing triggers for desktop-file-utils (0.23-1ubuntu3.18.04.2) ... Processing triggers for libglib2.0-0:amd64 (2.56.4-0ubuntu0.18.04.3) ... Processing triggers for libglib2.0-0:i386 (2.56.4-0ubuntu0.18.04.3) ... Setting up gnome-software (3.28.1-0ubuntu4.18.04.10) ... Processing triggers for man-db (2.8.3-2ubuntu0.1) ... Processing triggers for gnome-menus (3.13.3-11ubuntu1.1) ... Processing triggers for hicolor-icon-theme (0.17-2) ... (Reading database ... 275690 files and directories currently installed.) Purging configuration files for apparmor (2.12-4ubuntu5.1) ... dpkg: warning: while removing apparmor, directory '/var/cache/apparmor' not empty so not removed dpkg: warning: while removing apparmor, directory '/etc/apparmor.d/cache' not empty so not removed dpkg: warning: while removing apparmor, directory '/etc/apparmor.d/abstractions/ubuntu-browsers.d' not empty so not removed Purging configuration files for snapd (2.37.4+18.04.1) ... Stopping snap-core-6964.mount Stopping unit snap-core-6964.mount Waiting until unit snap-core-6964.mount is stopped [attempt 1] snap-core-6964.mount is stopped. Removing snap core and revision 6964 Removing snap-core-6964.mount Stopping snap-core-7169.mount Stopping unit snap-core-7169.mount Waiting until unit snap-core-7169.mount is stopped [attempt 1] snap-core-7169.mount is stopped. Removing snap core and revision 7169 Removing snap-core-7169.mount Stopping snap-core18-1013.mount Stopping unit snap-core18-1013.mount Waiting until unit snap-core18-1013.mount is stopped [attempt 1] snap-core18-1013.mount is stopped. Removing snap core18 and revision 1013 Removing snap-core18-1013.mount Stopping snap-core18-970.mount Stopping unit snap-core18-970.mount Waiting until unit snap-core18-970.mount is stopped [attempt 1] snap-core18-970.mount is stopped. Removing snap core18 and revision 970 Removing snap-core18-970.mount Stopping snap-gnome\x2d3\x2d26\x2d1604-86.mount Stopping unit snap-gnome\x2d3\x2d26\x2d1604-86.mount Waiting until unit snap-gnome\x2d3\x2d26\x2d1604-86.mount is stopped [attempt 1] snap-gnome\x2d3\x2d26\x2d1604-86.mount is stopped. Removing snap gnome-3-26-1604 and revision 86 Removing snap-gnome\x2d3\x2d26\x2d1604-86.mount Stopping snap-gnome\x2d3\x2d26\x2d1604-88.mount Stopping unit snap-gnome\x2d3\x2d26\x2d1604-88.mount Waiting until unit snap-gnome\x2d3\x2d26\x2d1604-88.mount is stopped [attempt 1] snap-gnome\x2d3\x2d26\x2d1604-88.mount is stopped. Removing snap gnome-3-26-1604 and revision 88 Removing snap-gnome\x2d3\x2d26\x2d1604-88.mount Stopping snap-gnome\x2d3\x2d28\x2d1804-55.mount Stopping unit snap-gnome\x2d3\x2d28\x2d1804-55.mount Waiting until unit snap-gnome\x2d3\x2d28\x2d1804-55.mount is stopped [attempt 1] snap-gnome\x2d3\x2d28\x2d1804-55.mount is stopped. Removing snap gnome-3-28-1804 and revision 55 Removing snap-gnome\x2d3\x2d28\x2d1804-55.mount Stopping snap-gnome\x2d3\x2d28\x2d1804-59.mount Stopping unit snap-gnome\x2d3\x2d28\x2d1804-59.mount Waiting until unit snap-gnome\x2d3\x2d28\x2d1804-59.mount is stopped [attempt 1] snap-gnome\x2d3\x2d28\x2d1804-59.mount is stopped. Removing snap gnome-3-28-1804 and revision 59 Removing snap-gnome\x2d3\x2d28\x2d1804-59.mount Stopping snap-gnome\x2dcalculator-260.mount Stopping unit snap-gnome\x2dcalculator-260.mount Waiting until unit snap-gnome\x2dcalculator-260.mount is stopped [attempt 1] snap-gnome\x2dcalculator-260.mount is stopped. Removing snap gnome-calculator and revision 260 Removing snap-gnome\x2dcalculator-260.mount Stopping snap-gnome\x2dcalculator-406.mount Stopping unit snap-gnome\x2dcalculator-406.mount Waiting until unit snap-gnome\x2dcalculator-406.mount is stopped [attempt 1] snap-gnome\x2dcalculator-406.mount is stopped. Removing snap gnome-calculator and revision 406 Removing snap-gnome\x2dcalculator-406.mount Stopping snap-gnome\x2dcharacters-284.mount Stopping unit snap-gnome\x2dcharacters-284.mount Waiting until unit snap-gnome\x2dcharacters-284.mount is stopped [attempt 1] snap-gnome\x2dcharacters-284.mount is stopped. Removing snap gnome-characters and revision 284 Removing snap-gnome\x2dcharacters-284.mount Stopping snap-gnome\x2dcharacters-288.mount Stopping unit snap-gnome\x2dcharacters-288.mount Waiting until unit snap-gnome\x2dcharacters-288.mount is stopped [attempt 1] snap-gnome\x2dcharacters-288.mount is stopped. Removing snap gnome-characters and revision 288 Removing snap-gnome\x2dcharacters-288.mount Stopping snap-gnome\x2dlogs-45.mount Stopping unit snap-gnome\x2dlogs-45.mount Waiting until unit snap-gnome\x2dlogs-45.mount is stopped [attempt 1] snap-gnome\x2dlogs-45.mount is stopped. Removing snap gnome-logs and revision 45 Removing snap-gnome\x2dlogs-45.mount Stopping snap-gnome\x2dlogs-61.mount Stopping unit snap-gnome\x2dlogs-61.mount Waiting until unit snap-gnome\x2dlogs-61.mount is stopped [attempt 1] snap-gnome\x2dlogs-61.mount is stopped. Removing snap gnome-logs and revision 61 Removing snap-gnome\x2dlogs-61.mount Stopping snap-gnome\x2dsystem\x2dmonitor-87.mount Stopping unit snap-gnome\x2dsystem\x2dmonitor-87.mount Waiting until unit snap-gnome\x2dsystem\x2dmonitor-87.mount is stopped [attempt 1] snap-gnome\x2dsystem\x2dmonitor-87.mount is stopped. Removing snap gnome-system-monitor and revision 87 Removing snap-gnome\x2dsystem\x2dmonitor-87.mount Stopping snap-gnome\x2dsystem\x2dmonitor-91.mount Stopping unit snap-gnome\x2dsystem\x2dmonitor-91.mount Waiting until unit snap-gnome\x2dsystem\x2dmonitor-91.mount is stopped [attempt 1] snap-gnome\x2dsystem\x2dmonitor-91.mount is stopped. Removing snap gnome-system-monitor and revision 91 Removing snap-gnome\x2dsystem\x2dmonitor-91.mount Stopping snap-gtk\x2dcommon\x2dthemes-1198.mount Stopping unit snap-gtk\x2dcommon\x2dthemes-1198.mount Waiting until unit snap-gtk\x2dcommon\x2dthemes-1198.mount is stopped [attempt 1] snap-gtk\x2dcommon\x2dthemes-1198.mount is stopped. Removing snap gtk-common-themes and revision 1198 Removing snap-gtk\x2dcommon\x2dthemes-1198.mount Stopping snap-gtk\x2dcommon\x2dthemes-818.mount Stopping unit snap-gtk\x2dcommon\x2dthemes-818.mount Waiting until unit snap-gtk\x2dcommon\x2dthemes-818.mount is stopped [attempt 1] snap-gtk\x2dcommon\x2dthemes-818.mount is stopped. Removing snap gtk-common-themes and revision 818 Removing snap-gtk\x2dcommon\x2dthemes-818.mount Final directory cleanup Discarding preserved snap namespaces Removing extra snap-confine apparmor rules Removing snapd cache rm: cannot remove '/var/cache/snapd/aux': Is a directory dpkg: error processing package snapd (--purge): installed snapd package post-removal script subprocess returned error exit status 1 E: Sub-process /usr/bin/dpkg returned an error code (1) akem@akem-HP:~$ ProblemType: Bug DistroRelease: Ubuntu 18.04 Package: snapd (not installed) ProcVersionSignature: Ubuntu 4.18.0-22.23~18.04.1-generic 4.18.20 Uname: Linux 4.18.0-22-generic x86_64 NonfreeKernelModules: nvidia_modeset nvidia ApportVersion: 2.20.9-0ubuntu7.5 Architecture: amd64 Date: Thu Jun 27 02:28:24 2019 InstallationDate: Installed on 2019-05-31 (26 days ago) InstallationMedia: Ubuntu 18.04.2 LTS "Bionic Beaver" - Release amd64 (20190210) SourcePackage: snapd UpgradeStatus: No upgrade log present (probably fresh install) ** Affects: snapd (Ubuntu) Importance: Undecided Status: New ** Tags: amd64 apport-bug bionic -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1834387 Title: Error when removing snapd (via apparmor) To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/snapd/+bug/1834387/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs