PVE 虚拟机主机 更换国内源以及解决无效订阅的问题
创始人
2025-01-19 19:33:15
0

1、PVE更换国内源

 注:本文以 pve 7.3.3 为例。

替换前建议先更新下证书,否则可能由于证书不可用导致 https 无法使用,进而无法下载所有软件。

apt install apt-transport-https ca-certificates

首先替换通用软件源, Debian 的软件源配置文件是 /etc/apt/sources.list,备份后将其中内容修改为以下即可。

# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye main contrib non-free
deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-updates main contrib non-free

deb https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian/ bullseye-backports main contrib non-free

deb https://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free
# deb-src https://mirrors.tuna.tsinghua.edu.cn/debian-security bullseye-security main contrib non-free

 ctrl+x 再按Y,回车,就可以完成。

之后替换 pve 软件源,pve 镜像默认的 pve 软件源配置文件是 /etc/apt/sources.list.d/pve-enterprise.list ,备份后将其中内容替换为以下即可:(修改步骤同前面。)

deb https://mirrors.tuna.tsinghua.edu.cn/proxmox/debian bullseye pve-no-subscription

最后更新下,速度很快:

apt-get update

修改 CT Templates (LXC 容器) 源

/usr/share/perl5/PVE/APLInfo.pm 文件中默认的源地址 http://download.proxmox.com 替换为 https://mirrors.tuna.tsinghua.edu.cn/proxmox 即可。

可以使用如下命令修改:

cp /usr/share/perl5/PVE/APLInfo.pm /usr/share/perl5/PVE/APLInfo.pm_back
sed -i 's|http://download.proxmox.com|https://mirrors.tuna.tsinghua.edu.cn/proxmox|g' /usr/share/perl5/PVE/APLInfo.pm

针对 /usr/share/perl5/PVE/APLInfo.pm 文件的修改,重启后生效。

systemctl restart pvedaemon.service

之后在 pve 网页端下载 CT Templates 速度就很快了。

2、去除无效订阅

首先你可以登录shh工具,下载proxmoxlib.js这个js文件。 

在这个路径为:/usr/share/javascript/proxmox-widget-toolkit/proxmoxlib.js,用编辑工具搜索“data.status” 

 修改成

if (false) {

文件修改后保存上传,执行 systemctl restart pveproxy 命令重启网页服务

systemctl restart pveproxy

相关内容

热门资讯

黑科技讲解(wepoke软件透... 黑科技讲解(wepoke软件透明挂价格)外挂黑科技辅助器(透视)总是有挂(黑科技脚本)-哔哩哔哩亲,...
第5分钟黑科技!德扑之星ai软... 第5分钟黑科技!德扑之星ai软件,(德扑之星)竟然有挂,扑克教程(有挂方法)-哔哩哔哩;1、玩家可以...
黑科技安装!aapoker辅助... 黑科技安装!aapoker辅助工具下载(透视)太坑了真的是有挂(科技教程黑科技攻略)-哔哩哔哩;暗藏...
黑科技辅助挂(德扑之星发牌规律... 黑科技辅助挂(德扑之星发牌规律)外挂透明挂辅助软件(透视)果然真的有挂(黑科技解密)-哔哩哔哩1、每...
透视脚本!WPK最新ai辅助黑... 透视脚本!WPK最新ai辅助黑科技,(wPk)原来是真的有挂,黑科技自建房(有挂规律)-哔哩哔哩1、...
黑科技智能ai!智星德州菠萝a... 黑科技智能ai!智星德州菠萝app下载(透视)太坑了是真的有挂(可靠教程黑科技介绍)-哔哩哔哩;1)...
黑科技能赢(微扑克透牌软件)外... 黑科技能赢(微扑克透牌软件)外挂透明挂辅助器(透视)本来真的有挂(黑科技介绍)-哔哩哔哩进入游戏-大...
透视代打!wPK最新ai辅助黑... 透视代打!wPK最新ai辅助黑科技,(wpK)原来真的是有挂,黑科技规律(的确有挂)-哔哩哔哩1)辅...
黑科技讲解!德扑之星操作(智能... 黑科技讲解!德扑之星操作(智能ai)太坑了存在有挂(玩家教你黑科技介绍)-哔哩哔哩;暗藏猫腻,小编详...
黑科技规律(智星德州菠萝怎么看... 黑科技规律(智星德州菠萝怎么看有没有开挂)外挂透视辅助app(透视)切实真的有挂(黑科技攻略)-哔哩...