Linux 升级yum
当使用yum进行升级的时候,无法升到最新版,就要升级yum啦
- sudo yum update openssl
- 最新版是1.1.1,就要升级yum啦
操作如下:
- 备份yum repo
sudo mv /etc/yum.repos.d /etc/yum.repos.d.backup- 创建yum repo
sudo mkdir /etc/yum.repos.d
cd /etc/yum.repos.d- 下载阿里yum
sudo yum install -y wget
wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo- 重建cache
sudo yum clean all
sudo yum makecache- 升级所有包
sudo yum update -y