Information Technology Reference
In-Depth Information
Table 10.3
The ping Command-Line Arguments
Argument
Description
-i interface
Uses the specified interface address
-I interval
Specifies an interval between transmissions (default of 1 second)
-n
Displays addresses instead of hostnames
-r
Bypasses the routing tables (remote host is on local network)
-R
Records route in IP header
-s
Sends ICMP packets until interrupted
-t time
Specifies a time to live (in seconds) for IP packets
-v
Displays detailed information (verbose mode)
At a minimum, a hostname or IP address must be specified. All these com-
mand-line arguments are specified before the hostname or IP address.
When used without any command-line arguments (only a hostname is spec-
ified), a timeout can be specified after the hostname. The default timeout is
20 seconds.
When used with the -s command-line argument, a packet size and a count
can be specified after the hostname. The following listing shows the ping
command sending five packets (each with 60 bytes of data) to the solaris9
host:
$ /usr/sbin/ping -s sparc20 60 5
PING sparc20: 60 data bytes
68 bytes from sparc20 (192.168.99.9): icmp_seq=0. time=1.ms
68 bytes from sparc20 (192.168.99.9): icmp_seq=1. time=0.ms
68 bytes from sparc20 (192.168.99.9): icmp_seq=2. time=0.ms
68 bytes from sparc20 (192.168.99.9): icmp_seq=3. time=0.ms
68 bytes from sparc20 (192.168.99.9): icmp_seq=4. time=0.ms
----sparc20 PING Statistics----
5 packets transmitted, 5 packets received, 0% packet loss
round-trip (ms) min/avg/max = 0/0/1
$
The spray Command
The /usr/sbin/spray command sends a stream of User Datagram Protocol
(UDP) packets to a host using the Remote Procedure Call (RPC) mecha-
nism. On the remote end, the spray daemon, sprayd(1M) , accepts these pack-
ets and acknowledges receiving the packets. The spray command, along with
the sprayd program, are used to verify both the connectivity between two
hosts and the proper operation of the network interfaces and protocol stacks
(of both hosts) up to the application layer.
Search WWH ::




Custom Search