• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL



traceroute Prints the route packets take to a network host.
traceroute [-d] [-D] [-g <gateway_addr>] [-l] [-m <max_tt>] [-n] [-p
<port>] [-q <nqueries>] [-r] [-s <src_addr>] [-t <tos>] [-v] [-w <wait-
									time>] <host> [<packetsize>]

traceroute uses the IP protocol time-to-live field and attempts to elicit an ICMP TIME_EXCEEDED response from each gateway along the path to the same host.
The only mandatory parameter is <host>>—the destination host or IP number. The default probe datagram length is 38 bytes, but this can be increased by specifying a packet size (in bytes) after the destination host name.
-d Turns on socket-level debugging.
-D Dumps the packet data to standard error before transmitting it.
-g <gateway_addr> Adds <gateway_addr> to the list of addresses in the IP Loose Source Record Route (LSRR) option. If no gateways are specified, the LSRR option is omitted.
-l Displays the ttl value of the returned packet. This is useful for checking asymmetric routing.
-m <max_ttl> Sets the maximum time-to-live (maximum number of hops) used in outgoing probe packets. The default is 30 hops. The same default is used for TCP connections.
-n Prints hop addresses numerically rather than symbolically and numerically (saves a nameserver address-to-name lookup for each gateway found on the path).
-p <port> Sets the base UDP port number used in probes to <port>. Default is 33434. traceroute hopes that nothing is listening on UDP <base> to <base+nohops+1> at the destination host, so that an ICMP PORT_UNREACHABLE message will be returned to terminate the route tracing. If something is listening on a port in the default range, this option can be used to pick an unused port range.
-q <nqueries> Sets the number of probes per ttl to <nqueries>. Default is three probes.
-r Bypasses the normal routing tables and sends directly to a host on an attached network. If the host is not on a directly attached network, an error is returned. This option can be used to ping a local host through an interface that has no route through it.
-s <src_addr> Uses the following IP address (which must be given as an IP number, not a host name) as the source address in outgoing probe packets. On hosts with more than one IP address, this option can be used to force the source address to be something other than the IP address of the interface that the probe packet is sent on. If the IP address is not one of this machine's interfaces, an error is returned and nothing is sent.
-t <tos> Sets the type-of-service in probe packets to <tos>. Default is 0. Value must be a decimal integer in the range 0 to 255. This option can be used to see whether different types-of-service result in different paths. Not all values of TOS are legal or meaningful. See the IP spec for definitions. Useful values are probably -t 16 (low delay) and -t 8 (high throughput).
-v Sets to verbose output. Lists ICMP packets received other than TIME_EXCEEDED and UNREACHABLE packets.
-w <waittime> Sets the time to wait for a response to a probe to <waittime> seconds. Default is three seconds.



Not a subscriber?

Start A Free Trial

  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint