mityaya

问题:

[root@yaya ~]# 
yum -y install gcc-*
Loaded plugins: fastestmirror, presto
Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=os
error was
14: PYCURL ERROR 6 - "Couldn\'t resolve host \'mirrorlist.centos.org\'"
Error: Cannot retrieve repository metadata (repomd.xml) for repository: base. Please verify its path and try again

 

原因:
 dns服务器没有配置正确

 

解决办法:
1、打开文件/etc/resolv.conf在其中添加:

 nameserver 8.8.8.8
 nameserver 8.8.4.4

 

 

2、然后重启网卡:使用命令:

service network restart

问题解决

分类:

技术点:

相关文章:

  • 2021-09-15
  • 2022-12-23
  • 2021-12-07
  • 2022-12-23
  • 2022-02-21
猜你喜欢
  • 2021-09-23
  • 2021-10-06
  • 2022-12-23
  • 2021-09-24
  • 2022-12-23
  • 2022-12-23
  • 2021-11-06
相关资源
相似解决方案