无法在 Ubuntu 20.04 中升级、卸载、重新安装、安装、删除或清除 MySQL 或 MariaDB

无法在 Ubuntu 20.04 中升级、卸载、重新安装、安装、删除或清除 MySQL 或 MariaDB

我正在尝试升级 MySQL,但由于出现以下消息而无法升级:

The following packages have unmet dependencies:
 mysql-server-8.0 : Depends: mysql-server-core-8.0 (= 8.0.31-0ubuntu0.20.04.1) but 8.0.31-0ubuntu0.20.04.2 is to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

这是 apt 安装的列表:

libmysqlclient20/xenial-security,now 5.7.33-0ubuntu0.16.04.1 amd64 [installed]
libmysqlclient21/focal-security,now 8.0.31-0ubuntu0.20.04.1 amd64 [installed,upgradable to: 8.0.31-0ubuntu0.20.04.2]
mysql-client-8.0/focal-updates,now 8.0.31-0ubuntu0.20.04.2 amd64 [installed,automatic]
mysql-client-core-8.0/focal-updates,now 8.0.31-0ubuntu0.20.04.2 amd64 [installed,automatic]
mysql-client/focal-security,now 8.0.31-0ubuntu0.20.04.1 all [installed,upgradable to: 8.0.31-0ubuntu0.20.04.2]
mysql-common/focal,now 5.8+1.0.5ubuntu2 all [installed]
mysql-server-8.0/focal-security,now 8.0.31-0ubuntu0.20.04.1 amd64 [installed,upgradable to: 8.0.31-0ubuntu0.20.04.2]
mysql-server-core-8.0/focal-updates,now 8.0.31-0ubuntu0.20.04.2 amd64 [installed,auto-removable]
mysql-server/focal-security,now 8.0.31-0ubuntu0.20.04.1 all [installed,upgradable to: 8.0.31-0ubuntu0.20.04.2]
php-mysql/focal,now 2:7.4+75 all [installed,automatic]
php7.4-mysql/focal-updates,focal-security,now 7.4.3-4ubuntu2.15 amd64 [installed,automatic]

这是 dpkg 安装列表:

||/ Name                  Version                 Architecture Description
+++-=====================-=======================-============-===================================================================
ii  mysql-client          8.0.31-0ubuntu0.20.04.1 all          MySQL database client (metapackage depending on the latest version)
un  mysql-client-5.7      <none>                  <none>       (no description available)
ii  mysql-client-8.0      8.0.31-0ubuntu0.20.04.2 amd64        MySQL database client binaries
un  mysql-client-core-5.7 <none>                  <none>       (no description available)
ii  mysql-client-core-8.0 8.0.31-0ubuntu0.20.04.2 amd64        MySQL database core client binaries
ii  mysql-common          5.8+1.0.5ubuntu2        all          MySQL database common files, e.g. /etc/mysql/my.cnf
un  mysql-common-5.6      <none>                  <none>       (no description available)
ii  mysql-server          8.0.31-0ubuntu0.20.04.1 all          MySQL database server (metapackage depending on the latest version)
un  mysql-server-5.5      <none>                  <none>       (no description available)
un  mysql-server-5.7      <none>                  <none>       (no description available)
pFR mysql-server-8.0      8.0.31-0ubuntu0.20.04.1 amd64        MySQL database server binaries and system database setup
un  mysql-server-core-5.7 <none>                  <none>       (no description available)
ii  mysql-server-core-8.0 8.0.31-0ubuntu0.20.04.2 amd64        MySQL database server binaries

但我清除了所有mysql*文件libmysql*夹和/var/dpkg/lib/info文件 /var/cache/apt

有任何想法吗?

相关内容