System maintenance and debugging
You can use the ping command and the tracert command to verify the current network connectivity, and
use the debug command to enable debugging and to diagnose system faults based on the debugging
information.
Ping
Introduction
The ping command allows you to verify whether a device with a specified address is reachable, and to
examine network connectivity.
The ping function is implemented through the Internet Control Message Protocol (ICMP) using the
following workflow:
1. The source device sends an ICMP echo request to the destination device.
2. The source device determines whether the destination is reachable based on whether it receives an
ICMP echo reply. If the destination is reachable, the source device determines the following:
• The link quality, based on the numbers of ICMP echo requests sent and replies received.
• The distance between the source and destination based on the round trip time of ping packets.
Configuring ping
There are two version of the ping command, one for IPv4 networks (ping) and the other for IPv6 networks
(ping ipv6).
Follow the step below to configure the ping function:
To do… Use the command… Remarks
IPv4 network:
ping [ ip ] [ -a source-ip | -c count | -f | -h
ttl | -i interface-type interface-number | -m
interval | -n | -p pad | -q | -r | -s
packet-size | -t timeout | -tos tos | -v ] *
host
Check whether a specified
address in an IP network is
reachable
IPv6 network:
ping ipv6 [ -a source-ipv6 | -c count | -m
interval | -s packet-size | -t timeout ] * host
[ -i interface-type interface-number ]
Required
Use either approach
Available in any view
NOTE:
For a low-speed network, set a larger value for the timeout timer (indicated by the -t parameter in the
command) when using the ping command.
1