完整的ping命令,用於下面參考
<H3C>ping 1.1.1.1
PING 1.1.1.1: 56 data bytes, press CTRL_C to break
Reply from 1.1.1.1: bytes=56 Sequence=1 ttl=255 time=10 ms
Reply from 1.1.1.1: bytes=56 Sequence=2 ttl=255 time=16 ms
Reply from 1.1.1.1: bytes=56 Sequence=3 ttl=255 time=20 ms
Reply from 1.1.1.1: bytes=56 Sequence=4 ttl=255 time=15 ms
Reply from 1.1.1.1: bytes=56 Sequence=5 ttl=255 time=1 ms
--- 1.1.1.1 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 1/12/20 ms
<H3C>ping ?
-a 指定源地址 例:<H3C>ping -a 2.2.2.2 1.1.1.1
源地址目的地址
-c 指定發送報文的次數 例:<H3C>ping -c 2 1.1.1.1 //ping兩次
-h 指定報文的TTL值,1~255,默認為255
-m 指定發送報文的時間間隔,1~65535,默認200毫秒
-r 記錄路由,默認是不記錄路由的
-s 指定所發送報文的長度,默認為56字節,20~8100
-t 指定超時時間,默認200毫秒,1~65535