Your Internet Consultant - The FAQs of Life Online

3.13. How can I tell whether a computer on the Internet is up and running?

If you're trying to connect to another computer on the Internet, but you aren't sure whether it's even running, you can ping that computer to find out. The ping command, available on many systems, sends out an "Are you there?" message (called a ping packet) to the computer in which you're interested. If the computer is awake, it admits it is there (by sending back what is called, in sillier circles, a pong packet) and you'll be told that everything is right with the world. If the remote computer isn't up, you'll know why you haven't been able to Telnet or FTP there, or why e-mail to that site isn't getting through.

The ping command can take many forms. On some systems, its output looks like this:

$ ping is alive.
On some systems, the ping by default offers quite a bit of useful information. Your host may or may not have an extra-useful ping command. If your system doesn't, don't blame me. It's default of de computer. (I stole that joke from the book Inside Atari Basic, written by Bill Carris in 1983. It was stupid then and it's still stupid.)

On my system, when I type ping -s, it sends ping packets over and over again until I hit Ctrl-C; then it shows me a status report. In this case, the connection between California and Massachusetts is nice and stable, and it takes about 114 milliseconds for my ping packets to get there and back. This means that my query crossed the United States, was received, acted on, and replied to. That response makes it back to me faster than you can read a single word in this sentence. That's fast!.

$ ping -s
PING 56 data bytes
64 bytes from ( icmp_seq=0. time=116. ms
64 bytes from ( icmp_seq=1. time=112. ms
64 bytes from ( icmp_seq=2. time=116. ms
64 bytes from ( icmp_seq=3. time=117. ms
64 bytes from ( icmp_seq=3. time=115. ms
64 bytes from ( icmp_seq=5. time=114. ms
64 bytes from ( icmp_seq=6. time=111. ms
^C PING Statistics----
7 packets transmitted, 7 packets received, 0% packet loss
round-trip (ms)  min/avg/max = 111/114/117
Note: Ping lives in the here-and-now. If the computer in question isn't "alive," you know only that it isn't available on the Internet right now. There's no telling whether it's gone forever, or it crashed, or it's down for system maintenance, or the network link between your host and it has temporarily died.

Table of Contents | Previous Section | Next Section