Introduction To Network Layer: Computer
Introduction To Network Layer: Computer
Lecture 3
Introduction to Network Layer
The passage of a
message from a source to
a destination involves
many decisions. When a
message reaches a
connecting device, a
decision needs to be
made to select one of the
output ports through
which the packet needs
to be send out. In other
words, the connecting
device acts as a switch
that connects one port to
another port.
Switching, Forwarding and Routing
When the Internet started, the network layer was designed to provide a
connectionless service, in which the network layer protocol treats each
packet independently, with each packet having no relationship to any
other packet.
Network
A connectionless
packet-swtiched network
R1 R2
4 3 2 1 2
Sender 1
Network
4
2
3
R4 1
3 3
4 1 3 4 2
R3 R5 Out of order Receiver
Forwarding process in a connectionless network
Each packet is routed based on the information contained in its header: source
and destination address. The destination address defines where it should go; the
source address defines where it comes from. The router in this case routes the
packet based only on the destination address. The source address may be used to
send an error message to the source if the packet is discarded
SA DA Data SA DA Data
1 2
3 4
Delay in a connectionless network
Destination
Souce
Total delay
2
4 3 2 1
4
3
2
1
4 3 2 1 4 3 2 1
Forwarding process in a connection-oriented network
Routing Table
Legend
Incoming Outgoing
SA: Source address
Port Label Port Label DA: Destination address
1 L1 2 L2 L1, L2: Labels
1 2
3 4
Delay in a connection-oriented network
Source Destination
1
Setup
2
Total delay
3 Transmission
time
4
5
Teardown