Fping
(十大特色功能)
Ping是最常用的网络测试工具,ping的测试功能其实比较多,xp系统的ping有12个选项。但是,fping测试工具有25个选项,在ping的基础上增加了许多专业的功能,可用于更深层次的网络测试和检测。
Fping是免费软件,可从http://www.kwakkelflap.com下载。
本文翻译和总结了fping的参数,以及使用方法、命令举例,以及总结除了fping的十个特色功能,仅供参考。尤其是抖动测试,是目前网络中能找到的唯一的简单测试时延的网络工具软件。
一、版本
Fast pinger version 3.00
(c) Wouter Dhondt (http://www.kwakkelflap.com)
二、参数Usage:
fping <host(-list)> [-s data_size] [-S size1/size2] [-c] [-t time] [-wtimeout][-n count] [-h TTL] [-v TOS] [-r routes] [-R min/max] [-a] [-f][-b(-)][-i][-l][-o][-j][-T][-D][-dping_data][-ghost1/host2]
[-H filename] [-L filename]
三、十大特色功能
1. (限定间隔)指定数据包间隔大小,从2ms到1000000ms。实际命令是可以从1ms到1000000ms(16分钟)
2. 跳数扫描,通过指定-h选项,可以判断跳数范围。
3. 可以通过 -v选项指定ping数据包的ToS值,相当于可以发出指定ToS的ping数据包。
4. 可以通过 -r选项打印ping数据包经过的路由。
5. (测试抖动)可以通过 -j选项测试网络抖动性能,同时能兼容测试丢包情况。
6. 可以通过 -g选项,一次连续ping多个地址。
7. 可以通过 -i指定数据包所采用的协议为ICMP,而不是IP包。
8. 可以通过 -T 和-D选项打印时间戳和日期戳。
9. 可以通过 -l和-o选项,控制输出信息的复杂程度,可以选择只输出统计信息。
10.可以通过 -L选项将ping信息输出到文件。
四、选项Options:
1. -s:data_sizeinbytesupto65500,指定数据包大小,最大可到65500Byte,
命令举例:C:\>fping 192.0.0.64 -s 65500
Reply[1] from 192.0.0.64: bytes=65500 time=8.9 ms TTL=64
Reply[2] from 192.0.0.64: bytes=65500 time=8.4 ms TTL=64
Reply[3] from 192.0.0.64: bytes=65500 time=8.3 ms TTL=64
Reply[4] from 192.0.0.64: bytes=65500 time=8.2 ms TTL=64
Ping statistics for 192.0.0.64:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss)
Approximate round trip times in milli-seconds:
Minimum = 8.2 ms, Maximum = 8.9 ms, Average = 8.4 ms
2. -t : time between 2 pings in ms up to 1000000,指定ping的数据包时间
间隔大小,时间越小,单位时间内发出去的包越多,最大为16分钟。用1ms(fping 192.0.0.64-t1 -c)的间隔ping数据包可测试业务倒换时间(注意外加-c 选项),例如在测试双路由的情况下,从网管主机 ping对端,可大致测试业务中断时间和恢复时间。
命令举例:C:\>fping 192.0.0.64 -t 1
Pinging 192.0.0.64 with 32 bytes of data every 1 ms:
Reply[1] from 192.0.0.64: bytes=32 time=9.0 ms TTL=64
Reply[2] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
Reply[3] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64
Reply[4] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64
Ping statistics for 192.0.0.64:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss)
Approximate round trip times in milli-seconds:
Minimum = 0.3 ms, Maximum = 9.0 ms, Average = 2.5 ms
3. -w : timeout in ms to wait for each reply
目前的测试,此选项不生效。
4. -c:continuousping(higherprioritythan-n),持续ping包,直到CTRL+C(Control-C)终止。配合-t、-s等选项使用更当。通过Control-Break可暂停ping包,按任意键可继续。
命令举例:C:\>fping 192.0.0.64 -c
5. n : number of pings to send to each host。Ping指定数量的包。n值可无限大。
命令举例:C:\>fping 192.0.0.64 -n 999999999
6. -S : size sweep: ping with size1, size1 + 1, ..., size2 bytes目前的测试,此选项不生效。
7. -R : random length between min and max (disabled when using -S)目前的测试,此选项不生效。
8. -d : ping with specified data。可以通过-d选项,指定数据包内容。中间不能有空格,空格之后的内容会忽略。
命令举例:C:\>fping 192.0.0.64 -d 1234567890
9. -h : number of hops (TTL: 1 to 128) + print hops。可以通过-h指定条数,如果目的地址在 指定范围减1范围之内,可以ping通,否则不同。使用-h从1开始累加,可以实现一个跳数扫描功能,可以检测一个地址在ping发出主机的多少hops 范围之内。例如fping 192.0.0.64 -h 1 ,2,3,4,5,6。直到ping通为止,可以判断出目的主机的hops范围。
10. -v : Type Of Service (0 to 255) (IPv4-only),可以指定ping包的优先级别。
命令举例:C:\>fping 192.0.0.64 -v 4
Pinging 192.0.0.64 with 32 bytes of data every 1000 ms:
Reply[1] from 192.0.0.64: bytes=32 time=0.5 ms TTL=64 TOS=4
Reply[2] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64 TOS=4
Reply[3] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64 TOS=4
Reply[4] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64 TOS=4
Ping statistics for 192.0.0.64:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss)
Approximate round trip times in milli-seconds:
Minimum = 0.4 ms, Maximum = 0.5 ms, Average = 0.4 m
11.-r : record route (1 to 9 routes) (IPv4-only),打印ping数据包经过的路由,数值范围是1-9。
命令举例:C:\>fping 192.0.0.64 -r 1
Pinging 192.0.0.64 with 32 bytes of data every 1000 ms:
Reply[1] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64
Route: 192.0.0.64
Reply[2] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64
Route: 192.0.0.64
Reply[3] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64
Route: 192.0.0.64
Reply[4] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
Route: 192.0.0.64
12.-f : set Don't Fragment flag in packet (IPv4-only),不做帧分割处理。如果与-s 选项配合使用,可检测所在物理环境的mtu大小。
命令举例:C:\>fping 192.0.0.64 -f -s 1473 结果如下:
C:\>fping 192.0.0.64 -f -s 1473
Packet size exceeds MTU and needs to be fragmented but DF set.
Packet size exceeds MTU and needs to be fragmented but DF set.
Packet size exceeds MTU and needs to be fragmented but DF set.
Packet size exceeds MTU and needs to be fragmented but DF set.
命令举例:C:\>fping 192.0.0.64 -f -s 1472 结果如下:
Reply[1] from 192.0.0.64: bytes=1472 time=0.9 ms TTL=64
Reply[2] from 192.0.0.64: bytes=1472 time=1.0 ms TTL=64
Reply[3] from 192.0.0.64: bytes=1472 time=0.9 ms TTL=64
Reply[4] from 192.0.0.64: bytes=1472 time=0.9 ms TTL=64
通过上述测试命令可知,所在网络环境的MTU为1472。
13.-j : print jitter with each reply (only when pinging one host),显示所在网络环境的抖动性能。
命令举例:C:\>fping 192.0.0.64 -t 1 -j 结果如下:
Reply[1] from 192.0.0.64: bytes=32 time=0.5 ms TTL=64 jitter=0.00 ms
Reply[2] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64 jitter=0.01 ms
Reply[3] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64 jitter=0.01 ms
Reply[4] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64 jitter=0.01 ms
14.-g : ping IP range from host1 to host2 (IPv4-only)
命令举例:fping 192.0.0.63 192.0.0.64 -g 结果如下:
Pinging multiple hosts with 32 bytes of data every 1000 ms:
Reply[1] from 192.0.0.63: bytes=32 time=0.2 ms TTL=64
Reply[2] from 192.0.0.64: bytes=32 time=10.1 ms TTL=64
Ping statistics for multiple hosts:
Approximate round trip times in milli-seconds:
Minimum = 0.2 ms, Maximum = 10.1 ms, Average = 5.1 ms
15.-H:get hostsfromfilename (commadelimited,filename withfullpath),从一个文本文件中获取主机地址,文本文件中只需要包含主机地址。
命令举例:fping 192.0.0.64 -H 1.txt -n 5 结果如下:
Reply[1] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
Reply[2] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64
Reply[3] from 192.0.0.63: bytes=32 time=0.1 ms TTL=64
Reply[4] from 192.168.0.234: bytes=32 time=14.6 ms TTL=64
Reply[5] from 192.168.0.233: bytes=32 time=0.1 ms TTL=64
16.-a : resolve addresses to hostnames,将一个IP地址解析为主机名称,并进行ping测试。
命令举例:fping 192.0.0.63 -a 本机地址为192.0.0.63,本机计算机名 称为:20120302-1704,结果如下:
Pinging 20120302-1704 [192.0.0.63] with 32 bytes of data every 1000 ms:
Reply[1] from 192.0.0.63: bytes=32 time=0.2 ms TTL=64
Reply[2] from 192.0.0.63: bytes=32 time=0.1 ms TTL=64
Reply[3] from 192.0.0.63: bytes=32 time=0.2 ms TTL=64
Reply[4] from 192.0.0.63: bytes=32 time=0.2 ms TTL=64
17.-A : print addresses with each reply
18.-p : use a thread pool to ping multiple hosts (enables ICMP dll),在一个线程中ping多个主机。-p5,每一个核心5个线程。
命令举例:fping 192.0.0.64 -p -t 10 -n 20 结果如下:
Reply[1] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
Reply[2] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64
Reply[3] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64
Reply[4] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
19.-i : use ICMP dll instead of raw socket (disables -r),使用ICMP协议发出数据包,不使用IP包方式,可通过扫描软件发现数据包协议为ICMP。
命令举例:fping 192.0.0.64 -i
20.-b : beep on every successful reply (-b- to beep on timeout),每成功一次蜂鸣一声。
命令举例:fping 192.0.0.64 -b
21.-T : print timestamp with each reply,每次ping完成后打印时间戳。
命令举例:fping 192.0.0.64 -T -t 10 -n 100
14:42:14.796 : Reply[1] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
14:42:14.812 : Reply[2] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
14:42:14.828 : Reply[3] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
14:42:14.828 : Reply[4] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
14:42:14.843 : Reply[5] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
22.-D : print datestamp with each reply,每次ping完成后打印日期。
命令举例:fping 192.0.0.64 -D -t 10 -n 100
2012/12/10 : Reply[1] from 192.0.0.64: bytes=32 time=0.5 ms TTL=64
2012/12/10 : Reply[2] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
2012/12/10 : Reply[3] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
23.-l : limit the output to ping results and errors,限制输出信息。相当于输出最简单的,最精简的信息。
命令举例:fping 192.0.0.64 -l -t 10 -n 40 结果如下:
Reply[1] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
Reply[2] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
Reply[3] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
Reply[4] from 192.0.0.64: bytes=32 time=0.4 ms TTL=64
Reply[5] from 192.0.0.64: bytes=32 time=0.3 ms TTL=64
24.-o : limit the output to ping statistics,只输出统计信息。
命令举例:fping 192.0.0.64 -o 结果如下:
Pinging 192.0.0.64 with 32 bytes of data every 1000 ms:
Ping statistics for 192.0.0.64:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss)
Approximate round trip times in milli-seconds:
Minimum = 0.4 ms, Maximum = 4.2 ms, Average = 1.4 ms
25.-L : logging to a text file,将ping的测试信息输出到一个文件。
命令举例:fping 192.0.0.64 -o -L ddd.txt 结果如下:
Pinging 192.0.0.64 with 32 bytes of data every 1000 ms:
Ping statistics for 192.0.0.64:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss)
Approximate round trip times in milli-seconds:
Minimum = 0.4 ms, Maximum = 0.5 ms, Average = 0.5 ms
Fping的更多相关文章
- ★Kali信息收集~★7.FPing :ip段扫描
参数: 使用方法: fping [选项] [目标...] -a显示是活着的目标 -A 显示目标地址 -b n 大量 ping 数据要发送,以字节为单位 (默认 56) -B f 将指数退避算法因子设置 ...
- fping tcping hping nmap nc
[root@test ~]# fping -a -g 192.168.40.1 192.168.40.240 |nl #-a 扫描alive主机,-g扫描一个段的ip地址 [root@test ...
- Linux 网络工具之fping
系统中有个最最常用命令工具--ping,而fping 是ping 工具的加强版本.安装过程很简单: [root@mail /]# wget --limit-rate 500k http://www.f ...
- 小白日记8:kali渗透测试之主动信息收集(二)三层发现:ping、traceroute、scapy、nmap、fping、Hping
三层发现 三层协议有:IP以及ICMP协议(internet管理协议).icmp的作用是用来实现intenet管理的,进行路径的发现,网路通信情况,或者目标主机的状态:在三层发现中主要使用icmp协议 ...
- centos7之zabbix3.2的fping监控
zabbix通过fping检测主机网络状态 fping的官方网站:http://www.fping.org/ 官网指定的github的地址:https://github.com/schweikert/ ...
- zabbix3.2使用fping批量监控ip的连通性
.在zabbix-agent端安装fping wget http://www.fping.org/dist/fping-3.16.tar.gz tar zxvf fping-3.16.tar.gz c ...
- linux下的ping工具--fping
前言: 如果想ping 大量的不连续的地址,有想知道放回结果,在linux系统下有一个非常合适的工具--fping. Fping 官网:http://www.fping.org/ Fpin ...
- fping常用参数介绍
fping的主要参数有以下两个: -a:只显示存活主机: -u:只显示不存活主机: -l:循环ping目标IP地址的输入方式: fping IP1 IP2 IP3 ...: fping -f file ...
- centos7.4之zabbix4.0的fping监控
参考博文: https://www.cnblogs.com/lei0213/p/8859326.html 注释:他是额外安装fping的:因为我yum安装的zabbix,fping就已经自带了:安装步 ...
随机推荐
- 用CSS定义每段首行缩进2个字符 转
应该遵循w3c所制定的html/xhtml标准来使用tag和编写网页.如果你对此不太了解,可以到w3c的网站www.w3.org去找相关资料,或者买一本xhtml的书(注意不要买过时的html的书,尽 ...
- 数据结构《16》----自动补齐实现《一》----Trie 树
1. 简述 Trie 树是一种高效的字符串查找的数据结构.可用于搜索引擎中词频统计,自动补齐等. 在一个Trie 树中插入.查找某个单词的时间复杂度是 O(len), len是单词的长度. 如果采用平 ...
- SVN小贴士
我辛辛苦苦写的到哪里了? SVN小贴士SVN服务器上的代码项目组公用,你的每一个提交都会体现给项目组每个人,所以提交要慎重,要注意避免代码冲突,使用SVN小贴士: 1.提前宣布开发计划,保持项目组成员 ...
- ssd硬盘u盘装win7扩展文件时0x80070570错误
搞了个minisata ssd 硬盘,80G正好,只用来装操作系统. 这个u盘装了很多系统了,没感觉会有什么问题,但在安装过程中出现0x80070570错误.见图 网上有很多方法. 最后的解决方法是: ...
- Turing Tree_线段树&树状数组
Problem Description After inventing Turing Tree, 3xian always felt boring when solving problems abou ...
- 第三个Sprint冲刺第七天
讨论地点:宿舍 讨论成员:邵家文.李新.朱浩龙.陈俊金 讨论问题:做最后的工作
- python-内置函数、装饰器
本节内容:一之前课程回顾: 在书写代码的时候,先写简单的逻辑在写复杂的逻辑.概念梳理:1.函数在传递实参的时候是传递的是引用而不是从内存中重新赋相同值给形参.比如: def test(x): x.ap ...
- 使用notepad++进行格式转换
由于历史原因,导致Windows.Unix/Linux.Mac三者之间,对于文本中所用回车换行符,表示的方法,都不一样.这就导致了很多人都会遇到回车换行符的困惑,同时需要在不同格式间进行转换. 1)查 ...
- iOS的URL处理
前两天处理iOSapp过程中(我是用swift语言写的,资料较少),被一个“字符串”搞了一晚上的时间到第二天才处理好,在此记下,望见过此文的学生有一天遇到该情况能三分钟搞定不浪费时间: 先看如下代码 ...
- 《C与指针》第一章练习
本章例程 程序1.1 重排字符 #include <stdio.h> #include <stdlib.h> #include <string.h> #define ...