阿里云轻量服务器ubuntu一直报错 unable to resolve host xxxxxxxx的解决的方案

1.切换到root

sudo su root

2.修改/etc/hosts文件:

sudo vi /etc/hosts

3.在127.0.0.1       localhost下面添加

127.0.0.1 localhost 报错的主机名

4.按Esc,输入

:wq

保存文件并退出。

 

博客参考:

https://yq.aliyun.com/articles/495245

https://blog.csdn.net/hhtnan/article/details/79551969

https://blog.csdn.net/feosun/article/details/73196299

全部评论

相关推荐

评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务