损坏的 ubuntu-advantage-tools 和 ubuntu-pro-client 之间的冲突导致更新中断

损坏的 ubuntu-advantage-tools 和 ubuntu-pro-client 之间的冲突导致更新中断

我在 20.04 LTS 上安装 Ubuntu-pro 失败(不小心按了软件更新程序上的营销按钮),现在纠正这个问题的努力导致 ubuntu-advantage-tools 和 ubuntu-pro-clients 之间出现依赖冲突。有人遇到过同样的问题吗?有明显的解决办法吗?Aptitude 运行了几个小时然后停了下来。

~$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 ubuntu-advantage-tools : Depends: ubuntu-pro-client (>= 31.2~20.04) but it is not installed
 ubuntu-pro-client-l10n : Depends: ubuntu-pro-client (= 31.2~20.04) but it is not installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

$ sudo apt --fix-broken install
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following additional packages will be installed:
  ubuntu-pro-client
The following NEW packages will be installed:
  ubuntu-pro-client
0 upgraded, 1 newly installed, 0 to remove and 55 not upgraded.
2 not fully installed or removed.
Need to get 0 B/196 kB of archives.
After this operation, 1,116 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 413409 files and directories currently installed.)
Preparing to unpack .../ubuntu-pro-client_31.2~20.04_amd64.deb ...
Unpacking ubuntu-pro-client (31.2~20.04) ...
dpkg: error processing archive /var/cache/apt/archives/ubuntu-pro-client_31.2~20.04_amd64.deb (--unpack):
 trying to overwrite '/etc/apt/apt.conf.d/20apt-esm-hook.conf', which is also in package ubuntu-advantage-tools 31.2~20.04
dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
Errors were encountered while processing:
 /var/cache/apt/archives/ubuntu-pro-client_31.2~20.04_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1) 

编辑:建议删除 ubuntu-advantage-tools,但这并不能解决这个问题,因为此功能不容易删除。

dpkg: error processing package ubuntu-advantage-tools (--purge):
 dependency problems - not removing
Errors were encountered while processing:
 ubuntu-advantage-tools

相关内容