8 D% g: g% p! [. X$ \5 ` Options: 8 V9 E# l' C* O% s
9 R N& o1 n2 a -t Ping the specified host until stopped.To see statistics and continue - type Control-Break;To stop - type Control-C. / R; S( R% V5 q8 E! t 4 ?% z$ M$ q9 Y2 ]+ A( U 不停的ping地方主机,直到你按下Control-C。 / Z6 [* z! A8 U
# w& J' [1 _- f: P$ c 此功能没有什么特别的技巧,不过可以配合其他参数使用,将在下面提到。 8 V. X0 _& w% D 4 w: e- ?0 H9 l2 O% q
-a Resolve addresses to hostnames. - M: }. ]2 ~0 b2 k3 l I - G& E* `7 V; S
解析计算机NetBios名。 ! Z6 V: P9 [ R4 _5 C8 h$ _
5 n5 Y4 _0 _+ P8 @; h a 示例:C:\>ping -a 192.168.1.21 : N& J" h7 }: Q1 x ] / X1 }1 Q |- ?4 z
Pinging iceblood.yofor.com [192.168.1.21] with 32 bytes of data: , h5 ?' ?/ @) f; M, r
, m# ^7 t. O8 m K4 l; ? Reply from 192.168.1.21: bytes=32 time<10ms TTL=254 . _ f! n q7 B& Q. y m/ b4 Y
6 K4 H: B J( l; D5 c! P
Reply from 192.168.1.21: bytes=32 time<10ms TTL=254 / n+ K1 b9 h% |( M9 | 7 k3 t! k3 D: {8 T: l) e2 L1 @7 U8 O* J Reply from 192.168.1.21: bytes=32 time<10ms TTL=254 q: d% z! M' L" d- L* V6 }: x( L2 i, h2 x
- W1 x7 j/ I! u/ F; Z Reply from 192.168.1.21: bytes=32 time<10ms TTL=254 & f, G8 |4 m | 7 s% X; G. n; c3 m) K5 P
Ping statistics for 192.168.1.21: $ z8 v$ |7 v# Q1 p. ~( w. G9 U4 ? + k3 x8 O4 r* g
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),Approximate round trip times in milli-seconds: * [5 ?. N$ u% `/ h S; X ' w+ u; C( u( z- ~! u
Minimum = 0ms, Maximum = 0ms, Average = 0ms + R/ k' E% y# q& y4 E* @3 W9 u+ W
% ]: B9 Y2 n6 x* N8 Q+ {
从上面就可以知道IP为192.168.1.21的计算机NetBios名为iceblood.yofor.com。 / M, g* \4 m8 d/ e; Q8 L
8 q1 W1 L" o y$ f -n count Number of echo requests to send. j# m1 H' ^) d; c5 v+ l
1 h* t( V% y8 j) s$ T! M3 g. Y' a C:\>ping -n 50 202.103.96.68 & v; p$ m7 i7 V$ A, P 2 |+ x, u, l9 U4 }. F3 G9 e' I Pinging 202.103.96.68 with 32 bytes of data: % i8 g% K' ~+ j. N: y% f " I+ R! P+ N+ P- v. _( E7 |
Reply from 202.103.96.68: bytes=32 time=50ms TTL=241 8 u4 C' @/ V) T; P
9 H8 ?" e8 o7 h. y
Reply from 202.103.96.68: bytes=32 time=50ms TTL=241 4 @/ ?5 a8 z9 B" s( X( p 2 Q( c( g' |% j+ P b
Reply from 202.103.96.68: bytes=32 time=50ms TTL=241 : S8 P, {( T: f9 C4 w
3 ]) ?/ i3 n1 O# Y0 q5 D Request timed out. : M, {! Y8 B) g& A4 @
& Z/ A: R3 t. r1 R: s( @ ……………… 1 J; B. f8 r4 h+ u3 i5 s
( W$ B( G6 `; Q7 X2 }- S8 b4 h Reply from 202.103.96.68: bytes=32 time=50ms TTL=241 , |2 K0 \% T9 \9 V$ v) T. `+ J/ W
& v8 X0 d( S' e" B9 [7 }! q Reply from 202.103.96.68: bytes=32 time=50ms TTL=241 . n6 |' T# I3 c/ ^+ l8 f8 u E% s
2 g+ z6 j7 n- _3 [' S* n
Ping statistics for 202.103.96.68: + D( N9 b& b! t; r4 \ 4 i9 `& _3 `* G( n9 a4 A& F0 n Packets: Sent = 50, Received = 48, Lost = 2 (4% loss),Approximate round trip times in milli-seconds: 8 K1 o) h5 K8 `) d3 ]1 ~ E
! E' B+ w0 Z4 ?) [ Minimum = 40ms, Maximum = 51ms, Average = 46ms - j7 P% B( ?+ x9 p2 C6 e Y - K5 O. b" e/ h8 _9 Z1 }4 S. K( [4 { 从以上我就可以知道在给202.103.96.68发送50个数据包的过程当中,返回了48个,其中有两个由于未知原因丢失,这48个数据包当中返回速度最快为40ms,最慢为51ms,平均速度为46ms。 2 ~4 T. e; |5 E" l( C+ w ) W( @! M/ ? c2 m# M+ I
-l size Send buffer size. & s2 c6 w+ X, }) _ , l& C4 i% o x# _ 定义echo数据包大小。作者: 冷雨清心 时间: 2008-9-25 15:54