From the Trenches, part one: Network troubleshooting with ping

In part one of this three-part article, network administrator and IT consultant Tim Fenner will walk you through the basic uses of basic TCP/IP connection testing utilities -- and point out ways to use them more extensively.

Most Windows administrators and PC users are familiar with basic TCP/IP connection testing utilities, but they don't often get to stretch the limits of those utilities' capabilities. That's too bad, because tools like ping, tracert and pathping are limber enough to stretch your system's muscles.

In this three-part article, I'll walk you through the basic uses of these tools and point out ways to use them more extensively. In this story, we'll check out the ping utility. Parts two and three cover tracert and pathping.

The ping command verifies connections to a remote computer or computers by sending out Internet Control Message Protocol (ICMP) echo packets.

So you say: "All right. Nice definition, but what does that mean to me?" What it says is this: using the ping command is like picking up the phone and dialing a number to see whether it rings on the other side. But ping does a little more. It determines whether the phone on the other side rings, whether it speaks the right language (TCP/IP, in this case) and how long it takes.

At a command prompt, type:

ping [destination computer or IP address]

Here are some examples:

  • ping www.yahoo.com
  • ping 172.16.12.2
  • ping 127.0.0.1
The third example in the above list shows how to check whether TCP/IP is installed and active and whether your NIC is responding to your commands. That address -- 127.0.0.1-- is called the loopback address of your NIC.

Sample output below:


C:WINNTSYSTEM32>ping 127.0.0.1

Pinging 127.0.0.1 with 32 bytes of data:

Reply from 127.0.0.1: bytes=32 time<10ms TTL=128
Reply from 127.0.0.1: bytes=32 time<10ms TTL=128
Reply from 127.0.0.1: bytes=32 time<10ms TTL=128
Reply from 127.0.0.1: bytes=32 time<10ms TTL=128

Ping statistics for 127.0.0.1:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms


Notice the four replies. This shows that you have a valid IP connection to the destination computer. Since I was pinging the loopback, it shows my NIC is responding to IP traffic.

To use ping to test your TCP/IP configuration, Windows Help offers these steps:

  • To quickly obtain the TCP/IP configuration of a computer, open [a]command prompt, and then type ipconfig.
  • At the command prompt, ping the loopback address by typing ping 127.0.0.1. If the ping command fails, verify that the computer was restarted after TCP/IP was installed and configured.
  • Ping the IP address of the computer [from which you are working on]. If the ping command fails, verify that the computer was restarted after TCP/IP was installed and configured.
  • Ping the IP address of the default gateway. If the ping command fails, verify that the default gateway IP address is correct and that the gateway (router) is operational.
  • Ping the IP address of a remote host (a host that is on a different subnet). If the ping command fails, verify that the remote host IP address is correct, that the remote host is operational, and that all the gateways (routers) between this computer and the remote host are operational.
  • Ping the IP address of the DNS server. If the ping command fails, verify that the DNS server IP address is correct, that the DNS server is operational, and that all the gateways (routers) between this computer and the DNS server are operational.
With this utility, there are many different options, which can be found by typing:
  • ping | more
In the above example, note that the | between "ping" and "more" is not a lower case L or a number 1. On most systems, you can produce this symbol by pressing the shift key and the backslash key at the same time.

From there, you can find many ways to milk ping for all its worth. And it's worth a lot!

About the author: Tim Fenner is a network and systems administrator for a national industry association and an IT consultant for small businesses.

FOR MORE INFORMATION: Check out this network troubleshooting flowchart.
Continue on to part two

Reference works for this article include

Dig deeper on Windows Operating System Management

Pro+

Features

Enjoy the benefits of Pro+ membership, learn more and join.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchServerVirtualization

SearchCloudComputing

SearchExchange

SearchSQLServer

SearchWinIT

SearchEnterpriseDesktop

SearchVirtualDesktop

Close