Ping [-t] [-a] [-n count] [-l length] [-f] [-i TTL] [-V TOS] [-r count] [-s count] {-j computer-list] | [-k computer-list} [-w Timeout] destination-list options: -t ping the specified host uncle stopped.to see statistics and continuous - type control-break; to stop - type control-c. non-stop ping Local host until you press Control-C. This feature does not have special skills, but it can be used with other parameters will be mentioned below.
-A resolve address to hostnames. Resolve the computer NetBIOS name. Example: c: \> ping -a 192.168.1.21 pinging iceblood.yofor.com [192.168.1.21] with 32 bytes of data: reply from 192.168.1.21: bytes = 32 TIME <10ms TTL = 254 reply from 192.168.1.21: Bytes = 32 TIME <10ms TTL = 254 reply from 192.168.1.21: bytes = 32 TIME <10ms TTL = 254 reply from 192.168.1.21: bytes = 32 TIME <10ms TTL = 254 ping statistics for 192.168.1.21: Packets: SENT = 4, Received = 4, Lost = 0 (0% Loss), Approximate Round Trip Times in Milli-Seconds: minimum = 0ms, Maximum = 0ms, Average = 0ms From above, IP is 192.168.1.21 Computer NetBIOS name Iceblood.yofor.com.
-n count number of echo requests to send. Send count specified by the ECHO packet. By default, only four packets are usually sent. You can define the number of sent by this command. It is very helpful to measure the network speed. For example, I want to test the average time of the return of 50 packets, how much time is How much is the fastest time, the slowest time can be learned by: C: \> ping -n 50 202.103.96.68 pinging 202.103.96.68 With 32 bytes of data: reply from 202.103.96.68: BYtes = 32 TIME = 50ms TTL = 241 Reply from 202.103.96.68: bytes = 32 time = 50ms TTL = 241 Reply from 202.103.96.68: bytes = 32 time = 50ms TTL = 241 Request timed out .................. Reply from 202.103.96.68:. bytes = 32 TIME = 50ms TTL = 241 reply from 202.103.96.68: BYtes = 32 Time = 50ms TTL = 241 ping statistics for 202.103.96.68: Packets: SENT = 50, Received = 48, LOST = 2 (4% loss), Approximate Round Trip Times In Milli-Seconds: Minimum = 40ms, Maximum = 51ms, Average = 46ms From the above I can know that in the process of sending 50 packets to 202.103.96.68, returning 48, two of which are unknown The reason is lost, and the return speed is the fastest speed is 40ms in the 48 packets, the at least 51ms, the average speed is 46ms.
-l size send buffer size. Define the Echo packet size. In the default case, the packet size sent by Windows is 32byt, and we can also define its size, but there is a size limit, that is, the maximum can only send 65500byt, maybe someone will ask why it is 65500Byt, because The Windows Series systems have a security vulnerability (perhaps other systems) is that when the data packet sent by the other party is greater than or equal to 65532, the other party is very likely to block, so Microsoft has restricted this security vulnerability. Ping's packet size. Although Microsoft has made this limit, this parameter is still very powerful after this parameter is still very powerful. For example, we can implement an aggressive command by mating -t parameters: (The following introduction is dangerous, only In the test, please do not easily apply to the other machines, otherwise the consequences are at your own risk) C: \> ping -l 65500 -t 192.168.1.21 pinging 192.168.1.21 with 65500 BYtes of data: reply from 192.168.1.21: bytes = 65500 time < 10ms TTL = 254 reply from 192.168.1.21: bytes = 65500 Time <10ms TTL = 254 ................ This will send a size of 65500BYT to 192.168.1.21 computers, if you only have one There may be no effect on the computer, but if there are many computers, you can make the other party completely paralyzed, I have done such a test, when I use more than 10 computer PING PING, less than 5 minutes, less than 5 minutes The network has been completely paralyzed, the network is severely blocked, and the HTTP and FTP services are completely stopped, and the power is not as small. -f set don't fragment flag in packet. Send "Do not segment" in the packet. In the general packet you send, you will be sent to the other party via routing segmentation, plus the route will not reside again.
-i TTL TIME TO LIVE. Specifies the time for TTL values to stay in the other party. This parameter also helps you check the network operation.
-V TOS TYPE OF Service. Set the Service Type field to the value specified by TOS.
-r Count Record Route for Count HOPS. Record the route from the "Record Routing" field. In general, the packet you sent is to the other party through a route, but what is the route? Through this parameter, you can set the number of routes you want to detect, but the limit is 9, that is, you can only track 9 routes. If you want to detect more, you can implement it through other commands, I will Explain to everyone in future articles. The following is an example: C: \> ping -n 1 -r 9 202.96.105.101 (send a packet, record up to 9 routes)
Pinging 202.96.105.101 with 32 bytes of data:
Reply from 202.96.105.101: bytes = 32 time = 10ms TTL = 249 Route: 202.107.208.187 -> 202.107.210.214 -> 61.153.112.70 -> 61.153.112.89 -> 202.96.105.149 -> 202.96.105.97 -> 202.96.105.101 -> 202.96.105.150 -> 61.153.112.90Ping statistics for 202.96.105.101: Packets: Sent = 1, Received = 1, Lost = 0 (0% loss), Approximate round trip times in milli-seconds: Minimum = 10ms, Maximum = 10ms, Average = 10ms I can know from my computer to 202.96.105.107.210.214, 61.53.112.70, 61.53.112.89, 202.96.105.149, 202.96.105.96. .
-s count timestamp for count hops. Specify the timestamp of the number of hops specified by Count. This parameter and -R are similar, but this parameter does not record the route passed by the packet, and only 4 is recorded.
-j host-list loose source route along host-list. Routing packets using Computer-List specified by computer-list. A continuous computer can be separated by the intermediate gateway (routing sparse source) IP allowed to be 9.
-k host-list strict source route along host-list. The computer list specified using computer-list routing packets. Continuous computers cannot be separated by intermediate gateway (routing strict source) IP allowed to 9.
-w Timeout Timeout In MilliseConds to Wait for Each Reply. Specify time separation, units in milliseconds. This parameter has no other techniques.
Other Tips for ping commands: In general, you can also return the other party to your TTL value size, the system type of the rough judgment target host is a Windows Series or a UNIX / Linux series, in general, the Windows series system returns The TTL value is between 100-130, and the TTL value returned by the UNIX / Linux series is between 240-255, and of course the value of TTL is modified in the other's host, and the system of Windows series can be registered Table: [HKEY_LOCAL_MACHINE \System \currentcontrolset\service \currentcontrolset\service \tcpip \parameters] "defaultttl" = dword: 000000FF