Traceroute references
References for traceroute.
Traceroute syntax on Windows
Example of traceroute command on Windows:
tracert [-d] [-h maximum hops] [-j host list] [-w timeout] [-R] [-S scraddr] [-4] [-6] target_name
The list of parameters available on Windows systems are:
Parameters | Description |
---|---|
-d | Do not resolve addresses to hostnames. |
-h maximum_hops | Maximum number of hops to search for target. |
-j host-list | Loose source route along host-list (IPv4-only). |
-w timeout | Wait timeout milliseconds for each reply. |
-R | Trace round-trip path (IPv6-only). |
-S srcaddr | Source address to use (IPv6-only). |
-4 | Force using IPv4. |
-6 | Force using IPv6. |
Traceroute syntax on MacOS and Linux
Example of traceroute command on MacOS and Linux:
traceroute [-n] [-w wait_time] [-i initial_ttl] [-m max_ttl] [-p dest_port] [-q n_queries] [-t tos] host [data_size]
The list of parameters available on MacOS and Linux-based systems are:
Parameters | Description |
---|---|
-n | Prevents traceroute from performing a DNS lookup for each hop. |
-w wait_time | Specify the amount of time (in seconds) that traceroute will wait for an ICMP response message. Allowed range is 1 to 300 seconds, default is 5 seconds. |
-i initial_ttl | Causes traceroute to send ICMP datagrams with a TTL value equal to
initial_ttl instead of the default TTL of 1. This causes traceroute to skip processing for hosts that are less than
initial_ttl hops away. |
-m max_ttl | Specify the maximum TTL value for outgoing ICMP datagrams. Allowed range for max_ttl is 1 to 255, default value is 30. |
-p dest_port | Specify the base UDP destination port number used in traceroute datagrams. Allowed range for
dest_port is 1 to 65535, default base port is 33434. |
-q n_queries | Specify the number of datagrams to send for each TTL value. Allowed range for n_queries is 1 to 1000, default is 3. |
-t tos | Specify the TOS to be set in the IP header of the outgoing datagrams. Allowed range for tos is 0 to 255; default is 0. |
host | IP alias or IP address in dot notation (a.b.c.d) of the destination host. |
data_size | Number of bytes, in addition to the default of 40 bytes, of the outgoing datagrams. The allowed range is 0 to 1420, default is 0. |