Title: Internetwork Routing
1Internetwork Routing Consider 5 networks
connected by 6 multiprotocol routers.
Once a graph of the internetwork is created, the
distance vectors can be determined.
2Internetwork Routing
- Within each network an interior gateway protocol
is used. Between these networks, an exterior
gateway protocol is used. - Gateway is an older term for router.
3Internetwork Routing
- A typical internet packet starts on a LAN
addressed to the local multiprotocol router (in
the MAC layer header). Then the network layer
decides which multiprotocol router to forward the
packet, using its own routing tables. - If that router can be reached using the packets
original network protocol, it is immediately
forwarded there. - Otherwise, the packet is tunneled to its
destination. - If a packet is too large for a particular
gateway, it is chopped into smaller fragments. It
is reattached after it travels through that
gateway.
4Tunneling Although many different types of
networks and protocols can be found on an
internetwork, there is a common special case
where the source and destination are on similar
networks, but there is a different network in
between.
5Tunneling
- The sender constructs an IP packet to the
destination, containing the destinations
address. - This packet is inserted into an Ethernet frame
addressed to a multiprotocol router. - The router removes the IP packet and inserts it
into the payload field for a WAN network layer
packet. - The payload address field is the multiprotocol
router closest to the destination. This router
removed the IP packet from the payload, and then
sends it to the destination. - The WAN acts like a tunnel between points.
6- Internet Control Protocols
- The operation of the internet is mostly
controlled by routers (no surprise). There are 5
major protocols - ICMP
- ARP
- RARP
- OSPF
- BGP
7Internet Control Message Protocol (ICMP) When an
unexpected event occurs at a router, the event is
reported by the ICMP. ICMP is also used to test
the internet. Some of these messages are shown
below.
8Internet Control Message Protocol (ICMP)
- Destination Unreachable - message occurs when the
subnet or router cannot locate a destination, or
when a packet set for DF cannot be delivered (a
small packet network blocks the path). - Time Exceeded message - means that the Time To
Live field has reached zero. - Parameter Problem - indicates an illegal value in
the header field. - Redirect - tells a sending host that a packet is
being incorrectly routed.
9- Address Resolution Protocol (ARP)
- Maintaining router tables is a considerable
chore. When an address is encountered for a
destination that is unknown to a router, the
router can broadcast a query to all routers about
that address. This is performed using ARP. - Reverse Address Resolution Protocol (RARP)
- This allows a newly-booted machine to determine
its corresponding IP address. Sometimes an
associated protocol, BOOTP is also used.
10- Interior Gateway Routing Protocol (OSPF)
- This protocol handles routing inside (interior) a
local network (gateway). The most current
protocol for this is Open Shortest Path First
(OSPF). OSPF supports 3 kinds of networks
connections - Point-to-point lines between exactly 2 routers
- Multi-access networks with broadcasting (most
LANs) - Multi-access networks without broadcasting (most
packet-switched WANs)
11Interior Gateway Routing Protocol (OSPF)
Within each local area, every router has the same
link state database and also uses the same
shortest path algorithm.
12Interior Gateway Routing Protocol (OSPF)
- OSPF categorizes routers into 4 classes
- Internal routers wholly inside one area
- Area border routers that connect 2 or more areas.
- Backbone routers
- AS boundary routers talk to routers in other
ASes.
13Interior Gateway Routing Protocol (OSPF)
- OSPF exchanges information with adjacent routers.
One router is chosen to be the designated
router. It is then considered to be adjacent to
all other routers on the LAN, and exchanges
information with them. - During normal operation, each router periodically
floods adjacent routers with LINK STATE UPDATE
messages. These flooded messages are acknowledged
by all adjacent routers.
- By analyzing the responses, a router can select
the best adjacent router to send data to.
14- Exterior Gateway Routing Protocol (BGP)
- Between autonomous systems (other networks), a
different protocol, BGP, is used. To a BGP
router, the world consists entirely of other BGP
routers. They share a common network. There are 3
BGP subnetworks - Stub networks
- Multi-connected networks
- Transit networks
15Exterior Gateway Routing Protocol (BGP)
- Stub networks - are dead ends and have only one
connection to a BGP network. - Multiconnected networks - could be used for
transit traffic, but they REFUSE transit traffic. - Transit networks - such as backbones, are able
and willing to handle 3rd party packets. - BGP is primarily a distance vector protocol. It
records the line cost (time hops) to each
destination. It also keeps track of the exact
path used. Instead of telling each neighbor its
cost data, it tells each neighbor the path it
uses to each neighbor.
16Example of BGP Router-to-Router Messages
17Routing Principles Most packet transmissions
will require multiple hops across the subnet.
Routing algorithms fall into one of 2 categories
1) Nonadaptive algorithms 2) Adaptive
algorithms
18Routing Principles
Nonadaptive algorithms compute the path between 2
points in advance. All routers located within a
network are provided with this information when
the system is booted up. Adaptive algorithms
change their routing paths due to constant
testing of current topology and traffic
congestion. They obtain their information by
monitoring other nearby routers.
19Routing Principles
Distance Vector Routing Most networks use
adaptive (dynamic) routing methods. One of the
two most popular methods is distance vector
routing. In this method, each router maintains a
table (vector) giving the best-known distance to
each destination and which line to use to get
there. These tables are updated by exchanging
information with its neighbors. Each router
contains a routing table containing an entry for
every other router in the subnet.
20Routing Principles
- Each entry contains
- the preferred outgoing line to use for that
destination - an estimate of the time or distance to that
destination - The distance is not really distance. In
this case, distance means the number of hops, or
the queue length, or the delay time.
21Routing Principles
- Once every so often ( milliseconds ), each router
sends to each neighbor a list of estimated delays
to each destination. It also receives similar
lists from its neighbors. - The router then calculates the new distance to
each neighbor and update its routing table
accordingly.
22Routing Principles
In the figure shown above, a router would
calculate the distance between J to G along
several paths. It will quickly determine that the
fastest path is from J to H to G.
23Routing Principles
- Link State Routing
- The other type of dynamic routing is link state
routing. Using this method, each router will - discover its neighbors network addresses
- measure the delay to each of its neighbors
- construct a packet containing this information
- send this packet to other routers
- compute the shortest path to each router
24Routing Principles
When a router is booted, it first learns about
its neighbors by sending a special HELLO packet
on each point-to-point line. Other routers on the
line will respond by identifying themselves. The
identifiers must be globally unique.
25Routing Principles
- Measuring the line cost (delay) requires a
choice. Do you measure the delay when the line is
not busy ? Or do you measure the line when it is
heavily congested ? - The first inclination is to measure during
congestion. After all, congestion is a legitimate
factor. - Remember that the line cost information will
eventually end up in the router tables. Consider
the following subnet.
26Routing Principles
Suppose the line from C to F is heavily
congested, but the line from E to I is lightly
trafficked. If the line cost includes congestion,
then all of the routers will update their tables
to favor path E to I. Suddenly, E to I will
become congested, while C to F will become
uncongested. This problem will repeat itself over
and over again.
27Routing Principles
Once the neighbors are located and the line costs
have been calculated, the next step is for a
router to create a packet containing this
information. The packet begins with the identity
of the sender. It then adds a sequence number,
its age, a list of neighbors, and the delay to
each neighbor.
28Routing Principles
- One unanswered question is when to build these
link state packets. They could be built
periodically, or built after a major event has
occurred. - The link packets are then distributed by
flooding. If a router receives a link state
packet, it checks the sequence number. If the
sequence number is higher than the last sequence
number from the sender, the router keeps the
packet and updates its tables accordingly.
29Routing Principles
- If a router goes down or fails, when it is booted
up again its sequence number will start at zero.
When it floods its neighbors, the neighbors will
ignore it since the sequence number is lower than
the last one. - To prevent this event from happening, we must
return to the age part of a link state packet.
When a packet is accepted by a router, it is
given an age (say 10 minutes). After each minute,
the age is decremented. When the age reaches
zero, the data in the table is updated by the
next packet, regardless of the sequence number.
30Routing Principles
Hierarchical Routing As networks grow, so does
the number of routers. And so also does the size
and complexity of routing tables. Eventually, it
is no longer practical for every router to have
an entry for every other router. Instead, a
router hierarchy can be developed. With
hierarchical routing, the routers are divided
into regions. Each router knows how to route
packets to every other router in its region. But
it knows nothing outside of its region.
31Routing Principles
Two-Level Hierarchy with Five Regions
32CONGESTION CONTROL
When too many packets are present on a part of
the subnet, congestion can occur. This severely
limits the amount of packets delivered.
33CONGESTION CONTROL
- If a stream of packets suddenly arrives on
several input lines, and all need the same output
line, a queue will develop. - If there is insufficient memory, packets will be
lost. - If more memory is added, the problem becomes
worse. The size of the queue increases, but
eventually transmitter machines time out without
receiving an acknowledgement. - The transmitters response to time outs is to
send the packet again. The router memory will
then become clogged with multiple copies of
packets.
34CONGESTION CONTROL
- Slow routers can also cause congestion. Queues
continue to get larger. Again we have time out
problems. - Congestion control deals with ensuring that the
subnet is able to carry the desired traffic. It
is a global issue and involves ALL hosts,
routers, and store-and-forward processes within
routers. - Flow control, however, is a data link issue. It
is concerned with point-to-point traffic between
a given sender and receiver. - Flow control requires direct feedback from the
receiver. Congestion control does not.
35CONGESTION CONTROL
- General Principles of Congestion Control
- There are 2 approaches to congestion control
- Open loop control (no feedback)
- Closed loop control (feedback)
- Open loop control consists of methods such as
deciding which packets a router accepts and which
packets a router discards. The current state of
the network is not an issue for open loop control.
36CONGESTION CONTROL
- Closed loop control uses feedback. It is
therefore necessary to - Monitor the subnet and detect when congestion
occurs. - Pass this information to places where action can
be taken. - Adjust system operation to correct the problem.
37CONGESTION CONTROL
- One method for monitoring congestion is to
calculate the percentage of all packets that are
discarded due to - lack of buffer memory space
- the average queue length
- the number of packets that timeout and are
retransmitted, - the average packet delay.
- If the capacity cannot be increased by adding new
lines, then the only alternative to correct
congestion is to decrease the load by either
denying access to some users or by degrading
service to some users.
38Policies that Affect Congestion
39CONGESTION CONTROL
- Traffic Shaping
- Congestion often occurs in large bursts of
traffic. If hosts transmitted at a uniform rate,
much congestion could be prevented. An open loop
method for congestion management is called
traffic shaping. - Traffic shaping regulates the average rate of
data transmission. - It is an agreement made when a virtual circuit is
set up.