Time to live (TTL) is a system that limits the lifetime of data packets traveling across the internet before being discarded by a router.
In addition, TTL (or hop limit) prevents the packet sent from continuing indefinitely to hop from router to router. TTL is mainly used to enhance performance and manage data caching.
Packet TTL can also help determine how long a packet has circulated and inform the sender about its path throughout the net.
How Does TTL Work?
Every packet created stores a numerical value limiting the time of its movement through a network. Whenever a router receives a packet, it subtracts one from the TTL count and passes it to the following network location. If the subtraction leaves a zero count, the router discards the packet and sends an ICMP message to the initiating host.