In Unix, how can I check whether a networked computer has crashed?
To see whether a networked computer has crashed or otherwise become
unavailable, try using the Unix ping command,
which reports whether a computer at a particular address or IP
number is responding. The syntax for ping is:
Replace address with the name of the computer you want to
check. Because ping may be stored in a directory that is
not included in your path, you may have to include the full path name
for the program in order to use it. Often, ping is
located in the /etc, /sbin, or
/usr/sbin directory, so you may need to enter one of the
following:
Replace address with the hostname of the computer in
question. For example, to check whether the host
mail-relay.iu.edu is up, you would enter:
On some systems, ping will simply respond with a message
indicating whether the system is up or down, though typically this
behavior can be modified. On other systems, ping sends
packets to the remote host and returns information in one second
intervals (by default) about how the host responds. If the version of
ping on your system does not do this, but simply reports
if a host is alive or not, you may be able to change this by including
-s in the command, for example:
Press Ctrl-c to stop ping from sending out
any more packets; ping then will produce a summary of the
remote host's responses. The summary will include the number of
packets transmitted, the number received, the percentage of packets
lost, and how long it took for each packet to be received and
returned. Ideally, the number of packets received should be equal to
the number transmitted. If the remote host has a problem, packet loss
may occur (i.e., the number of packets received will be fewer than the
number transmitted).
Note: In some situations, a remote computer may
respond to ping, but not be reachable by other network
tools such as SFTP or rlogin.
For more information about the ping command, at the Unix
prompt, enter man ping .
At Indiana University, to get support for personal or departmental Linux or Unix systems, see At IU, how do I get support for Linux or Unix?
Also see:
- In Unix, what is my path, and how do I set or modify it?
- In Windows, what are some networking commands I can use from the command prompt?
- In Unix, what is the man command, and how do I use it to read manual pages?
- Introduction to Unix commands
- In Windows, how can I ping an IU computer from outside the IU network?
- What is ping?
Last modified on August 22, 2008.






