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

相关内容

热门资讯

一分钟了解(德扑之星规律)外挂... 一分钟了解(德扑之星规律)外挂辅助工具(透视)揭秘教程(2021已更新)(哔哩哔哩);1、点击下载安...
5分钟了解(青云)外挂透明挂辅... 5分钟了解(青云)外挂透明挂辅助挂(辅助挂)解说技巧(2024已更新)(哔哩哔哩);亲真的是有正版授...
6分钟了解(云梦司缘)外挂辅助... 6分钟了解(云梦司缘)外挂辅助神器(透视)详细教程(2025已更新)(哔哩哔哩);云梦司缘是一项云梦...
第五分钟了解(粤友圈)外挂透明... 第五分钟了解(粤友圈)外挂透明挂辅助下载(辅助挂)教你攻略(2023已更新)(哔哩哔哩);粤友圈是一...
3分钟了解(旋转光线)外挂透明... 3分钟了解(旋转光线)外挂透明挂辅助软件(辅助挂)透牌教程(2020已更新)(哔哩哔哩);亲,有的,...
3分钟了解(搜圈)外挂辅助黑科... 3分钟了解(搜圈)外挂辅助黑科技(辅助挂)详细教程(2023已更新)(哔哩哔哩);1、让任何用户在无...
第9分钟了解(熊猫互娱)外挂透... 第9分钟了解(熊猫互娱)外挂透明挂辅助黑科技(透视)wepoke教程(2025已更新)(哔哩哔哩);...
七分钟了解(蜀州麻将云县)外挂... 您好:蜀州麻将云县这款游戏可以开挂的,确实是有挂的,很多玩家在这款游戏中打牌都会发现很多用户的牌特别...
1分钟了解(PG电子)外挂辅助... 1分钟了解(PG电子)外挂辅助app(辅助挂)黑科技教程(2024已更新)(哔哩哔哩)是一款可以让一...
第6分钟了解(新好游)外挂辅助... 第6分钟了解(新好游)外挂辅助助手(辅助挂)切实教程(2020已更新)(哔哩哔哩);1、点击下载安装...