Testing the path between the switch and another device on an IP network
The ping test uses ICMP echo requests and ICMP echo replies to determine if another device is alive. It also measures the amount of time it takes to receive a reply from the specified destination. The
ping
command has several extended commands that allow advanced checking of destination availability.
Syntax:
ping {<ip-address | hostname>} [repetitions <1-10000>] [timeout <1-60>] [source < {ip-address | <vlan-id> | loopback <0-7>>}] [data-size <0-65471>] [data-fill <0-1024>] [ip-option {<record-route | loose-source-route | strict-source-route | include-timestamp | include-timestamp-and-address | include timestamp-from} >] [tos <0-255>]
ping6 {<ipv6-address | hostname>} [repetitions <1-10000>] [timeout <1-60>] [source < {ip-address | vlan-id | loopback <0-7>>}] [data-size <0-65471>] [data-fill <0-1024>]
Sends ICMP echo requests to determine if another device is alive.
|
Target IP address or hostname of the destination node being pinged |
|
Number of ping packets sent to the destination address. Default: 1 |
|
Timeout interval in seconds; the ECHO REPLY must be received before this time interval expires for the ping to be successful. Default: 5 |
|
Source IP address, VLAN ID, or loopback address used for the ping. The source IP address must be owned by the router.If a VLAN is specified, the IP address associated with the specified VLAN is used. |
|
Size of packet sent. Default: 0 (zero) |
|
The data pattern in the packet. Default: Zero length string |
|
Specify an IP option, such as loose or strict source routing, or an include-timestamp option: Default: 9 Default: 4 When specified without loose or strict recording, the source route is not recorded. The source route is automatically recorded when loose or strict source routing is enabled. Default: 9 |
|
Specifies the type of service to be entered in the header packet. Default: 0 (zero) |
Ping tests
switch# ping 10.10.10.10 10.10.10.10 is alive, time = 15 ms switch# ping 10.10.10.10 repetitions 3 10.10.10.10 is alive, iteration 1, time = 15 ms 10.10.10.10 is alive, iteration 1, time = 15 ms 10.10.10.10 is alive, iteration 1, time = 15 ms switch# ping 10.10.10.10 timeout 2 10.10.10.10 is alive, time = 10 ms switch# ping 10.11.12.13 The destination address is unreachable.