An Error Reporting Mechanism ICMP 1 IP Semantics

  • Slides: 15
Download presentation
An Error Reporting Mechanism (ICMP) 1

An Error Reporting Mechanism (ICMP) 1

IP Semantics • IP is best-effort • Datagrams can be – Lost – Delayed

IP Semantics • IP is best-effort • Datagrams can be – Lost – Delayed – Duplicated – Delivered out of order – Corrupted 2

Error Detection • IP does not – Introduce errors – Ignore all errors •

Error Detection • IP does not – Introduce errors – Ignore all errors • Errors detected – Corrupted bits – Illegal addresses – Routing loops – Fragment loss 3

Problems And Solutions • Corrupted header bits – Header checksum • Illegal destination address

Problems And Solutions • Corrupted header bits – Header checksum • Illegal destination address – Routing tables • Routing loop – Time-To-Live (TTL) field • Fragment loss – Timeout 4

Internet Control Message Protocol (ICMP) • Separate protocol for – Errors – Information •

Internet Control Message Protocol (ICMP) • Separate protocol for – Errors – Information • Required part of IP • Sends error messages to original source 5

Example ICMP Message Types 6

Example ICMP Message Types 6

Example ICMP Messages • Source Quench – Sent by router – Triggered by datagram

Example ICMP Messages • Source Quench – Sent by router – Triggered by datagram overrun – Requests sending host(s) to slow down 7

Example ICMP Messages (continued) • Time Exceeded – Sent by router • TTL on

Example ICMP Messages (continued) • Time Exceeded – Sent by router • TTL on datagram reached zero • Not a request for retransmission – Sent by host • Reassembly timeout (some fragments lost) 8

Example ICMP Messages (continued) • Destination unreachable – Specifies whether • Destination network unreachable

Example ICMP Messages (continued) • Destination unreachable – Specifies whether • Destination network unreachable • Destination host unreachable • Protocol port on destination unreachable 9

Example ICMP Messages (continued) • Redirect – Sent by router – Goes to host

Example ICMP Messages (continued) • Redirect – Sent by router – Goes to host on local network – Host used incorrect initial router – Requests host to change routes 10

Example ICMP Messages (continued) • Echo request and reply – Not an error –

Example ICMP Messages (continued) • Echo request and reply – Not an error – Tests whether destination reachable – Request sent by ping program – Reply sent by ICMP on destination computer 11

ICMP Message Transport • Error messages go back to original source (may cross internet)

ICMP Message Transport • Error messages go back to original source (may cross internet) • Messages carried in IP 12

Illustration Of ICMP Message Encapsulation • Two levels of encapsulation • IP type field

Illustration Of ICMP Message Encapsulation • Two levels of encapsulation • IP type field specifies ICMP 13

Avoiding An Infinite Loop • What happens if: – Datagram D causes an ICMP

Avoiding An Infinite Loop • What happens if: – Datagram D causes an ICMP error message, I 1 – Error message I 1 causes another error, which generates ICMP message I 2 – Message I 2 generates another error, I 3 – Error messages cascade • To avoid the problem – No error messages about ICMP error messages 14

Path MTU Discovery • IP datagram header contains a bit to specify no fragmentation

Path MTU Discovery • IP datagram header contains a bit to specify no fragmentation allowed • ICMP sends an error message when fragmentation required, but not permitted • Technique – Probe to find largest MTU that does not generate an error message • Note: path MTU not guaranteed if routes change 15