< Home

ping ipv6

Function

The ping ipv6 command checks whether a specified IPv6 address is reachable and exports corresponding statistics.

Format

ping ipv6 [ -a source-ipv6-address | -c count | -h ttl-value | -m time | -name | -s packetsize | -t timeout | -tc traffic-class-value | vpn-instance vpn-instance-name ] * host [ -i interface-type interface-number ]

Parameters

Parameter Description Value
-a source-ipv6-address

Specifies a source IPv6 address for sending ICMPv6 Echo Request messages.

If no source IPv6 address is specified, the IPv6 address of the outbound interface is used as the source address for sending ICMPv6 Echo Request messages.

The value is a 32-digit hexadecimal number, in the format of X:X:X:X:X:X:X:X.
-c count

Specifies the number of times for sending ICMPv6 Echo Request messages.

You can increase the number of outgoing packets to detect the network quality based on the packet loss rate.

The value is an integer that ranges from 1 to 4294967295. The default value is 5.
-h ttl-value Specifies the TTL value.

If the TTL field is reduced to 0 during message forwarding, the Layer 3 switch that the message reaches sends an ICMPv6 timeout message to the source host, indicating that the destination host is unreachable.

The value is an integer that ranges from 1 to 255. The default value is 255.
-m time Specifies the time to wait before sending the next ICMPv6 Echo Request message.

Each time the source sends an ICMPv6 Echo Request message using the ping ipv6 command, the source waits a period of time (2000 ms by default) before sending the next ICMPv6 Echo Request message. You can set the time to wait before sending the next ICMPv6 Echo Request message using the parameter time. In the case of poor network condition, the value should be equal to or larger than 2000, in milliseconds.

The value is an integer that ranges from 1 to 10000, in milliseconds. The default value is 2000.
-name Displays the name of the destination host. -
-s packetsize

Specifies the length of an ICMPv6 Echo Request message, excluding the IP header and ICMPv6 header.

The value is an integer that ranges from 20 to 9600, in bytes. The default value is 56.
-t timeout

Specifies the timeout period to wait for an ICMPv6 Echo Reply message after an ICMPv6 Echo Request message is sent.

After the ping ipv6 command is run, the source sends an ICMPv6 Echo Request message to a destination and waits for an ICMPv6 Echo Reply message. If the destination, after receiving the ICMPv6 Echo Request message, returns an ICMPv6 Echo Reply message to the source within the period specified by the parameter timeout, the destination is reachable. If the destination does not return an ICMPv6 Echo Reply message within the specified period, the source displays that the message times out. Normally, the source receives an ICMPv6 Echo Reply message within 1 to 10 seconds after sending an ICMPv6 Echo Request message. If the transmission speed is low, properly prolong the timeout period.

The value is an integer that ranges from 0 to 65535, in milliseconds. The default value is 2000.
-tc traffic-class-value

Specifies the traffic classification in the ICMPv6 Echo Request message.

To configure traffic control for ICMPv6 packets, set the parameter traffic-class-value.

The value is an integer that ranges from 0 to 255. The default value is 0.
vpn-instance vpn-instance-name

Specifies the name of a VPN instance for the IPv6 address family.

The value must be an existing VPN instance name.
host

Specifies the host name or IPv6 address of the destination host.

The value is a string of 1 to 255 case-sensitive characters, spaces not supported. When double quotation marks are used around the string, spaces are allowed in the string. The IPv6 address is a 32–bit string in hexadecimal format, namely, the format X:X:X:X:X:X:X:X.
-i interface-type interface-number

Specifies the outbound interface for sending ICMPv6 Echo Request messages.

-

Views

All views

Default Level

0: Visit level

Usage Guidelines

Usage Scenario

The ping ipv6 command is a widely used debugging tool for checking network connectivity and host reachability on an IPv6 network by transmitting ICMPv6 messages. It can detect the following items:
  • Availability of the remote device
  • Round-trip delay in communication between the local and remote devices
  • Packet loss rate
You can run the ping ipv6 command to check the IPv6 network connectivity or line quality in the following scenarios:
  • Check the protocol stack on the local device. You can run the ping ipv6 IPv6-loopback-address command to check whether the TCP/IP protocol stack works properly on the local device.

  • Check whether the destination IPv6 host is reachable on an IPv6 network. You can run the ping ipv6 host command to send an ICMPv6 Echo Request message to the destination host. If a reply is received, the destination host is reachable.

  • Check whether the peer is reachable on a Layer 3 VPN. On a Layer 3 VPN, devices may not have routing information about each other. Therefore, you cannot use the ping ipv6 host command to check whether the peer is reachable. When a VPN instance name is specified, you can run the ping ipv6 vpn-instance vpn-instance-name host command to send an ICMPv6 Echo Request message to the peer. If the peer returns an ICMPv6 Echo Reply message, the peer is reachable.

  • In the case of an unstable network, you can run the ping ipv6 -c count -t timeout host command to check the quality of the network between the local device and the peer. By analyzing the packet loss rate and average delay in the command output, you can evaluate the network quality. If the network is unreliable, set the packet transmission count (-c) and timeout (-t) to the upper limits. This makes the test result accurate.

Prerequisites

  • Before running the ping ipv6 command, ensure that the ICMPv6 module is working properly.
  • If -vpn-instance is specified, ensure that the VPN module is working properly.

Precautions

  • If an intermediate device is disabled from responding to ICMPv6 messages, detection on this node fails.
  • If the IPv6 address of the destination host maps the local address, specify the name of the local outbound interface through which the ICMPv6 Echo Request message is sent. Otherwise, reply to the ping ipv6 command times out.
  • When the destination host is unreachable, the system displays "Request time out" indicating that the ICMPv6 Echo Request message times out and displays statistics collected by the IPv6 ping test.
  • If a fault occurs in the IPv6 ping process, you can press Ctrl+C to terminate the IPv6 ping operation.

Example

# Check whether the host with the IPv6 address as FC00::1 is reachable.

<HUAWEI> ping ipv6 FC00::1
 PING FC00::1 : 56  data bytes, press CTRL_C to break
    Reply from FC00::1
    bytes=56 Sequence=1 hop limit=64 time=115 ms
    Reply from FC00::1
    bytes=56 Sequence=2 hop limit=64 time=1 ms
    Reply from FC00::1
    bytes=56 Sequence=3 hop limit=64 time=1 ms
    Reply from FC00::1
    bytes=56 Sequence=4 hop limit=64 time=1 ms
    Reply from FC00::1
    bytes=56 Sequence=5 hop limit=64 time=1 ms
  ---FC00::1 ping statistics---
    5 packet(s) transmitted
    5 packet(s) received
    0.00% packet loss
    round-trip min/avg/max=1/23/115 ms          
Table 1 Description of the ping ipv6 command output

Item

Description

PING HH:HH::HH:H

IPv6 address of the destination host.

x data bytes

Length of a sent ICMPv6 Echo Request message.

press CTRL_C to break

The ongoing IPv6 ping test is terminated after you press Ctrl+C.

Reply from HH:HH::HH:H

The destination host responds to the ICMPv6 Echo Request message with an ICMPv6 Echo Reply message that contains the following items:
  • bytes: indicates the length of the ICMPv6 Echo Reply message.

  • sequence: indicates the sequence number of the ICMPv6 Echo Reply message.

  • hop limit: indicates the TTL of the ICMPv6 Echo Reply message.

  • time: indicates the RTT, in milliseconds.

If no ICMPv6 Echo Reply message is received after the timeout period, the system displays "Request time out".

HH:HH::HH:H ping statistics

Statistics collected after the IPv6 ping test on the destination host. The statistics include the following information:
  • packet(s) transmitted: indicates the number of sent ICMPv6 Echo Request messages.

  • packet(s) received: indicates the number of received ICMPv6 Echo Reply messages.

  • % packet loss: indicates the percentage of unresponded messages to total sent messages.

  • round-trip min/avg/max: indicates the minimum, average, and maximum RTTs.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >