我无法升级 Debian 9

我无法升级 Debian 9

我执行:sudo apt-get dist-upgrade我得到这个:

Reading Package Lists ... Done
Building the dependency tree
Reading status information ... Done
Calculation of the update ... Some packages can not be installed. This may mean
That you have asked for the impossible, or if you
Unstable distribution, which some packages have not yet
Have been created or have not been released from Incoming.
The following information should help you resolve the situation:

The following packages contain unsatisfied dependencies:
  Systemd: Break: rdnssd (<1.0.1-5) but 1.0.1-1 + b1 must be installed
E: Error, pkgProblem :: Resolve generated breaks, which could be caused by the packages to be kept as is.

输出apt-cache policy rdnssd

   Dmicaelandre @ ThinkPad: ~ $ apt-cache policy rdnssd
rdnssd:
  Installed: 1.0.1-1+b1
  Candidate: 1.0.3-3
  Version table:
      1.0.3-3 0
         650 http://ftp2.fr.debian.org/debian/ stretch/main amd64 Packages
  *** 1.0.1-1+b1 0
         100 /var/lib/dpkg/status

输出apt-cache policy

100 /var/lib/dpkg/status
     release a=now
 500 http://security.debian.org/ stretch/updates/non-free Translation-en
 500 http://security.debian.org/ stretch/updates/main Translation-en
 500 http://security.debian.org/ stretch/updates/contrib Translation-en
 650 http://security.debian.org/ stretch/updates/non-free i386 Packages
     release o=Debian,a=testing,n=stretch,l=Debian-Security,c=non-free
     origin security.debian.org
 650 http://security.debian.org/ stretch/updates/contrib i386 Packages
     release o=Debian,a=testing,n=stretch,l=Debian-Security,c=contrib
     origin security.debian.org
 650 http://security.debian.org/ stretch/updates/main i386 Packages
     release o=Debian,a=testing,n=stretch,l=Debian-Security,c=main
     origin security.debian.org
 650 http://security.debian.org/ stretch/updates/non-free amd64 Packages
     release o=Debian,a=testing,n=stretch,l=Debian-Security,c=non-free
     origin security.debian.org
 650 http://security.debian.org/ stretch/updates/contrib amd64 Packages
     release o=Debian,a=testing,n=stretch,l=Debian-Security,c=contrib
     origin security.debian.org
 650 http://security.debian.org/ stretch/updates/main amd64 Packages
     release o=Debian,a=testing,n=stretch,l=Debian-Security,c=main
     origin security.debian.org
 500 http://ftp2.fr.debian.org/debian/ stretch-updates/non-free Translation-en
 500 http://ftp2.fr.debian.org/debian/ stretch-updates/main Translation-en
 500 http://ftp2.fr.debian.org/debian/ stretch-updates/contrib Translation-en
 500 http://ftp2.fr.debian.org/debian/ stretch-updates/non-free i386 Packages
     release o=Debian,a=testing-updates,n=stretch-updates,l=Debian,c=non-free
     origin ftp2.fr.debian.org
 500 http://ftp2.fr.debian.org/debian/ stretch-updates/contrib i386 Packages
     release o=Debian,a=testing-updates,n=stretch-updates,l=Debian,c=contrib
     origin ftp2.fr.debian.org
 500 http://ftp2.fr.debian.org/debian/ stretch-updates/main i386 Packages
     release o=Debian,a=testing-updates,n=stretch-updates,l=Debian,c=main
     origin ftp2.fr.debian.org
 500 http://ftp2.fr.debian.org/debian/ stretch-updates/non-free amd64 Packages
     release o=Debian,a=testing-updates,n=stretch-updates,l=Debian,c=non-free
     origin ftp2.fr.debian.org
 500 http://ftp2.fr.debian.org/debian/ stretch-updates/contrib amd64 Packages
     release o=Debian,a=testing-updates,n=stretch-updates,l=Debian,c=contrib
     origin ftp2.fr.debian.org
 500 http://ftp2.fr.debian.org/debian/ stretch-updates/main amd64 Packages
     release o=Debian,a=testing-updates,n=stretch-updates,l=Debian,c=main
     origin ftp2.fr.debian.org
 500 http://ftp2.fr.debian.org/debian/ stretch/non-free Translation-en
 500 http://ftp2.fr.debian.org/debian/ stretch/main Translation-fr
 500 http://ftp2.fr.debian.org/debian/ stretch/main Translation-en
 500 http://ftp2.fr.debian.org/debian/ stretch/contrib Translation-en
 650 http://ftp2.fr.debian.org/debian/ stretch/non-free i386 Packages
     release o=Debian,a=testing,n=stretch,l=Debian,c=non-free
     origin ftp2.fr.debian.org
 650 http://ftp2.fr.debian.org/debian/ stretch/contrib i386 Packages
     release o=Debian,a=testing,n=stretch,l=Debian,c=contrib
     origin ftp2.fr.debian.org
 650 http://ftp2.fr.debian.org/debian/ stretch/main i386 Packages
     release o=Debian,a=testing,n=stretch,l=Debian,c=main
     origin ftp2.fr.debian.org
 650 http://ftp2.fr.debian.org/debian/ stretch/non-free amd64 Packages
     release o=Debian,a=testing,n=stretch,l=Debian,c=non-free
     origin ftp2.fr.debian.org
 650 http://ftp2.fr.debian.org/debian/ stretch/contrib amd64 Packages
     release o=Debian,a=testing,n=stretch,l=Debian,c=contrib
     origin ftp2.fr.debian.org
 650 http://ftp2.fr.debian.org/debian/ stretch/main amd64 Packages
     release o=Debian,a=testing,n=stretch,l=Debian,c=main
     origin ftp2.fr.debian.org

答案1

正如所暗示的阿罗切斯特的评论,删除该rdnssd包。

sudo apt-get remove rdnssd

这让我能够继续升级到 Debian 9。

这个软件包是一种 dns 自动配置守护进程。在我的系统上,它只是通过覆盖网络管理器的设置来定期破坏我的 DNS 设置。 (我知道,正是这个包在搜索相关信息时给我带来了 DNS 问题,以便了解如何解决升级问题。)
如果您不知道这个rdnssd包,也不知道什么是“使用递归 DNS 的 DNS 配置”服务器(RDNSS)选项”,很可能您实际上并不需要它。

答案2

我遇到了同样的错误。推荐的升级过程是:

  1. apt-get 更新
  2. apt-get 升级
  3. apt-get dist-upgrade

首先进行定期升级为我解决了这个问题。

相关内容