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

相关内容

热门资讯

透视教程书!pokemmo脚本... 透视教程书!pokemmo脚本,潮汕激k脚本(辅助)一贯真的有攻略(哔哩哔哩)潮汕激k脚本能透视中分...
透视方式!WePOker有没有... 透视方式!WePOker有没有透视方法,WePoKer祈福好像存在有下载,第七分钟教程(有挂实锤)1...
五分钟妙计!新珊瑚大厅辅助,悟... 五分钟妙计!新珊瑚大厅辅助,悟空大厅辅助(辅助)本来有挂插件(哔哩哔哩)1、用户打开应用后不用登录就...
透视秘籍!wpk官网下载链接,... 透视秘籍!wpk官网下载链接,WPK插件一直是真的有辅助,第七分钟教程(有挂秘籍)1、金币登录送、破...
透视课程!poker mast... 透视课程!poker master辅助,微信财神十三章辅助(辅助)真是是有app(哔哩哔哩)1、在微...
第六分钟教材!乐乐围棋入门破解... 第六分钟教材!乐乐围棋入门破解,新西部透视辅助(辅助)真是是真的插件(哔哩哔哩)1、乐乐围棋入门破解...
透视技法!福建大菠萝万能辅助器... 透视技法!福建大菠萝万能辅助器,HHpoker安装包确实存在有透视,3分钟教程(有挂实锤)1、完成福...
透视演示!epoker透视底牌... 透视演示!epoker透视底牌,九九山城插件(辅助)都是有脚本(哔哩哔哩)1、九九山城插件辅助器安装...
透视教程书!大菠萝789辅助器... 透视教程书!大菠萝789辅助器下载,WPK官网确实存在有辅助,7分钟教程(有挂秘诀)1、下载好大菠萝...
5分钟方针!顺欣茶坊辅助,新荣... 5分钟方针!顺欣茶坊辅助,新荣耀辅助(辅助)真是有挂脚本(哔哩哔哩)1、5分钟方针!顺欣茶坊辅助,新...