树挪死,人挪活。
大城市小人物,生活最终会把你变成你讨厌的人。
下载wget 本地服务器搭建(2.4)---Centos基本软件安装介绍
yum install -y wget
备份默认的yum
mv /etc/yum.repos.d /etc/yum.repos.d.backup
设置新的yum目录
mkdir /etc/yum.repos.d
下载阿里yum配置到该目录中
CentOS 5
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo
或者
curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-5.repo
CentOS 6
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
或者
curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-6.repo
CentOS 7
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
或者
curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
重建缓存
yum clean all
yum makecache
升级所有包(改变软件设置和系统设置,系统版本内核都升级,故需要几分钟耐心等待)
yum update -y