安装git依赖环境出现Couldn't resolve host 'mirrorlist.centos.org

安装git依赖环境的时候出现如下:
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 find a valid baseurl for repo: base

解决方法:切换到/etc目录下,使用vim命令编辑resolv.conf文件,在下方添加一行nameserver 8.8.8.8,然后wq保存即可。

发布了38 篇原创文章 · 获赞 11 · 访问量 1779

猜你喜欢

转载自blog.csdn.net/weixin_44247784/article/details/104089358
今日推荐