【网络】常用命令详解

系统+安全 Liemer_Lius 26℃

1、DNS检查

nslookup命令是检查DNS解析是否正常的命令,需要安装bind-utils包:

> yum install -y bind-utils
> nslookup www.a.shifen.com 8.8.8.8  # 可以直接键入域名进行解析,最后一个字段是DNS的ip地址
Server:		8.8.8.8
Address:	8.8.8.8#53

Non-authoritative answer:
www.a.shifen.com	canonical name = www.wshifen.com.
Name:	www.wshifen.com
Address: 103.235.46.39

> nslookup www.a.shifen.com   # 也可以不填写,使用默认域名DNS
Server:		114.114.114.114
Address:	114.114.114.114#53

Non-authoritative answer:
Name:	www.a.shifen.com
Address: 110.242.68.4
Name:	www.a.shifen.com
Address: 110.242.68.3

> nslookup www.skelchina.com.cn   # 如果没有则报找不到
Server:		114.114.114.114
Address:	114.114.114.114#53

** server can't find www.skelchina.com.cn: NXDOMAIN

 

 

 

 

 

 

 

 

转载请注明:skelchina.com » 【网络】常用命令详解

喜欢 (3)