traceroute

Use this command to display a hop-by-hop path through an IP network from the device to a specific destination host.

Syntax

traceroute [-d ip-address] [-F] [-f first_ttl] [-I] [-i interface] [-m max_ttl] [-n] [-p port] [-q nqueries] [-r] [-s source-address] [-t tos] [-v {4 | 6}] [-V router][-w waittime] [-x] host

Parameters

-d ip-address (Optional) Performs a reverse lookup (finds a hostname that matches the specified IP address).
-F (Optional) Specifies that the traceroute packet should not be fragmented.
-f first-TTL (Optional) Specifies the maximum Time-To-Live (TTL) used in the first outgoing probe packets. Default value: 1.
-I (Optional) Specifies that ICMP echo requests should be used instead of UDP datagrams.
-i source-interface (Optional) Specifies the IP source interface (for example vlan.0.5 for VLAN 5).
-m max-ttl (Optional) Specifies the maximum Time-To-Live (TTL) for outgoing packets. Default value: 30.
-n host-ip-address (Optional) Specifies that name server contact should be avoided. All hops are listed numerically.
-p udp-dest-port (Optional) Specifies the initial UDP destination port. For each sent probe the UDP destination port is increased by one. Valid values: 1-65535. Default value: 33434.
-q number-of-probes (Optional) Specifies the number of probes to send out for each hop. Valid values: 1 - 255. Default value: 3.
-r (Optional) Specifies that normal host routing tables should be bypassed.
-s source-ip-address (Optional) Specifies the source IP address for the traceroute probes.
-t tos (Optional) Specifies the Type-of-Service (ToS) for IPv4 or the traffic class for IPv6. Valid Values 0 - 255. Default value: 0.
-v version (Optional) Forces traceroute to use either IPv4: 4 or IPv6: 6. The IP version is auto-detected by default (not configurable).
-V router (Optional) Specifies the virtual router to use for this traceroute. The default value is 0 (default router).
-w period (Optional) Specifies the time in seconds to wait for a response to a probe. Valid values: 0 - 255. Default value: 5.
-x (Optional) Specifies that traceroute should not calculate checksum.
host host Specifies an IP address or a host to find a route to.

Defaults

  • If -d is not specified, a reverse lookup is not performed.
  • If -F is not specified, the traceroute will be fragmented if necessary.
  • If -f is not specified, the maximum TTL in the first probe packet is set to 1.
  • If -i is not specified, the route table chooses the source IP interface.
  • If -I is not specified, UDP datagrams are used.
  • If -m is not specified, the maximum TTL in outgoing probes is 30.
  • If -n is not specified, name server contacts are not avoided.
  • If -p is not specified, the initial UDP destination port is set to 33434.
  • If -q is not specified, the number of probes sent out for each hop is set to 3.
  • If -r is not specified, host routing tables are not bypassed.
  • If -s is not specified, the route table chooses the source IP address.
  • If -t is not specified, the ToS or traffic class is set to 0.
  • If -v is not specified, the IP version is set to auto-detect.
  • If -V is not specified, virtual router 0 (default) is used.
  • If -w is not specified, the time to wait for a probe response is set to 5 seconds.
  • If -x is not specified, the traceroute calculates the checksum.

Mode

All command modes.

Usage

Possible annotations returned after the probe response time (-w) are:

  • !H - host is unreachable
  • !N - network is unreachable
  • !P - protocol is unreachable
  • !S - source route failed
  • !F-<pmtu> - fragmentation needed; the RFC1191 Path MTU Discovery value is dis-played
  • TOS=value! - TOS has been altered in the path to <value>
  • !X - communication administratively prohibited
  • !V - host precedence violation
  • !C - precedence cutoff in effect
  • !num - ICMP unreachable code num

These annotations are defined by RFC1812 which supersedes RFC1716. If almost all the probes result in an unreachable device or type, traceroute will give up and exit.

Example

This example shows how to use traceroute to display a round trip path to host 192.167.252.17. In this case, hop 1 is the Extreme Networks S- K- and 7100-Series switch, hop 2 is 14.1.0.45, and hop 3 is back to the host IP address. Round trip times for each of the three UDP probes are displayed next to each hop:

System(rw)->traceroute 192.167.252.17
traceroute to 192.167.252.17 (192.167.252.17), 30 hops max, 40 byte packets
  1  matrix.extremenetworks.com (192.167.201.40)  20.000 ms  20.000 ms  20.000 ms
  2  14.1.0.45 (14.1.0.45)  40.000 ms  10.000 ms  20.000 ms
  3  192.167.252.17 (192.167.252.17)  50.000 ms  0.000 ms  20.000 ms