我在多个 Proxmox Hypervisor 上运行多个 Ubuntu 20.04 服务器。
1 台服务器刚刚遇到了 apt 更新问题,但其他服务器都正常。Ubuntu 服务器版本都是相同的 (20.04.2),并且都只运行 CLI。
所有服务器 /etc/apt/sources.list 都是相同的 我在 1 个服务器上看到的错误是
Err:1 http://security.ubuntu.com/ubuntu focal-security InRelease
400 Bad Request [IP: 91.189.91.39 80]
Err:2 http://ubuntu.mirror.serversaustralia.com.au/ubuntu focal InRelease
400 Bad Request [IP: 27.50.85.5 80]
Reading package lists...
E: The repository 'http://security.ubuntu.com/ubuntu focal-security InRelease' is not signed.
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/focal-security/InRelease 400 Bad Request [IP: 91.189.91.39 80]
E: The repository 'http://ubuntu.mirror.serversaustralia.com.au/ubuntu focal InRelease' is not signed.
E: Failed to fetch http://ubuntu.mirror.serversaustralia.com.au/ubuntu/dists/focal/InRelease 400 Bad Request [IP: 27.50.85.5 80]
Run Code Online (Sandbox Code Playgroud)
所有其他服务器都更新良好,都位于同一子网、相同的 DNS、网关等。下面是在其他服务器之一上执行的相同“sudo apt update”命令
Hit:1 http://ubuntu.mirror.serversaustralia.com.au/ubuntu focal InRelease
Hit:2 http://security.ubuntu.com/ubuntu focal-security InRelease
Reading package lists...
Building dependency tree...
Reading state information...
All packages are up to date.
Run Code Online (Sandbox Code Playgroud)
我尝试安装“inetutils-traceroute”,但由于存储库已损坏而无法安装。我可以从任何其他服务器跟踪到 security.ubuntu.com ,没有任何问题。
这是一个生产服务器,我可以回滚到以前的快照,但相信聪明的社区可以为我指明正确的方向。由于这是一个生产服务器,我不会“玩弄”它的设置。
我必须认真编辑 /etc/apt/sources.list
转换了的所有实例
deb http://ubuntu.mirror.serversaustralia.com.au/ubuntu/ focal main
deb http://security.ubuntu.com/ubuntu/ focal-security main
Run Code Online (Sandbox Code Playgroud)
到另一个存储库并在每一行包含 trust=yes
deb [trusted=yes] https://mirror.internet.asn.au/pub/ubuntu/archive/ focal main
deb [trusted=yes] https://mirror.internet.asn.au/pub/ubuntu/archive/ focal-security main
Run Code Online (Sandbox Code Playgroud)
之后apt更新并升级了服务器。耶!
应用升级后,我再次编辑sources.list并删除“[trusted=yes]”的所有实例。重新测试并全部 AOK
归档时间: |
|
查看次数: |
15482 次 |
最近记录: |