TCP/IP 笔记 7 Ping
lenovo-myc@lenovomyc-Lenovo-Product:~$ ping www.baidu.com
PING www.a.shifen.com (123.125.65.82) () bytes of data. 这句出现前的延时,为DNS对域名的解析时间
bytes from 123.125.65.82: icmp_seq= ttl= time=2.60 ms 这句time如果较长,可能是发送ARP请求和接受ARP应答所花的时间
bytes from 123.125.65.82: icmp_seq= ttl= time=3.36 ms
bytes from 123.125.65.82: icmp_seq= ttl= time=2.38 ms
bytes from 123.125.65.82: icmp_seq= ttl= time=2.75 ms
bytes from 123.125.65.82: icmp_seq= ttl= time=3.64 ms
^C
--- www.a.shifen.com ping statistics ---
packets transmitted, received, % packet loss, time 4006ms
rtt min/avg/max/mdev = 2.382/2.950/3.647/0.480 ms lenovo-myc@lenovomyc-Lenovo-Product:~$ ping 123.125.65.78
PING 123.125.65.78 (123.125.65.78) () bytes of data.
bytes from 123.125.65.78: icmp_seq= ttl= time=2.45 ms
bytes from 123.125.65.78: icmp_seq= ttl= time=2.35 ms
bytes from 123.125.65.78: icmp_seq= ttl= time=2.19 ms
bytes from 123.125.65.78: icmp_seq= ttl= time=2.94 ms
bytes from 123.125.65.78: icmp_seq= ttl= time=2.59 ms
bytes from 123.125.65.78: icmp_seq= ttl= time=2.71 ms
bytes from 123.125.65.78: icmp_seq= ttl= time=2.57 ms
^C
--- 123.125.65.78 ping statistics ---
packets transmitted, received, % packet loss, time 6008ms
rtt min/avg/max/mdev = 2.193/2.547/2.947/0.232 ms
ping -s packetsize 指定数据包大小,默认为56
-s packetsize
Specifies the number of data bytes to be sent. The default is
56, which translates into 64 ICMP data bytes when combined with
the 8 bytes of ICMP header data.
lenovo-myc@lenovomyc-Lenovo-Product:~$ ping -s www.baidu.com
PING www.a.shifen.com (220.181.112.244) () bytes of data.
bytes from 220.181.112.244: icmp_seq= ttl=
bytes from 220.181.112.244: icmp_seq= ttl=
bytes from 220.181.112.244: icmp_seq= ttl=
bytes from 220.181.112.244: icmp_seq= ttl=
bytes from 220.181.112.244: icmp_seq= ttl=
^C
--- www.a.shifen.com ping statistics ---
packets transmitted, received, % packet loss, time 5006ms
查看中间路由。。。没找到可以测的网址
lenovo-myc@lenovomyc-Lenovo-Product:~$ ping -R www.baidu.com
PING www.a.shifen.com (220.181.111.188) () bytes of data.
bytes from 220.181.111.188: icmp_seq= ttl= time= ms
NOP
RR: 220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188 bytes from 220.181.111.188: icmp_seq= ttl= time= ms
NOP
RR: 220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188 bytes from 220.181.111.188: icmp_seq= ttl= time= ms
NOP
RR: 220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188 bytes from 220.181.111.188: icmp_seq= ttl= time= ms
NOP
RR: 220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188
220.181.111.188 ^C
--- www.a.shifen.com ping statistics ---
packets transmitted, received, % packet loss, time 4006ms
rtt min/avg/max/mdev = 176.328/181.574/186.643/4.214 ms
ping同一个网段
lenovo-myc@lenovomyc-Lenovo-Product:~$ ping -R 10.100.156.2
PING 10.100.156.2 (10.100.156.2) () bytes of data.
bytes from 10.100.156.2: icmp_seq= ttl= time=2.30 ms
NOP
RR: 10.100.156.2
10.100.156.2
10.100.156.2
10.100.156.2 bytes from 10.100.156.2: icmp_seq= ttl= time=2.53 ms
NOP (same route)
bytes from 10.100.156.2: icmp_seq= ttl= time=1.11 ms
NOP (same route)
bytes from 10.100.156.2: icmp_seq= ttl= time=4.45 ms
NOP (same route)
^C
--- 10.100.156.2 ping statistics ---
packets transmitted, received, % packet loss, time 4005ms
rtt min/avg/max/mdev = 1.110/2.602/4.459/1.200 ms
TCP/IP 笔记 7 Ping的更多相关文章
- TCP/IP笔记(1)
TCP/IP 背景和介绍 上世纪 70 年代,随着计算机技术的发展,计算机使用者意识到:要想发挥计算机更大的作用,就要将世界各地的计算机连接起来.但是简单的连接是远远不够的,因为计算机之间无法沟通.因 ...
- TCP/IP 笔记 - 用户数据报协议和IP分片
关于本章中的IP分片部分,参考第五章IP分片头部知识点.需要注意的是,TCP有超时重传,UDP的超时重传则依赖上层应用程序实现. 用户数据报协议(UDP) UDP是一个简单的面向无连接.不可靠的数据报 ...
- TCP/IP 笔记 - ICMPv4和ICMPv6 : Internet控制报文协议
ICMP是一种面向无连接的协议,负责传递可能需要注意的差错和控制报文,差错指示通信网络是否存在错误(如目的主机无法到达.IP路由器无法正常传输数据包等.注意,路由器缓冲区溢出导致的丢包不包括在ICMP ...
- TCP/IP笔记 一.综述
1. TCP/IP分层 TCP/IP 是四层的体系结构:应用层.运输层.网际层和网络接口层,如下图: OSI协议是国际标准的网络协议,但是由于OSI的实用性等问题造成OSI没有流行起来.目前国际上广泛 ...
- TCP/IP笔记 二.网络层(1)
1. IP 1.1 配套协议 IP 是 TCP/IP 体系中两个最主要的协议之一 . 与 IP 协议配套使用的还有四个协议: (1)ARP (Address Resolution Protocol ...
- TCP/IP笔记(二)TCP/IP简介
上回,主要介绍了下协议和OSI参考模型,并简单了解下网络构成要素,这回该说说TCP/IP了 互联网与TCP/IP的关系 互联网进行通信时,需要相应的网络协议,TCP/IP原本就是为使用互联网而开发 ...
- TCP/IP笔记(三)数据链路层
数据链路的作用 数据链路层的协议定义了通过通信媒介互连的设备之间传输的规范.通信媒介包括双绞线电缆.同轴电缆.光纤.电波以及红外线等介质.此外,各个设备之间有时也会通过交换机.网桥.中继器等中转数据. ...
- TCP/IP笔记(四)IP协议
前言 IP相当于OSI参考模型的第3层--网络层:主要作用是"实现终端节点之间的通信"又称"点对点通信". IP作为整个TCP/IP中至关重要的协议,主要负责将 ...
- TCP/IP笔记(五)IP协议相关技术
IP旨在让最终目标主机收到数据包,但是在这一过程中仅仅有IP时无法实现通信的.必须还要又能够解析主机名称和MACdivide功能,以技术包在发送过程中异常情况处理的功能. 这篇主要介绍下DNS.ARP ...
随机推荐
- NSBundle的理解和mainBundle的基本介绍
一.NSBundle NSBundle是cocoa为bundle提供的一个类,bundle是一个目录,其中包含了程序会使用到的资源. 这些资源包含了如图像.声音.编译好的代码.nib文件.(用户也会把 ...
- spring: 使用Aspectj代理EnabelAspectjAutoProxy
使用JavaConfig的话,可以在配置类的类级别上通过使用EnableAspectJ-AutoProxy注解启用自动代理功能. package ch2.test; import org.aspect ...
- 《Advanced Bash-scripting Guide》学习(十三):引用变量的两个例子
本文所选的例子来自于<Advanced Bash-scripting Gudie>一书,译者 杨春敏 黄毅 例1. 使用""可以防止单词分割,将变量看成一个整体,没有& ...
- Linux脚本基础
1.文本编辑 命令模式快捷键命令 命令 作用 dd 删除(剪切)光标所在整行. 5dd 删除(剪切)从光标处开始的5行. yy 复制光标所在整行. 5yy 复制从光标处开始的5行. n 显示搜索命令定 ...
- nyoj 42 一笔画 欧拉通路
http://acm.nyist.net/JudgeOnline/problem.php?pid=42 一笔画问题 时间限制:3000 ms | 内存限制:65535 KB 难度:4 描述 zyc ...
- LeetCode OJ:Maximum Depth of Binary Tree(二叉树最大深度)
Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the long ...
- LeetCode OJ:Binary Tree Preorder Traversal(前序遍历二叉树)
Given a binary tree, return the preorder traversal of its nodes' values. For example:Given binary tr ...
- OSError: [Errno 22] Invalid argument: 'D:\x07ckup\test.txt'
使用with open("D:\backup\test.txt","rt") as f:报上面的错误,将上面的语句改成 with open(r"D:\ ...
- [ Laravel 5.5 文档 ] 数据库操作 —— 在 Laravel 中轻松实现分页功能
 简介 在其他框架中,分页是件非常痛苦的事,Laravel 让这件事变得简单易于上手.Laravel 的分页器与查询构建器和 Eloquent ORM 集成在一起,并开箱提供方便的.易于使用的.基于 ...
- pair对组
一.pair基本概念 对组(pair)将一对值组合成一个值,这一对值可以具有不同的数据类型,两个值可以分别用pair的两个公有函数first和second访问. 类模板:template <cl ...