223.5.5.5出现curl: (6) Could not resolve host
作者:快盘下载 人气:在执行curl时,突然发现这个报错,问题是之前完全没有出现过这样的情况。
故障描述:
root@localhost ~]# curl -k https://www.kkpan.com/
curl: (6) Could not resolve host: www.kkpan.com; Unknown error
You have new mail in /var/spool/mail/root
测试ping
[root@localhost ~]# ping www.kkpan.com
ping: www.kkpan.com: Name or service not known
解决办法:
[root@localhost ~]# cat /etc/resolv.conf
nameserver 223.5.5.5
search localdomain
223.5.5.5是什么地址?
DNS223.5.5.5是由阿里巴巴提供的免费DNS服务器的IP地址;
果断直接修改resolv文件,改成114和谷歌的地址
[root@localhost ~]# cat /etc/resolv.conf
nameserver 114.114.114.114
nameserver 8.8.8.8
测试正常。。结果就不贴出来的。。
加载全部内容