Internet Control Message Protocol

The second network-level protocol is the Internet Control Message Protocol (ICMP). ICMP is a required part of every IP implementation. ICMP handles error and control messages for IP.

This protocol allows gateways and hosts to send problem reports to the machine sending a packet. ICMP does the following:

  • Tests whether a destination is alive and reachable
  • Reports parameter problems with a datagram header
  • Performs clock synchronization and transit time estimations
  • Obtains Internet addresses and subnet masks
Note: ICMP uses the basic support of IP as if it were a higher-level protocol. However, ICMP is actually an integral part of IP and must be implemented by every IP module.

ICMP provides feedback about problems in the communications environment, but does not make IP reliable. That is, ICMP does not guarantee that an IP packet is delivered reliably or that an ICMP message is returned to the source host when an IP packet is not delivered or is incorrectly delivered.

ICMP messages might be sent in any of the following situations:

  • When a packet cannot reach its destination
  • When a gateway host does not have the buffering capacity to forward a packet
  • When a gateway can direct a host to send traffic on a shorter route

TCP/IP sends and receives several ICMP message types (see Internet Control Message Protocol message types). ICMP is embedded in the kernel, and no application programming interface (API) is provided to this protocol.