一 测试域名是否可达

1 ping

# ping www.baidu.com
PING www.a.shifen.com (220.181.112.244) 56(84) bytes of data.
64 bytes from 220.181.112.244 (220.181.112.244): icmp_seq=1 ttl=52 time=2.51 ms
64 bytes from 220.181.112.244 (220.181.112.244): icmp_seq=2 ttl=52 time=2.50 ms

2 nslookup

# nslookup www.baidu.com
Server: 103.224.222.222
Address: 103.224.222.222#53

Non-authoritative answer:
www.baidu.com canonical name = www.a.shifen.com.
Name: www.a.shifen.com
Address: 220.181.112.244

二 测试ip是否可达

1 ping

# ping 220.181.112.244
PING 220.181.112.244 (220.181.112.244) 56(84) bytes of data.
64 bytes from 220.181.112.244: icmp_seq=1 ttl=52 time=2.57 ms
64 bytes from 220.181.112.244: icmp_seq=2 ttl=52 time=2.55 ms

2 traceroute

# traceroute 220.181.112.244
traceroute to 220.181.112.244 (220.181.112.244), 30 hops max, 60 byte packets
1 * * *
2 * * *
3 100.127.3.117 (100.127.3.117) 0.933 ms * 100.127.3.115 (100.127.3.115) 1.055 ms
4 * * *
5 100.127.125.82 (100.127.125.82) 2.489 ms 100.127.125.80 (100.127.125.80) 2.475 ms 100.127.125.18 (100.127.125.18) 2.519 ms
6 180.149.137.117 (180.149.137.117) 7.877 ms 180.149.137.145 (180.149.137.145) 3.965 ms 100.127.125.10 (100.127.125.10) 2.341 ms
7 180.149.159.77 (180.149.159.77) 2.347 ms 180.149.159.57 (180.149.159.57) 2.456 ms 180.149.159.17 (180.149.159.17) 3.372 ms
8 * 36.110.246.201 (36.110.246.201) 7.804 ms 180.149.159.17 (180.149.159.17) 2.341 ms
9 * 220.181.0.109 (220.181.0.109) 2.997 ms 36.110.246.205 (36.110.246.205) 2.756 ms
10 * 220.181.17.94 (220.181.17.94) 2.962 ms 220.181.17.22 (220.181.17.22) 2.767 ms
11 * * 220.181.17.150 (220.181.17.150) 2.559 ms
12 * * *
13 * * *
14 * * *

三 测试端口是否可达

1 telnet

# telnet 220.181.112.244 80
Trying 220.181.112.244...
Connected to 220.181.112.244.
Escape character is '^]'.

2 nc

# nc 220.181.112.244 80 -v
Ncat: Version 7.50 ( https://nmap.org/ncat )
Ncat: Connected to 220.181.112.244:80.

3 curl

# curl http://220.181.112.244:80 -v
* Trying 220.181.112.244...
* TCP_NODELAY set
* Connected to 220.181.112.244 (220.181.112.244) port 80 (#0)
> GET / HTTP/1.1
> Host: 220.181.112.244
> User-Agent: curl/7.63.0
> Accept: */*
>
< HTTP/1.1 200 OK
< Accept-Ranges: bytes
< Cache-Control: private, no-cache, no-store, proxy-revalidate, no-transform
< Connection: Keep-Alive
< Content-Length: 2381
< Content-Type: text/html
< Date: Sat, 16 Feb 2019 02:35:56 GMT
< Etag: "588604c8-94d"
< Last-Modified: Mon, 23 Jan 2017 13:27:36 GMT
< Pragma: no-cache
< Server: bfe/1.0.8.18
< Set-Cookie: BDORZ=27315; max-age=86400; domain=.baidu.com; path=/
<
<!DOCTYPE html>

最新文章

  1. 《中国文明史》系列—外柔 VS 内厉
  2. bootstrap1
  3. kettle参数、变量详细讲解[转]
  4. BZOJ3931 [CQOI2015]网络吞吐量(最大流)
  5. JVM GC (一)
  6. Android平台上长连接的实现
  7. hql &amp; mysql 札记
  8. 字符串截取数字和点击radio显示不同内容
  9. HBase中的备份和故障恢复方法
  10. linux IPC总结——管道
  11. CTF---安全杂项入门第三题 这是捕获的黑客攻击数据包,Administrator用户的密码在此次攻击中泄露了,你能找到吗?
  12. HDFS命令全总结
  13. 为什么会存在using filesort
  14. 小强的HTML5移动开发之路(7)——坦克大战游戏1
  15. Echarts学习之路3(在react中使用)
  16. [转帖]Sqlcmd使用详解
  17. mysql修改字符集
  18. ios程序中存储的回忆
  19. Code once, debug everywhere.
  20. memory prefix inter,intra,intro,iso out 5

热门文章

  1. retry示例
  2. Kettle系列: kettle标准化trans模板
  3. 3.1HashMap源码分析
  4. JavaSE回顾及巩固的自学之路(一)——————前言
  5. 目前比较火的前端框架及UI组件
  6. 数组去重的4种方法(Which one is the fastest???嘻嘻嘻....)
  7. Springboot(一)概念
  8. Mybatis(二)入门程序-通过id查找用户、模糊查找用户、添加用户、删除用户
  9. python - 代码练习 - 备份目录/文件(windos环境)
  10. Spring重温(一)--Spring快速入门