PING(8,C) AIX TCP/IP User's Guide PING(8,C)
-------------------------------------------------------------------------------
ping
PURPOSE
Sends ICMP ECHO_REQUEST packets to network hosts.
SYNTAX
+--------+ +--------------+ +---------+
ping ---| +----+ |--- host ---| |---| |---|
+-| -d |-+ +- packetsize -+ +- count -+
^| -r ||
|| -v ||
|+----+|
+------+
DESCRIPTION
The DARPA Internet is a large and complex aggregation of network hardware,
connected together by gateways. Tracking a single-point hardware or software
failure can often be difficult. The ping command utilizes the ICMP protocol's
mandatory ECHO_REQUEST datagram to elicit an ICMP ECHO_RESPONSE from a host or
gateway.
ECHO_REQUEST datagrams (pings) have an IP and ICMP header, followed by a struct
timeval, and then an arbitrary number of pad bytes used to fill out the packet.
The default datagram length is 64 bytes, but this may be changed using the
command line option.
When using ping for fault isolation, it should first be run on the local host
to verify that the local network interface is up and running. Then, hosts and
gateways further and further away should be pinged. The ping command sends one
datagram per second and prints one line of output for every ECHO_RESPONSE
returned. By default, ping sends one packet. If an optional count is given,
only that number of requests are sent. Round-trip times and packet loss
statistics are computed. When all responses have been received or the program
times out (with a count specified), or if the program is terminated with a
SIGINT, a brief summary is displayed.
This program is intended for use in network testing, measurement and
management. It should be used primarily for manual fault isolation.
FLAGS
The ping command options are:
Processed October 29, 1990 PING(8,C) 1
PING(8,C) AIX TCP/IP User's Guide PING(8,C)
-d Sets the SO-Debug flag on the socket that ping is using. This enables
console output of debugging messages from the TCP/IP routines in the
kernel. Although this flag has no direct effect on ping's output, it does
affect console output from debugging routines in the kernel.
-r Bypasses the normal routing tables and sends directly to a host on an
attached network. If the host is not on a directly attached network, an
error is returned. This option can be used to ping a local host through
an interface that has no route through it (for example, after the
interface was dropped by routed.)
-v Verbose output. All ICMP packets other than ECHO_RESPONSE that are via
the raw socket are listed (not only those packets related ping).
EXAMPLES
$ /etc/ping host1
PING host1: 56 data bytes
----host1 PING Statistics----
packet transmitted, packet received, 0% packet loss
round-trip (ms) min/avg/max = 26/32/55
$
RELATED INFORMATION
In this book:
"netstat"
"ifconfig"
Processed October 29, 1990 PING(8,C) 2