8 Switching 14 02 2023
8 Switching 14 02 2023
J. Dheeba/SCOPE
Switching
• The network layer is concerned with getting packets from the source
all the way to the destination.
• Getting to the destination may require making many hops at
intermediate routers along the way.
• Store-and-Forward Packet Switching
• A host with a packet to send transmits it to the nearest
router, either on its own LAN or over a point-to-point link to
the ISP.
• The packet is stored there until it has fully arrived and the
link has finished its processing by verifying the checksum.
• Then it is forwarded to the next router along the path until it
reaches the destination host, where it is delivered.
• This mechanism is store-and-forward packet switching
• Switching in connectionless service
• If connectionless service is offered, packets are injected into the
network individually and routed independently of each other.
• No advance setup is needed. In this context, the packets are
frequently called datagrams and the network is called a datagram
network.
• How a datagram network works?
• Suppose that the process P1 has a long message for P2.
• It hands the message to the transport layer, with instructions to deliver
it to process P2 on host H2.
• The transport layer code runs on H1, typically within the operating
system.
The algorithm that manages the
tables and makes the routing
decisions is called the routing
algorithm
• Switching in Connection-Oriented Service
• For connection-oriented service - virtual-circuit network is
required
• The idea behind virtual circuits is to avoid having to choose a new
route for every packet sent.
• Instead, when a connection is established, a route from the source
machine to the destination machine is chosen as part of the
connection setup and stored in tables inside the routers
• When the connection is released, the virtual circuit is also
terminated.
• With connection-oriented service, each packet carries an identifier
telling which virtual circuit it belongs to.
what happens if H3 also wants to
establish a connection to H2?