Whenever other engineers see network engineers during troubleshooting, they think that, network engineers only ping from one node to another. But as you know a network engineer is more than a pingman :) This command is a basic but very useful tool for network engineers to control the reachability of peer node.
Ping command maybe is the most useful command for a network engineer. Basically, with this command, you send an ICMP(Internet Control Management Protocol) request to the destination, and wait for the response. According to the number of response and its returning time, you can decide what to do for troubleshooting.
In this article we will discuss ping command for windows, unix systems and cisco routers.
If the destination is not reachable for IP layer, you will receive the “Request timed out” message.
By the way, if you has just connect a device to a network, first ping packet to this network seen lost, because the device is not known in the network and its MAC address is not in the ARP Table of your device. The rest of the ping packets will be successfull if there is not any other problem in the connection.
Ping is mostly used on Windows to check network reachability. There are various of Ping Command for Windows. Below, you can find these important Ping Commands for Windows.
-t : Continuous ping. -> ping 172.22.82.1 –t
-n: Number of ping packet. -> ping 172.22.82.1 –n 2 (2 ping packet)
-l : Size of the ping packet. -> ping 172.22.82.1 –l 200 (200 bytes,from 32 to 65,527)
-i : The value of TTL. -> ping 172.22.82.1 –i 200 (TTL=200, max 255)
-s : To report the time, in Internet Timestamp format, that each echo request is received and echo reply is sent. The maximum value for count is 4 meaning that only the first four hops can be time stamped.
-w: To adjust the time-out value. Default is 1000ms=1s -> ping 172.22.82.1 –w 2000
-f : Sets the Do Not Fragment bit on the ping packet. -> ping 172.22.82.1 –f
-a: To resolve, the hostname of an IP address target. -> ping 172.22.82.1 -a
-4 : Force to use IPv4
-6 : Force to use Ipv6
-R : To trace the round trip path (for Ipv6 only)
-S : To specify the source address (for Ipv6 only)
You can use “/?” command for help of ping command like other commands.
Do not forget that, this parameters are used in different meaning in different systems. For example, “-l” value is used for packet size in windows systems, but you can do this with “-s” in unix systems.
Now, Let’s check the Unix versions of these commands.
Unix systems and windows systems has different commands and parameters for the Ping Command. Here, the command is the same but Ping Commands For Unix has different parameters and these parameters have generally different meanings. These Unix commands are also used on Linux systems as Ping Command for Linux. Let’s check these Ping Commands For Unix and Ping Command in Linux one by one.
-i = To determine the interval for two ping packet. -> ping 172.22.82.1 –i 5 (seconds)
-c = To set the number of ping packets. -> ping 172.22.82.1 –c 3
-s = To set the packet size. -> ping 172.22.82.1 –s 200 (bytes)
-w = To set the deadline to terminate the ping output. -> ping 172.22.82.1 –w 3(seconds)
-f = Super users can send hundred or more packets per second using -f option. It prints a ‘.’ when a packet is sent, and a backspace is printed when a packet is received.
-R = To print the network route through which the packet is sent and received.
In the following articles, we will talk about other useful commands for network engineers…Keep on, ipcisco.com ;)