Comment 4 for bug 1970066

Revision history for this message
Steffen (sldayo) wrote (last edit ): Re: removing firefox snap after fresh 22.04 install with (encrypted) ZFS breaks APT, snapd

I was the one who originally had this issue and tried to get help on IRC, so I can confirm that this happens on my system as well with ZFS (encrypted) when running "snap remove firefox" during the first boot.

I decided to reproduce it again in order to submit my information but "apport-collect 1970066" suggested that I create a separate report.

When I then ran "apport-bug snapd" it failed (see attached screenshot) with a FileNotFoundError.

When I then tried to let apport-collect send my info anyway then it also failed:

Traceback (most recent call last):
  File "/usr/share/apport/apport-gtk", line 597, in <module>
    app.run_argv()
  File "/usr/lib/python3/dist-packages/apport/ui.py", line 719, in run_argv
    return self.run_update_report()
  File "/usr/lib/python3/dist-packages/apport/ui.py", line 604, in run_update_report
    apport.packaging.get_version(p)
  File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 163, in get_version
    pkg = self._apt_pkg(package)
  File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 156, in _apt_pkg
    return self._cache()[package]
  File "/usr/lib/python3/dist-packages/apport/packaging_impl.py", line 121, in _cache
    self._apt_cache = apt.Cache(progress, rootdir='/')
  File "/usr/lib/python3/dist-packages/apt/cache.py", line 143, in __init__
    self._check_and_create_required_dirs(rootdir)
  File "/usr/lib/python3/dist-packages/apt/cache.py", line 186, in _check_and_create_required_dirs
    open(rootdir + f, "w").close()
PermissionError: [Errno 13] Permission denied: '//var/lib/dpkg/status'

Edit: Regarding this error, I got the same result as in #3 when running apport-collect as root.