现象:yum下令不能使用会报下面错误
已加载插件:fastestmirror, langpacks
File contains no section headers.
file: file:///etc/yum.repos.d/nginx.repo, line: 1
‘nx-stable]\n’
解决方法:
1.rm -f /etc/yum.repos.d/*
然后重新下载阿里的:
2.wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
清算缓存:
3.yum clean all