Configuring tracert, Configuration prerequisites, Tracert configuration – H3C Technologies H3C SR8800 User Manual

Page 16

Advertising
background image

4

Figure 2 Tracert operation

Traceroute uses received ICMP error messages to get the IP addresses of devices. As shown in

Figure 2

,

traceroute works as follows:

1.

The source device (Device A) sends a UDP packet with a TTL value of 1 to the destination device
(Device D). The destination UDP port is not used by any application on the destination device.

2.

The first hop (Device B, the first Layer 3 device that receives the packet) responds by sending a
TTL-expired ICMP error message to the source device, with its IP address encapsulated. In this way,
the source device can get the address of the first Layer 3 device (1.1.1.2).

3.

The source device sends a packet with a TTL value of 2 to the destination device.

4.

The second hop (Device C) responds with a TTL-expired ICMP error message, which gives the
source device the address of the second Layer 3 device (1.1.2.2).

5.

The above process continues until the packet sent by the source device reaches the ultimate
destination device. Since no application uses the destination port specified in the packet, the

destination device responds with a port-unreachable ICMP message to the source device, with its

IP address encapsulated. In this way, the source device gets the IP address of the destination

device (1.1.3.2).

6.

The source device thinks that the packet has reached the destination device after receiving the
port-unreachable ICMP message, and the path to the destination device is 1.1.1.2 to 1.1.2.2 to

1.1.3.2.

Configuring tracert

Configuration prerequisites

Enable sending of ICMP timeout packets on the intermediate device (the device between the source and

destination devices). If the intermediate device is an H3C device, execute the ip ttl-expires enable

command on the device. For more information about this command, see Layer 3—IP Services Command
Reference
.
Enable sending of ICMP destination unreachable packets on the destination device. If the destination

device is an H3C device, execute the ip unreachables enable command. For more information about this

command, see Layer 3—IP Services Command Reference.

Tracert configuration

To configure tracert:

Advertising