Monday, 28 November 2016

Tracert

  • Tracert is a command-line utility that you can use to trace the path that an Internet Protocol (IP) packet takes to its destination.
  • It also calculates and displays the amount of time each hop took.


Working process

  • When you enter the tracert command, the utility initiates the sending of a packet using the Internet Control Message Protocol (ICMP).
  • In these packets, tracert uses varying IP Time-To-Live (TTL) values. Because each router along the path is required to decrement the packet's TTL by at least 1 before forwarding the packet.
  • When the TTL on a packet reaches 0, the router sends an ICMP "Request timed out" message back to the source computer.
  • Tracert sends the first packet with a TTL of 1 and increments the TTL by 1 on each subsequent transmission until the destination respond.
  • The ICMP "Request timed out" messages that intermediate routers send back show the route.
  • However that some routers silently drop packets that have expired TTLs and these packets are invisible to tracert.


  • Tracert prints out an ordered list of the intermediate routers that return ICMP "Request timed out" messages.


Tracert syntax

tracert [-d] [-h MaxHops] [-j HostList] [-w TimeOut] target [/?]
-d
  • This option prevents tracert from resolving IP addresses to hostnames, often resulting in much faster results.


-h MaxHops
  • It determine maximum number of hops in the search for the target.
  • If you do not specify MaxHops, and target has not been found by 30 hops, tracert will stop looking.
-j HostList
  • Specifies loose source route along the host-list.
-w TimeOut
  • Waits the number of milliseconds specified by timeout for each reply.
target
  • Specifies the name or IP address of the target host.
/?
  • Use the help switch with the tracert command to show detailed help about the command's several options.

No comments: