CompTIA Network+ Certification Guide
上QQ阅读APP看书,第一时间看更新

ICMP Type 11 – Time Exceeded

Whenever a packet or message is sent on a network, a Time to Live (TTL) value is attached. The TTL value decreases after passing reach layer 3 devices such as a router along the way to the destination. If the TTL value reaches zero before arriving at the intended destination, the last router to change the TTL value to zero will send an ICMP Type 11 message back to the sender indicating the TTL expired and the packet has been discarded before reaching its destination. The -i parameter adjusts the TTL value on the ICMP message:

C:\>ping 8.8.8.8 -i 4

Pinging 8.8.8.8 with 32 bytes of data:
Reply from 179.60.213.149: TTL expired in transit.
Reply from 179.60.213.66: TTL expired in transit.
Reply from 179.60.213.66: TTL expired in transit.
Reply from 179.60.213.66: TTL expired in transit.

Ping statistics for 8.8.8.8:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),

Without adjusting the TTL value of the ICMP Type 8 message, the sender received an ICMP Type 0 message indicating successful transmission between both devices:

C:\>ping 8.8.8.8

Pinging 8.8.8.8 with 32 bytes of data:
Reply from 8.8.8.8: bytes=32 time=52ms TTL=120
Reply from 8.8.8.8: bytes=32 time=52ms TTL=120
Reply from 8.8.8.8: bytes=32 time=52ms TTL=120
Reply from 8.8.8.8: bytes=32 time=52ms TTL=120

Ping statistics for 8.8.8.8:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milliseconds:
Minimum = 52ms, Maximum = 52ms, Average = 52ms
Further information of ICMP can also be found at  https://tools.ietf.org/html/rfc792. Further information of all the ICMP message types can be found at: https://www.iana.org/assignments/icmp-parameters/icmp-parameters.xhtml#icmp-parameters-codes-7.

A simple and easy-to-use utility is Ping. The Ping utility harnesses the functionality of ICMP and provides meaningful feedback whether communication is successful, unsuccessful, redirected, the destination host or network is unreachable, and so on. The Ping utility is integrated into almost every, if not all, modern-day operating systems, from desktops to servers, and even mobile-operating systems.

The ping command can be executed in Windows Command Prompt or the Terminal of Linux-based operating systems. When a user initiates the ping command with a destination address, the Ping utility sends an ICMP Type 8 message to the intended destination. The syntax for checking basic connectivity is as follows:

ping <ip address or hostname>
ping 8.8.8.8
ping www.google.com