yum安装时出现错误[Errno 14]
[root@localhost home]# yum install yum-utils
执行命令报错, 结果如下:
总下载量:1.5 M
Downloading packages:
Delta RPMs disabled because /usr/bin/applydeltarpm not installed.
yum-utils-1.1.31-54.el7_8.noar FAILED
http://mirrors.163.com/centos/7/os/x86_64/Packages/yum-utils-1.1.31-54.el7_8.noarch.rpm: [Errno 14] curl#6 - "Could not resolve host: mirrors.163.com; Unknown error" 0 B --:--:-- ETA
正在尝试其它镜像。
Error downloading packages:
yum-utils-1.1.31-54.el7_8.noarch: [Errno 256] No more mirrors to try.
解决办法:
[root@localhost ~]# vim /etc/resolv.conf # Generated by NetworkManager search localdomain nameserver 0.0.0.0 #向resolv.conf文件中添加下面内容 nameserver 114.114.114.114
参考:https://blog.csdn.net/qq_44160357/article/details/104179092