前言

  • PVE 默认是企业源,所有没有付费肯定是会失败的,会报错 TASK ERROR: command 'apt-get update' failed: exit code 100
  • 9.x 和 8.x 的解决方式不一样,按照网上搜的肯定也会失败

解决

9.x

  1. 在这两个文件的最后加上 Enabled: no 禁用企业源

    1
    2
    3
    4
    5
    # 文件 1
    nano /etc/apt/sources.list.d/pve-enterprise.sources

    # 文件 2
    nano /etc/apt/sources.list.d/ceph.sources
  2. 新建社区源

    1
    nano /etc/apt/sources.list.d/pve-no-subscription.sources

    并写入下列内容

    1
    2
    3
    4
    5
    Types: deb
    URIs: http://download.proxmox.com/debian/pve
    Suites: trixie
    Components: pve-no-subscription
    Signed-By: /usr/share/keyrings/proxmox-archive-keyring.gpg
  3. 更新并验证

    1
    apt-get update

8.x