{
  "$type": "site.standard.document",
  "bskyPostRef": {
    "cid": "bafyreic6xl7uwao7q6nzratpyxwacdz2h3uq3kcbdqalybsvlty5htusmy",
    "uri": "at://did:plc:25rdn5elo5izoxrmtis34zuk/app.bsky.feed.post/3moh6h4va3bf2"
  },
  "coverImage": {
    "$type": "blob",
    "ref": {
      "$link": "bafkreih3spxqkcxebvgjnmv7ebwm6krvq3elacjykews4mbg6rhd6wd4pu"
    },
    "mimeType": "image/webp",
    "size": 78690
  },
  "path": "/taqq/package-tracking-was-traceroute-all-along-understanding-route-tracing-through-ttl-2n50",
  "publishedAt": "2026-06-17T01:15:46.000Z",
  "site": "https://dev.to",
  "tags": [
    "comptia",
    "network",
    "begginer",
    "traceroute"
  ],
  "textContent": "##  Introduction\n\nWhile studying CompTIA Network+, I couldn't fully understand how Traceroute and Tracert work.\n\nI could memorize them as the tool for tracing routes, but I couldn't comprehend how they work and what TTL is.\nOnce I grasped them through familiar example, everything clicked, so I decided to write it down.\n\n##  What is Traceroute / Tracert\n\n**They are tools for investigating which route data takes to reach its destination**.\n\n###  The difference between Traceroute and Tracert\n\n\n    Traceroute → Command used in Linux・macOS\n    Tracert    → Command used in Windows\n\n    They work the same way, but the name differs depending on the OS.\n\n\n###  Why are they needed\n\n\n    Problem:\n    Cannot connect to network or delayed\n    Cannot identify where the problem is occurring\n\n    Solution:\n    Check each route data pass through\n     → Identify the router that delay or lost happens\n\n\n###  Familiar example\n\n\n    If a package sent from Tokyo to Osaka never arrives:\n\n    Check tracking number:\n     Warehouse in Tokyo → Center in Nagoya(The good is stopped at this facility)\n     → Find that the center in Nagoya has problem\n\n    Similarly, with Traceroute:\n     PC → Router A → Router B(Delay happens)→ Destination\n     → Find that Router B has problem\n\n\n##  Practical output image\n\n\n    $ traceroute google.com\n\n    1  192.168.1.1      1ms   1ms   1ms   ← Home Router\n    2  10.0.0.1         5ms   5ms   5ms   ← ISP Router\n    3  172.16.0.1      10ms  10ms  10ms   ← Intermediate Router\n    4  8.8.8.8         20ms  20ms  20ms   ← Destination\n\n\n###  How to check the output\n\n\n    Number(1・2・3)= Hop count(Passed Router number)\n    IP Address     = The address of the Router\n    ms            = Response time(3 times measuring)\n\n    * * *         = No response(Timeout)\n     → Settings that the Router do not response\n     → Or any problem happens\n\n\n##  What is TTL\n\nTTL stands for **Time To Live**\n\nIn a nutshell, **remaining number that packets can pass routes**\n\n###  Why TTL is needed\n\n\n    Problem:\n    If packets cannot reach their destinations and keep flowing in network\n     ↓\n    Traffic congestion happens in network\n     ↓\n    Harm for other communication\n\n    Solution:\n    Attach a limit to each packet\n     → Discard the packet after it passes through a set number of routers\n     → Avoid network congestion\n\n\n###  How TTL works\n\n\n    Packets generate:\n    TTL = 128(In case of Windows)\n    TTL = 64(In case of Linux/mac)\n     ↓\n    Each time a packet passes through a router, the TTL decreases by one\n     ↓\n    When TTL reaches 0, the packet is discarded\n     ↓\n    「Time Exceeded」message is sent to senders\n\n\n###  Understanding with diagram\n\n\n    PC(Sent at TTL=3)\n     ↓\n    Router A Passed\n    (TTL decreases from 3 to 2 )\n     ↓\n    Router B Passed\n    (TTL decreases from 2 to 1 )\n     ↓\n    Router C\n    (TTL decreases from 1 to 0 )\n     → The packet is discarded\n     → Send 「Time Exceeded」message to PC\n     ↓\n    Don't reach them to the destination\n\n\n##  The mechanism Traceroute / Tracert use TTL\n\nThis is the core concept of this article\n\n\n\n    Step 1:TTL = 1\n     ↓\n    TTL becomes 0 at Router A\n     ↓\n    Router A sends「Time Exceeded」message\n     ↓\n    1 hop identified : Router A(192.168.1.1)\n\n    Step 2:TTL = 2\n     ↓\n    Pass Router A (TTL 2→1)\n    TTL becomes 0 at Router B\n     ↓\n    Router B sends「Time Exceeded」message\n     ↓\n    Find 2hop = Router B(10.0.0.1)\n\n    Step 3:TTL = 3\n     ↓\n    Pass Router A・B\n    TTL becomes 0 at Router C\n     ↓\n    Router C sends 「Time Exceeded」message\n     ↓\n    Find 3hop = Router C(172.16.0.1)\n\n    Step 4:TTL = 4\n     ↓\n    Arrive at destination\n     ↓\n    「Arrived」message is sent\n     ↓\n    Traceroute complete\n\n\n###  Understanding with courier service\n\n\n    Imagine a rule applied to every package:\n    ①The count decreases by one at each relay center\n    ②When the count reaches 0, a status message is sent back\n\n\n    TTL = 1:Goods stop at the warehouse in Tokyo\n     → Message「Arrived at warehouse at Tokyo」\n\n    TTL = 2:Tokyo → Nagoya\n    Goods stop at the relay center in Nagoya\n     →Message「Arrived at the relay center in Nagoya」\n\n    TTL = 3:Tokyo → Nagoya → Osaka\n    Goods stop at the relay center in Osaka\n     →Message「Arrived at the relay center in Osaka」\n\n    TTL = 4:Tokyo → Nagoya → Osaka → Destination\n    Goods arrive to the destination\n     → Message「Delivery completed」\n\n\n##  Which layer does Traceroute / Tracert operate on?\n\n\n    Layer 7  Application       │\n    Layer 6  Presentation      │\n    Layer 5  Session           │  Not applicable for Traceroute\n    Layer 4  Transport         │\n    ─────────────────────────────\n    Layer 3  Network      ← Traceroute works\n    ─────────────────────────────\n    Layer 2  Data Link         │\n    Layer 1  Physical          │\n\n\n\n    The reason why Traceroute / Tracert work at Layer 3:\n     → Tracking routes with IP address\n     → TTL is included in IP header\n\n\n##  Summary\n\n\n    Traceroute/Tracert :Tool for investigating the route data pass through\n\n    The difference of OS:\n     Linux/mac → traceroute\n     Windows   → tracert\n\n    TTL :The remaining number of routers a packet can pass through\n     → Decreases by 1 each time it passes through a router\n     → 0 means the packet is discarded and send Time Exceeded message\n\n    Traceroute / Tracert use TTL:\n     Send data with TTL\n     → Each router send「Time Exceeded」message, which can verify how many hop counted\n     → Can comprehend routes overall\n\n    OSI refecence model:Layer 3(Network Layer)\n\n    Use case:\n     → Not connect to network\n     → Lag and delay with communication\n     → Identify which router is causing the problem\n\n\n##  Conclusion\n\nI used to struggle with memorizing these tools over and over.\nOnce I understood the mechanism through a familiar example, everything naturally fell into the place.\n\n\n\n    TTL = Expiration time packets have(Remaining hop count router can pass )\n     → Count down by 1 as router pass\n     → 0 means responding「Time Exceeded」message\n\n    Traceroute / Tracert = Tool for identifying where the issue occurs by increasing TTL number from 1\n",
  "title": "Package Tracking Was Traceroute All Along — Understanding Route Tracing Through TTL"
}