AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / ubuntu / 问题 / 1184124
Accepted
DonP
DonP
Asked: 2019-10-27 22:47:14 +0800 CST2019-10-27 22:47:14 +0800 CST 2019-10-27 22:47:14 +0800 CST

升级到 Ubuntu 19.10 后,MySQL 失败

  • 772

我的系统提议从 19.04 升级,所以我让它,但有很多错误。现在 MySQL 将无法运行。在终端中运行它:

然:sudo dpkg --remove --force-all mysql-community-client libmysqlclient21:amd64 mysql-common mysql-community-client-core

dpkg: mysql-community-client: dependency problems, but removing anyway as you requested:
 dbconfig-mysql depends on default-mysql-client | virtual-mysql-client; however:
  Package default-mysql-client is not installed.
  Package virtual-mysql-client is not installed.
  Package mysql-community-client which provides virtual-mysql-client is to be removed.

(Reading database ... 533508 files and directories currently installed.)
Removing mysql-community-client (8.0.18-1ubuntu19.10) ...
dpkg: libmysqlclient21:amd64: dependency problems, but removing anyway as you requested:
 libvtk6.3 depends on libmysqlclient21 (>= 8.0.11); however:
  Package libmysqlclient21:amd64 is to be removed.
 libsnmp30:amd64 depends on libmysqlclient21 (>= 8.0.11).
 libqt4-sql-mysql:amd64 depends on libmysqlclient21 (>= 8.0.11).
 libgdal20 depends on libmysqlclient21 (>= 8.0.11).

Removing libmysqlclient21:amd64 (8.0.18-1ubuntu19.10) ...
Removing mysql-common (8.0.18-1ubuntu19.10) ...
Removing mysql-community-client-core (8.0.18-1ubuntu19.10) ...
Processing triggers for man-db (2.8.7-3) ...
Processing triggers for libc-bin (2.30-0ubuntu2) ...

然后运行:sudo apt install -f

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... failed.
The following packages have unmet dependencies:
 dbconfig-mysql : Depends: default-mysql-client but it is not installed or
                           virtual-mysql-client
 libgdal20 : Depends: libmysqlclient21 (>= 8.0.11) but it is not installed
 libqt4-sql-mysql : Depends: libmysqlclient21 (>= 8.0.11) but it is not installed
 libsnmp30 : Depends: libmysqlclient21 (>= 8.0.11) but it is not installed
 libvtk6.3 : Depends: libmysqlclient21 (>= 8.0.11) but it is not installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
E: Unable to correct dependencies

然:sudo dpkg --remove --force-all dbconfig-mysql;apt-get 下载 libmysqlclient21;sudo dpkg -i libmysqlclient21 .deb; sudo apt install -f*

dpkg: dbconfig-mysql: dependency problems, but removing anyway as you requested:
 phpmyadmin depends on dbconfig-mysql | dbconfig-no-thanks | dbconfig-common (<< 2.0.0); however:
  Package dbconfig-mysql is to be removed.
  Package dbconfig-no-thanks is not installed.
  Version of dbconfig-common on system is 2.0.11ubuntu2.

(Reading database ... 533425 files and directories currently installed.)
Removing dbconfig-mysql (2.0.11ubuntu2) ...
Get:1 http://repo.mysql.com/apt/ubuntu eoan/mysql-8.0 amd64 libmysqlclient21 amd64 8.0.18-1ubuntu19.10 [1,281 kB]
Fetched 1,281 kB in 8s (152 kB/s)                                              
Selecting previously unselected package libmysqlclient21:amd64.
(Reading database ... 533424 files and directories currently installed.)
Preparing to unpack libmysqlclient21_8.0.18-1ubuntu19.10_amd64.deb ...
Unpacking libmysqlclient21:amd64 (8.0.18-1ubuntu19.10) ...
dpkg: dependency problems prevent configuration of libmysqlclient21:amd64:
 libmysqlclient21:amd64 depends on mysql-common (>= 8.0.18-1ubuntu19.10); however:
  Package mysql-common is not installed.

dpkg: error processing package libmysqlclient21:amd64 (--install):
 dependency problems - leaving unconfigured
Processing triggers for libc-bin (2.30-0ubuntu2) ...
Errors were encountered while processing:
 libmysqlclient21:amd64
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... failed.
The following packages have unmet dependencies:
 libmysqlclient21 : Depends: mysql-common (>= 8.0.18-1ubuntu19.10)
 phpmyadmin : Depends: dbconfig-mysql but it is not installed or
                       dbconfig-no-thanks but it is not installed or
                       dbconfig-common (< 2.0.0) but 2.0.11ubuntu2 is installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.
E: Unable to correct dependencies

偶尔弹出的另一个错误是:

Error: GDBus.Error:org.freedesktop.systemd1.UnitMasked: Unit -.mount is masked.
mysql
  • 3 3 个回答
  • 4393 Views

3 个回答

  • Voted
  1. Best Answer
    Kulfy
    2019-11-16T23:05:20+08:002019-11-16T23:05:20+08:00

    来自评论:

    1. 使用以下命令强制删除 MySQL 相关包dpkg:

      sudo dpkg --remove --force-all mysql-server mysql-community-client mysql-common mysql-community-client-core libmysqlclient20 libmysqlclient21 mysql-client mysql-community-server-core mysql-community-server
      
    2. 使用 APT 再次安装 MySQL:

      sudo apt install mysql-server
      
    • 2
  2. crydotsnake
    2019-10-28T03:07:13+08:002019-10-28T03:07:13+08:00

    我先安装sudo apt install mysql-server,然后再安装sudo apt install php-mysql。我知道这很奇怪,但它确实有效。

    https://wiki.ubuntuusers.de/LAMP/

    • 0
  3. Pablo
    2019-11-06T18:12:19+08:002019-11-06T18:12:19+08:00

    跑:

    wget http://repo.mysql.com/mysql-apt-config_0.8.14-1_all.deb
    sudo dpkg -i mysql-apt-config_0.8.14-1_all.deb
    

    这将为您提供 Ubuntu Eoan (19.10) 的最新软件包。

    在安装屏幕上,选择软件包:

    设置

    最后,安装服务器:

    sudo apt-get update
    sudo apt-get install mysql-server
    
    • 0

相关问题

  • 上网本上的 MySQL 数据建模

  • 从终端备份mysql

  • 为什么 /etc/init.d/mysql 会运行错误的暴发户工作?

  • 将引号添加到文件中的字符串

  • 如何将 MySQL 数据文件移动到不同的分区?

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何运行 .sh 脚本?

    • 16 个回答
  • Marko Smith

    如何安装 .tar.gz(或 .tar.bz2)文件?

    • 14 个回答
  • Marko Smith

    如何列出所有已安装的软件包

    • 24 个回答
  • Marko Smith

    无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗?

    • 25 个回答
  • Martin Hope
    Flimm 如何在没有 sudo 的情况下使用 docker? 2014-06-07 00:17:43 +0800 CST
  • Martin Hope
    Ivan 如何列出所有已安装的软件包 2010-12-17 18:08:49 +0800 CST
  • Martin Hope
    La Ode Adam Saputra 无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗? 2010-11-30 18:12:48 +0800 CST
  • Martin Hope
    David Barry 如何从命令行确定目录(文件夹)的总大小? 2010-08-06 10:20:23 +0800 CST
  • Martin Hope
    jfoucher “以下软件包已被保留:”为什么以及如何解决? 2010-08-01 13:59:22 +0800 CST
  • Martin Hope
    David Ashford 如何删除 PPA? 2010-07-30 01:09:42 +0800 CST

热门标签

10.10 10.04 gnome networking server command-line package-management software-recommendation sound xorg

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve