Linux VPS一键更换软件源脚本

发布于 / 教程 / Linux VPS一键更换软件源脚本已关闭评论


在安装软件时,有时候会遇到Linux的源更新速度非常的缓慢,特别是在国内使用默认的源,在这种情况下,更换一个更适合或者说更近,更快的软件源,会为你的Linux安装更新操作更加的流畅和顺利。
使用
系统要求:CentOS 5+、Ubuntu 14.04+、Debian 7+

使用命令:

#下载脚本
wget git.io/superupdate.sh
#运行脚本
bash superupdate.sh
如果第一步你出现错误或执行后无任何输出,请检查是否安装wget和ca-certificates,使用命令:

或者
国内用户
bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh)

国外用户
bash <(curl -sSL https://raw.githubusercontent.com/SuperManito/LinuxMirrors/main/ChangeMirrors.sh) --abroad

查看支持的软件源

#Debian、Ubuntu
apt-get install -y wget && apt-get install -y ca-certificates
#CentOS
yum install -y wget && yum install -y ca-certificates
对于Debian默认换源为Fastly CDN的mirror这个源有Fastly的加持对境外主机都有不错的速度。对于Ubuntu和 CentOS系统都默认换为阿里云的mirror,这个源有阿里云全球CDN的加持,全球都有不错的速度。

没有评论权限