0% found this document useful (0 votes)
73 views47 pages

Delivery, Forwarding, Routing

The document discusses network layer delivery, forwarding, and routing. It covers direct versus indirect delivery, forwarding techniques and process using routing tables, and unicast routing protocols including RIP, OSPF, and BGP. Examples illustrate forwarding processes, hierarchical routing with ISPs, and concepts of distance vector and link state routing.

Uploaded by

ARYAMAN DWIVEDI
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
73 views47 pages

Delivery, Forwarding, Routing

The document discusses network layer delivery, forwarding, and routing. It covers direct versus indirect delivery, forwarding techniques and process using routing tables, and unicast routing protocols including RIP, OSPF, and BGP. Examples illustrate forwarding processes, hierarchical routing with ISPs, and concepts of distance vector and link state routing.

Uploaded by

ARYAMAN DWIVEDI
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 47

Chapter 22

Network Layer:
Delivery, Forwarding,
and Routing

22.1
22-1 DELIVERY

The network layer supervises the handling of the


packets by the underlying physical networks. We
define this handling as the delivery of a packet.

Topics discussed in this section:


Direct Versus Indirect Delivery

22.2
Figure 22.1 Direct and indirect delivery

22.3
22-2 FORWARDING

Forwarding means to place the packet in its route to


its destination. Forwarding requires a host or a router
to have a routing table. When a host has a packet to
send or when a router has received a packet to be
forwarded, it looks at this table to find the route to the
final destination.

Topics discussed in this section:


Forwarding Techniques
Forwarding Process
Routing Table

22.4
Forwarding Techniques
Figure 22.2 Route method versus next-hop method

22.5
Figure 22.3 Host-specific versus network-specific method

22.6
Figure 22.4 Default method

Note: default (normally defined as network address 0.0.0.0)

22.7
Forwarding Process
Figure 22.5 Simplified forwarding module in classless address

22.8
Note

In classless addressing, we need at least


four columns in a routing table.

22.9
Example 22.1

Make a routing table for router R1, using the


configuration in Figure 22.6.

Solution
Table 22.1 shows the corresponding table.

22.10
Figure 22.6 Configuration for Example 22.1

22.11
Table 22.1 Routing table for router R1 in Figure 22.6

22.12
Example 22.2

Show the forwarding process if a packet arrives at R1 in


Figure 22.6 with the destination address 180.70.65.140.
Solution
The router performs the following steps:
1. The first mask (/26) is applied to the destination address.
The result is 180.70.65.128, which does not match the
corresponding network address.
2. The second mask (/25) is applied to the destination
address. The result is 180.70.65.128, which matches the
corresponding network address. The next-hop address
and the interface number m0 are passed to ARP for
further processing.
22.13
Example 22.3

Show the forwarding process if a packet arrives at R1 in


Figure 22.6 with the destination address 201.4.22.35.

Solution
The router performs the following steps:
1. The first mask (/26) is applied to the destination
address. The result is 201.4.22.0, which does not
match the corresponding network address.
2. The second mask (/25) is applied to the destination
address. The result is 201.4.22.0, which does not
match the corresponding network address (row 2).
22.14
Example 22.3 (continued)

3. The third mask (/24) is applied to the destination


address. The result is 201.4.22.0, which matches the
corresponding network address. The destination
address of the packet and the interface number m3 are
passed to ARP.

22.15
Example 22.4

Show the forwarding process if a packet arrives at R1 in


Figure 22.6 with the destination address 18.24.32.78.

Solution
This time all masks are applied, one by one, to the
destination address, but no matching network address is
found. When it reaches the end of the table, the module
gives the next-hop address 180.70.65.200 and interface
number m2 to ARP. This is probably an outgoing package
that needs to be sent, via the default router, to someplace
else in the Internet.

22.16
Figure 22.7 Address aggregation

22.17
Figure 22.8 Longest mask matching

22.18
Example 22.5

As an example of hierarchical routing, let us consider


Figure 22.9. A regional ISP is granted 16,384 addresses
starting from 120.14.64.0. The regional ISP has decided
to divide this block into four subblocks, each with 4096
addresses. Three of these subblocks are assigned to three
local ISPs; the second subblock is reserved for future use.
Note that the mask for each block is /20 because the
original block with mask /18 is divided into 4 blocks.
The first local ISP has divided its assigned subblock into
8 smaller blocks and assigned each to a small ISP. Each
small ISP provides services to 128 households, each using
four addresses.
22.19
Example 22.5 (continued)

The second local ISP has divided its block into 4 blocks
and has assigned the addresses to four large
organizations.
The third local ISP has divided its block into 16 blocks
and assigned each block to a small organization. Each
small organization has 256 addresses, and the mask is
/24.
There is a sense of hierarchy in this configuration. All
routers in the Internet send a packet with destination
address 120.14.64.0 to 120.14.127.255 to the regional ISP.

22.20
Figure 22.9 Hierarchical routing with ISPs

22.21
Routing Table

Static Routing Table:

 A static routing table contains information entered manually.


 static routing table can be used in a small internet that does
not change very often.
 It is poor strategy to use a static routing table in a big internet
such as the Internet.

Dynamic Routing Table:

 A dynamic routing table is updated periodically by using one


of the dynamic routing protocols such as RIP, OSPF, or BGP.
 Whenever there is a change in the Internet, such as a shutdown
of a router or breaking of a link, the dynamic routing protocols
update all the tables in the routers automatically.

22.22
Figure 22.10 Common fields in a routing table

22.23
22-3 UNICAST ROUTING PROTOCOLS

A routing table can be either static or dynamic. A static


table is one with manual entries. A dynamic table is one
that is updated automatically when there is a change
somewhere in the Internet. A routing protocol is a
combination of rules and procedures that lets routers in
the Internet inform each other of changes.
Topics discussed in this section:
Optimization
Intra- and Interdomain Routing
Distance Vector Routing and RIP
Link State Routing and OSPF
Path Vector Routing and BGP
22.24
Figure 22.12 Autonomous systems

22.25
Figure 22.13 Popular routing protocols

• Routing Information Protocol (RIP)


• Open Shortest Path First (OSPF)
• Border Gateway Protocol (BGP)

22.26
Figure 22.14 Distance vector routing tables

22.27
Figure 22.15 Initialization of tables in distance vector routing

22.28
Note

In distance vector routing, each node


shares its routing table with its
immediate neighbors periodically and
when there is a change.

22.29
Figure 22.16 Updating in distance vector routing

22.30
Figure 22.17 Two-node instability

22.31
Figure 22.18 Three-node instability

22.32
Figure 22.19 Example of a domain using RIP

22.33
Figure 22.20 Concept of link state routing

22.34
Figure 22.21 Link state knowledge

22.35
Figure 22.22 Dijkstra algorithm

22.36
Figure 22.23 Example of formation of shortest path tree

22.37
Table 22.2 Routing table for node A

22.38
Figure 22.24 Areas in an autonomous system

22.39
Figure 22.25 Types of links

22.40
Figure 22.26 Point-to-point link

22.41
Figure 22.27 Transient link

22.42
Figure 22.28 Stub link

22.43
Figure 22.29 Example of an AS and its graphical representation in OSPF

22.44
Figure 22.30 Initial routing tables in path vector routing

22.45
Figure 22.31 Stabilized tables for three autonomous systems

22.46
Figure 22.32 Internal and external BGP sessions

22.47

You might also like