The Ping command is the primary TCP/IP command used to troubleshoot connectivity, reachability, and name resolution. Its most basic use is to confirm network connectivity between two hosts. You can also use this command to test both the computer name and the IP address of the computer.

  1. To run the command, open the Command prompt on WIndows PC or Terminal on Mac. Read the Knowledge Base article What Is A Command Prompt? for instructions on how to do it.
  2. In the Command prompt/Terminal, type ping hostname where hostname is the name of the destination host or IP address.

    If the ping request fails, there are two common failure messages:

    • The first is destination host unreachable. This message indicates that your local machine attempted to send a request, but it was unable to determine the destination to send it to. Usually, this indicates a configuration problem on your end of the connection. It could also point to a router issue, where the router doesn’t have a route to the destination network. This information allows you to confirm that the local settings are correct because the request couldn’t even be sent.
    • The second response is request timed out. It suggests that the problem is out on the network beyond your local system. Your system sent the request, but a reply was not received back within the ping's wait time. Since your system could send, the misconfiguration is more likely to be at the remote destination's end, or perhaps a network device between the two endpoints.
  3. You can check whether name resolution is functioning by first pinging by hostname, and then pinging by IP address. If the ping by name fails, but the ping by IP address succeeds, you have network connectivity – but the name resolution is not working correctly. If both pings fail, you have a network connectivity problem.
  4. Use the command ping -t hostname where hostname is the name of the destination host to send endless ping requests until interrupted. To interrupt and display statistics, press Ctrl+Enter. To interrupt and quit this command, press Ctrl+C. This command can be used when rebooting remote devices - start the command and restart the device. When it starts responding to the pings again, you know the reboot process is complete.
For more ping parameters you can use with the ping command, read this Microsoft article.

Is this answer helpful?


Haven't found what you're looking for? Search the Support Center!