更换yum源,再重新安装 wget
1.先进入到yum源文件:cd /etc/yum.repos.d/
2.到网易和阿里开源镜像站点下载系统对应版本的repo,http://mirrors.aliyun.com/repo/Centos-7.repo
3.将CenterOS-Base.repo备份,把下载的Centos-7.repo上传并把名称改为CenterOS-Base.repo
4.进入yum文件夹:cd /yum
5.创建文件夹repodata:mkdir repodata
6.进入repodata:cd repodata
7.将repomd.xml 和 e87982a7d437db5420d7a3821de1bd4a7b145d57a64a3a464cdeed198c4c1ad5-primary.sqlite.bz2 两个文件上传到repodata中(阿里的源需要从阿里服务器中拷贝出来,本人使用阿里源,直接复制链接到网盘获取,链接:链接:https://pan.baidu.com/s/1F9Txk5dEatqhXrFsOgsbiQ 提取码:1874
8.清除系统yum 缓存:yum clean all
9.生成yum缓存:yum makecache
10.卸载本来的wget:yum remove wget
11.重新安装wget:yum -y install wget
网友评论