最新消息:20190717 VPS服务器:Vultr新加坡,WordPress主题:大前端D8,统一介绍入口:关于

【记录】关于ping 二级域名的细节

工作和技术 crifan 1660浏览 0评论

ping 二级域名,加上http://的话,则是主域名的地址

➜  ~ ping http://hd.webonn.com
PING http://hd.webonn.com (202.102.110.204): 56 data bytes
Request timeout for icmp_seq 0
Request timeout for icmp_seq 1
Request timeout for icmp_seq 2
Request timeout for icmp_seq 3
Request timeout for icmp_seq 4
Request timeout for icmp_seq 5
Request timeout for icmp_seq 6
Request timeout for icmp_seq 7
Request timeout for icmp_seq 8
Request timeout for icmp_seq 9
^C

<div–<- http://hd.webonn.com ping statistics —

11 packets transmitted, 0 packets received, 100.0% packet loss

直接ping二级域名,不带http://,才是真实的,地址:

➜  ~ ping hd.webonn.com
PING hd.webonn.com (115.29.173.126): 56 data bytes
64 bytes from 115.29.173.126: icmp_seq=0 ttl=54 time=14.580 ms
64 bytes from 115.29.173.126: icmp_seq=1 ttl=54 time=12.879 ms
64 bytes from 115.29.173.126: icmp_seq=2 ttl=54 time=13.734 ms
64 bytes from 115.29.173.126: icmp_seq=3 ttl=54 time=13.406 ms
64 bytes from 115.29.173.126: icmp_seq=4 ttl=54 time=24.214 ms
64 bytes from 115.29.173.126: icmp_seq=5 ttl=54 time=15.061 ms
^C

<div–<- hd.webonn.com ping statistics —

6 packets transmitted, 6 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 12.879/15.646/24.214/3.899 ms
➜  ~

而再去ping主域名,则又是别的地址:

➜  ~ ping www.webonn.com
PING webonn.com (112.124.12.74): 56 data bytes
64 bytes from 112.124.12.74: icmp_seq=0 ttl=54 time=20.276 ms
64 bytes from 112.124.12.74: icmp_seq=1 ttl=54 time=16.805 ms
^C

<div–<- webonn.com ping statistics —

2 packets transmitted, 2 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 16.805/18.541/20.276/1.735 ms
➜  ~

对于hd.webonn.com的ping,是否加上http://,结果却还不一样,感觉很是奇怪。

ping with http://

ping – Difference between pinging with and without http:// – Super User

-》ping的参数应该是hostname或IP(而不是http开头的URL)

-》ping带http://开头的,理论上应该无法工作,ping不通才对

-〉和我想的一样

-》但是为何上面可以ping通???

转载请注明:在路上 » 【记录】关于ping 二级域名的细节

发表我的评论
取消评论

表情

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址
50 queries in 0.155 seconds, using 18.75MB memory