TypechoJoeTheme

主机评测

主机评测

专注VPS评测和优惠码发布

Debian10无法apt更新解决办法

2023-06-09
/
0 评论
/
1,818 阅读
/
正在检测是否收录...
06/09

在我们使用Debian10系统中,如果我们使用更新,大概会出现如下所示的错误

root@localhost:~# apt-get update
Get:1 http://ftp.debian.org/debian buster InRelease [122 kB]
Get:2 http://security.debian.org buster/updates InRelease [65.4 kB]
Get:3 http://ftp.debian.org/debian buster-updates InRelease [51.9 kB]
Reading package lists... Done
E: Repository 'http://security.debian.org buster/updates InRelease' changed its 'Suite' value from 'stable' to 'oldstable'
N: This must be accepted explicitly before updates for this repository can be applied. See apt-secure(8) manpage for details.
N: Repository 'http://ftp.debian.org/debian buster InRelease' changed its 'Version' value from '10.7' to '10.11'
E: Repository 'http://ftp.debian.org/debian buster InRelease' changed its 'Suite' value from 'stable' to 'oldstable'
N: This must be accepted explicitly before updates for this repository can be applied. See apt-secure(8) manpage for details.
E: Repository 'http://ftp.debian.org/debian buster-updates InRelease' changed its 'Suite' value from 'stable-updates' to 'oldstable-updates'
N: This must be accepted explicitly before updates for this repository can be applied. See apt-secure(8) manpage for details.

但是这是Debian10,又不是CentOS8,应该会有个解决方案的。经过我在Google上寻找,终于得到解决方案了
只需运行这两条命令即可

apt-get --allow-releaseinfo-change update
apt-get dist-upgrade

这两条命令都是在Debian系统中使用的包管理器 APT 的命令。其中:

apt-get --allow-releaseinfo-change update:这条命令的作用是更新软件源信息,获取最新的软件包列表。其中的 "--allow-releaseinfo-change" 参数是允许在更新软件源信息时更改发行版信息,这通常用于解决软件包依赖关系的问题。

apt-get dist-upgrade:这条命令的作用是升级系统中所有已安装的软件包,包括那些因为依赖关系而不能自动升级的软件包。与 apt-get upgrade 命令不同,dist-upgrade 命令会自动处理依赖关系,确保所有软件包都能升级到最新版本。

需要注意的是,执行这两条命令需要管理员权限。在执行升级操作前,建议先备份重要数据,以免数据丢失。

Debian10apt
朗读
赞 · 0
赞赏
感谢您的支持,我会继续努力哒!
打开微信扫一扫,即可进行打赏哦!
版权属于:

主机评测

本文链接:

https://zjpc.cc/1312.html(转载时请注明本文出处及文章链接)

评论 (0)