Ping is the network testing command used to see if another computer is still connected to the network. The ping helps us in figuring out network disconnections and all such related problems. The ping was invented for this purpose. The way the ping works is by sending out a specific format of message to the destination and it expects a reply from the destination. There are also other uses for ping in the network related operations. The ping is now integral part of very many application that depend on network connections.
Usage:
Ping is found in every computer system and over every platform and OS. The usual usage is
$ping 192.168.1.1 (or any other ip address)
This should give out results including the statistical analysis of the communication that is being established with the destination. It recurrently sends the signal to the destination. Some of the operating systems include further options for the ping command including the time for which it should wait to get reply, number of times it has to try and frequency at which it has to signal for reply.
The statistics:
Ping usually gives the time that is taken to get a message across to the destination and number of hops that the message have to make through the various routers in the network. It shows the number of bytes transmitted and the TimeToLive parameter set to the packets too.
Message transfer:
The Ping command transfers what is called the ICMP (Internet Control Message Protocol). This protocol has the header which will have the TTL, Source and destination addresses. The ping is then replied back with the reply which identifies the exact number of the message for which it is meant for.
Reasons for Failure:
Ping may fail and this can indicate any of the following problems in network:
ñ Network cables that could be unplugged meaning a loss of network access to the source or destination computer.
ñ A busy operating system that makes it difficult to transfer data to that specific system.
ñ The destination can be very late to reach from the system – in which case you can identify the malfunctions of the network based applications.
ñ Ping can also fail if the existing system is not able to initiate the network interface properly – this can be identified by the failure to initialize the ping.
ñ There can also be host resolving or route problems of network in which case the destination is unreachable.
The ping utility finds it usage in many network based applications. There is always a need to keep a connection alive in such applications. There are routers that can cancel a NAT map in case of inactivity. This can be avoided by using a ping request that is sent at a certain frequency. The multi-player games also make use of the ping to keep the network users active in game. Many of the network tools and simulators also use the ping to transfer messages at different levels and aspects.