Mariadb 软件包损坏

Mariadb 软件包损坏

我陷入了困境,不知道该怎么办了。我试图安装 Mariadb,但不知何故这些错误一直存在。

dpkg: regarding .../mariadb-client-core-10.3_1%3a10.3.23+maria~focal_amd64.deb containing mariadb-client-core-10.3:  mariadb-client-10.3 conflicts with mysql-client-core-5.5   mariadb-client-core-10.3 provides mysql-client-core-5.5 and is to be installed.

dpkg: error processing archive
/var/cache/apt/archives/mariadb-client-core-10.3_1%3a10.3.23+maria~focal_amd64.deb
(--unpack):  conflicting packages - not installing
mariadb-client-core-10.3

dpkg: regarding
.../mariadb-client-10.3_1%3a10.3.23+maria~focal_amd64.deb containing
mariadb-client-10.3:  mariadb-client-core-10.3 conflicts with
mysql-client-5.5   mariadb-client-10.3 provides mysql-client-5.5 and
is to be installed.

dpkg: error processing archive
/var/cache/apt/archives/mariadb-client-10.3_1%3a10.3.23+maria~focal_amd64.deb
(--unpack):  conflicting packages - not installing mariadb-client-10.3

Preparing to unpack .../mysql-common_1%3a10.3.23+maria~focal_all.deb
... Unpacking mysql-common (1:10.3.23+maria~focal) over
(5.8+1.0.5ubuntu2) ... Errors were encountered while processing: 
/var/cache/apt/archives/mariadb-client-core-10.3_1%3a10.3.23+maria~focal_amd64.deb
/var/cache/apt/archives/mariadb-client-10.3_1%3a10.3.23+maria~focal_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

我已经尝试过这些

sudo apt-get install -f 
sudo apt-get remove --purge mariadb* 
sudo apt-get remove --purge mysql* 
sudo dpkg -i --force-overwrite-all /var/cache/apt/archives/ 
sudo apt-get autoremove

请帮助我,因为我无法安装任何东西

答案1

本指南很有帮助:

如何在 ubuntu 中删除损坏的软件包

sudo dpkg --remove --force-remove-reinstreq mariadb-server mariadb-server-10.3 mariadb-client-10.3
sudo apt-get update
sudo reboot
sudo apt-get upgrade
sudo apt install mariadb-server

相关内容