linux 配置dns
[root@localhost ~]# echo "202.106.195.68">/etc/resolv.conf[root@localhost ~]# cat /etc/resolv.conf202.106.195.68[root@localhost ~]# echo "nameserver 202.106.195.68">/etc/resolv.conf--设置dns [root@localhost ~]# cat /etc/resolv.confnameserver 202.106.195.68[root@localhost ~]# ping www.baidu.comPING www.a.shifen.com (61.135.169.125) 56(84) bytes of data.64 bytes from 61.135.169.125: icmp_seq=0 ttl=55 time=15.0 ms64 bytes from 61.135.169.125: icmp_seq=1 ttl=55 time=16.4 ms--- www.a.shifen.com ping statistics ---2 packets transmitted, 2 received, 0% packet loss, time 1001msrtt min/avg/max/mdev = 15.095/15.775/16.455/0.680 ms, pipe 2[root@localhost ~]# service network restart--重启network服务Shutting down interface eth0: [ OK ]Shutting down loopback interface: [ OK ]Setting network parameters: [ OK ]Bringing up loopback interface: [ OK ]Bringing up interface eth0: [ OK ][root@localhost ~]# 202.106.195.68