TCP/IP layers
TCP/IP layer | Protocol Data Unit (PDU) |
---|---|
Physical layer | bits |
Data link layer | frame |
Network layer | packet |
Transport layer | segment |
Application layer | - |
Types of TCP/IP devices:
- end system
- intermediate node (e.g. routes), it usually only involves the 3 first layers
Data link vs Network layer
The biggest difference between the data link and the network layers is that the data link layer is in charge of data delivery between adjacent systems whereas the network layer delivers data between systems that are not directly connected.
Therefore the network layer is responsible for determining the path between the 2 systems but each individual hop along that path is delegated to the data link layer. For that to work, it is necessary to translate the IP address of each system along the path into its physical address. That is the responsibility of the ARP (Address Resolution Protocol)
IP fragmentation
In some cases, the packet that arrives at an intermediate system inside a frame is too large to fit inside the frame that must be sent out (as different link types have different maximum frame sizes). As a result, the network layer must be able to fragment a packet across multiple frames and reassemble the fragments at the destination.
Network layer protocols
- IPv4
- IPv6
- ARP (Address Resolution Protocol): to translate IP addresses into physical addresses
- ICMP (Internet Control Message Protocol): protocol to transmit data concerning the status of the network layer itself
Network vs Transport layer
Network layer gets a single packet to the right system whereas the transport layer gets the entire message to the right process. To the network layer, each packet is an independent unit.