In: Computer Science
What are the functions of the Network Layer? Please explain encapsulation and fragmentation and reassembly in the Network Layer.
The Network Layer is the third layer of the OSI model. And the functions that it performs are :
1 . The network layer receives the frames from the data link layer, and deliver them to the destinations on the addresses that present inside the frame.
2. The network layer finds the destination address, by using the logical addresses, ie. IP (internet protocol).
3. Packetizing – The process of encapsulating the data received from data link layer in a network layer packet at the source and decapsulating that from the network layer packet at the destination address is known as packetizing
4. Routing and Forwarding :
Routing is a process which delivers the packet to the destination by choosing an optimal path from one network to another.
Forwarding is defined as the action that is applied by each router in this network when a packet arrives at one of its interfaces.
Encapsulation :
The encapsulation is a process of adding headers and trailers around some data. In network layer, each packet, which contains header and encapsulated data, defined as the following :
Fragmentation :
Fragmentation occurs by the network layer when the maximum size of datagram is greater than maximum size of data that can be hold a frame, then fragments of data will occur.
It is a process of breaking the packets into the smallest individual data units then that will travel through different networks.
Reassembly in Network layer :
Reassembly is the process where the re-assembly of the fragments that takes place at the destination. These fragments may arrive out of order , after they are reassembled.