Ping - Explained

If you have been just getting into routers, networking and upgrades, you probably have seen a lot of folks talk about pinging.

This should help you understand this utility.

PING is short for Packet InterNet Groper, ping is a utility used to verify if a network data packet is capable of being distributed to an address without errors. The ping utility is commonly used to check for network errors.

The image to the right is an example of what happens when a ping is sent. As can be seen the user would first start by using the ping command to ping the IP address 204.228.150.3. Next, the request is sent over the network hub and router in this basic example to the other computer with this IP address. Once successfully received, the computer replies to the ping with a pong response and once received, the time between when sent and when received is calculated to generate a average response or latency time.

If the ping does not reach its destination either because of a network configuration error or because it is being blocked, the sending computer encounters a request timed out error.

So basically, when you Ping a device, say your router or even a web address - a reply back means that your machine can "see" the other device. This is why it's so handy. If you are troubleshooting your router , for example, if you computer cannot "see" your router, you will never be able to get anything else working.

The way you run and use Ping is by opening up a DOS type window in Windows XP. You do this by clicking on Start > Run and typing in CMD. This opens up a small window that you can run commands in.

If you just type the word Ping you will get a small help screen with all the options that Ping has, here are the options explained.

ping [-t] [-a] [-n count] [-l size] [-f] [-i TTL] [-v TOS]
  [-r count] [-s count] [[-j host-list] | [-k host-list]]
  [-w timeout] destination-list
Options:  
-t Pings the specified host until stopped.
To see statistics and continue - type Control-Break;
To stop - type Control-C.
-a Resolve addresses to hostnames.
-n count Number of echo requests to send.
-l size Send buffer size.
-f Set Don't Fragment flag in packet.
-i TTL Time To Live.
-v TOS Type Of Service.
-r count Record route for count hops.
-s count Timestamp for count hops.
-j host-list Loose source route along host-list.
-k host-list Strict source route along host-list.
-w timeout Timeout in milliseconds to wait for each reply.

 

So for example.

ping localhost

Pings the local host, this will allow you to see if the computer is able to send information out and receive the information back. Note that this does not send information over a network but may allow you to see if the card is being seen.

ping xxx.xxx.xxx.xxx

Allows you to ping another computer where the x's are located are where you would place the IP address of the computer you are attempting to ping. If this is not able to complete this should relay back an unsuccessful message which could be an indication of cable issues, network card issues, hub issue, etc.

So, in a nutshell, if your router is using 192.168.1.1 as it's address and you typed "Ping 192.168.1.1" in your CMD window, you would see a reply back if you were connected. It would Ping your router 3 times and give you the reply. If you use the "-t" option it would ping your router forever, until you typed Control-C.

Here are some other useful examples:

  1. ping 127.0.0.1 (This is a "loopback ping" — your computer trying to talk to itself. This tests whether your computer is able to handle Ethernet traffic. If this has a negative result, the computer has an operating system problem.)
  2. ping 192.168.1.1 (If the result is "Request timed out", type ping 192.168.0.1. If that also times out, then the computer is not making a connection to your router.)
  3. ping www.netgear.com. (Tests whether your computer can contact Internet computers.)

Now that you have a good grasp on how to ping a device and start using it, you will soon find out just how usefull this little tool is.