Firefox 在更新时出现问题

Firefox 在更新时出现问题

当我从 ubuntu 21.10 升级到 ubuntu 22.04 LTS 时,我看到以下错误。我在通知区域看到一个持续的图标,提醒我更新时出了点问题。当我尝试更新(如它所要求的)时,我收到以下错误。

The Package system is Broken

Check if you are using third party repositories. If so disable them, since they are a common source of problems.
Furthermore run the following command in a Terminal: apt-get install -f
Transaction failed: The package system is broken
 The following packages have unmet dependencies:

firefox-locale-en: Depends: firefox (>= 1:1snap1-0ubuntu2) but 99.0+build2-0ubuntu0.21.10.2 is installed

我有两个版本的 Firefox,一个来自apt,另一个来自snap。我卸载了来自的一个apt,但我无法卸载另一个snap。在删除其中apt一个时,我删除了 Firefox 目录,如和~/.mozilla/etc/firefox/usr/lib/firefox/以及/usr/lib/firefox-addons/sudo apt-get purge firefox

sudo snap uninstall firefox

error: system does not fully support snapd: cannot mount squashfs image using
       "squashfs": mount: /tmp/sanity-mountpoint-2641143541: wrong fs type, bad
       option, bad superblock on /dev/loop23, missing codepage or helper
       program, or other error.

更新和修复损坏软件包的结果

$ apt list --upgradable -a 
Listing... Done firefox/jammy 1:1snap1-0ubuntu2 amd64 [upgradable from: 99.0+build2-0ubuntu0.21.10.2] firefox/now 99.0+build2-0ubuntu0.21.10.2 amd64 [installed,upgradable to: 1:1snap1-0ubuntu2] 
sudo apt --fix-broken install

=> Installing the firefox snap
==> Installing the firefox snap
error: system does not fully support snapd: cannot mount squashfs image using "squashfs": mount:
       /tmp/sanity-mountpoint-2641143541: wrong fs type, bad option, bad superblock on /dev/loop23,
       missing codepage or helper program, or other error.
dpkg: error processing archive /var/cache/apt/archives/firefox_1%3a1snap1-0ubuntu2_amd64.deb (--unpack):
 new firefox package pre-installation script subprocess returned error exit status 1
update-alternatives: error: alternative path /usr/bin/firefox doesn't exist
dpkg: error while cleaning up:
 installed firefox package post-installation script subprocess returned error exit status 2
Errors were encountered while processing:
 /var/cache/apt/archives/firefox_1%3a1snap1-0ubuntu2_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

相关内容