在Linux/Windows系统上编辑/etc/hosts文件

Linux ubuntu16

open the terminal, input the command:

  sudo -i gedit /etc/hosts file

click enter key, then input your password, click enter key, the hosts file will be open, now you can edit it.

Windows (win7/win8)

  C:\Windows\System32\driver\etc\hosts

open the hosts, now you can edit it.

 在Ubuntu系统上查看IP地址,在控制台(terminal)上输入指令:ip addr

posted @ 2016-11-18 16:56  留白*  阅读(1604)  评论(0编辑  收藏  举报