报错

使用Proxmox VE默认的APT更新源,在WEB管理面板点击更新或者ssh登录服务器执行apt-get update的时候,会显示错误:

TASK ERROR: command 'apt-get update' failed: exit code 100

原因

因为默认的更新源为Proxmox VE企业版的订阅,我们没有购买订阅,就会提示签名错误,从而APT更新失败。

解决

解决的办法很简单,就是更换软件源就可以了。 Proxmox官方提供了对应不同版本的源,可以根据自己的情况进行选择。

root@pve:~# vim /etc/apt/sources.list.d/pve-enterprise.list
#deb https://enterprise.proxmox.com/debian/pve bullseye pve-enterprise

root@pve:~# vim/etc/apt/sources.list
deb http://ftp.debian.org/debian bullseye main contrib
deb http://ftp.debian.org/debian bullseye-updates main contrib

# PVE pve-no-subscription repository provided by proxmox.com,
# NOT recommended for production use // 生产环境慎用
deb http://download.proxmox.com/debian/pve bullseye pve-no-subscription

# security updates
deb http://security.debian.org/debian-security bullseye-security main contrib

root@pve:~# apt update && apt dist-upgrade
root@pve:~# reboot

参考资料

文章目录