Title: CS412 Introduction to Computer Networking
1CS412 Introduction to Computer Networking
Telecommunication
2Topics
- Design Issues
- Routing Algorithms
- Congestion Control
- Internetworking
3Position of network layer
4Network Layer Design Issues
- Store-and-Forward Packet Switching
- Services Provided to the Transport Layer
- Implementation of Connectionless Service
- Implementation of Connection-Oriented Service
- Comparison of Virtual-Circuit and Datagram
Subnets
5Store-and-Forward Packet Switching
- The environment of the network layer protocols.
6Figure 19.3 Network layer in an internetwork
7Figure 19.4 Network layer at the source
8Figure 19.5 Network layer at a router
9Figure 19.6 Network layer at the destination
10Services Provided to Transport Layer
- Designing goals
- Independent of subnet technology
- Transport layer shielded from number, type, and
topology of subnets - Uniform network address numbering
- Two Types of Services
- Connectionless
- Connection-oriented
11Implementation of Connectionless Service
- Routing within a diagram subnet.
12Implementation of Connection-Oriented Service
- Routing within a virtual-circuit subnet.
13Comparison of Virtual-Circuit and Datagram Subnets
5-4
14Routing Algorithms
- Network layer software
- Deciding which output line an incoming packet
should be transmitted to - Datagram made for each packet
- VC made for new VC setup
15Routing Algorithms
- Desirable Properties
- Correctness
- Simplicity
- Robustness
- Stability
- Fairness
- Optimality
16Routing Algorithms - Optimality
- What to optimize?
- Minimizing mean packet delay
- Maximizing total network throughput
- Problem
- The above two are in conflicts
- Compromise
- Minimizing number of hops a packet must take from
source to destination
17Classes of Routing Algorithm
- Two major classes
- Non-adaptive
- Adaptive
18Two Major Classes of Routing Algorithm
- Adaptive
- Algorithms differ in
- where to get information, e.g.,
- Locally
- From adjacent routers
- From all routers
- when to change routes, e.g.,
- Every T sec
- When the load changes
- When the topology changes
- what metric used for optimization, e.g.,
- Distance
- Number of hops
- Estimated transit time
19Routing Algorithms to be Studied
- Static (i.e., nonadaptive) routing
- Shortest path routing
- Flooding
- Dynamic (i.e., adaptive) routing
- Distance vector routing
- Link state routing
20Optimality Principle
- If router J is on the optimal path from router I
to router K, then the optimal path from J to K
also falls along the same route. - Proof?
K
J
I
21Sink Tree
- Direct consequence of optimality principle
- Subnet graph
- Node router
- Arc link
- The set of optimal routes from all sources to a
given destination form a tree rooted at the
destination - Might not be unique
- Goal of routing algorithms
- Discover and use the sink tree for all routers
22Sink Tree
- Example
- Distance metric number of hops
Subnet
Sink tree
23Shortest Path Routing
- Given a pair of routers, find the shortest path
between them - Subnet graph
- Node router
- Arc link
- Labels of arcs
- Function of factors
- Weighting function changed for different criteria
24Dijkstra's Algorithm
- Each node labeled with
- (distance from source, best known path)
- Initially
- distance infinity
- best known path unknown
- Label might change to reflect better paths
- Node is either tentative or permanent
- Initially tentative
- As a path from source to that node discovered,
label becomes permanent and never gets changed
25(No Transcript)
26Dijkstra's Algorithm
- How do we find the path?
- The algorithm given in the book works from
destination to source - Why?
27Flooding
- Every incoming packet is sent out on every
outgoing line except for the input line - Problem
- Large number of packets are generated
- Solutions
- Hop counter
- Avoiding duplicates
- Selective flooding
28Flooding - Conclusion
- Optimal
- Shortest path is always chosen
- ? No other algorithm can produce a shorter delay
- Robust
- Not practical in most applications
- Useful in some applications
- Military application robustness
- Distributed database applications
- Concurrent update
- Wireless networks
- Metric of other routing algorithms
29Distance Vector Routing
- Table in each router
- Giving
- Best known distance to each destination
- Which line to use to get there
- Indexed by each router
- Each entry contains two parts
- Preferred outgoing line to use for that
destination - Estimate of "distance" to go there
- Best known distance to each destination
- Updated by exchanging information with neighbors
30Distance Vector Routing
- Router
- Knows "distance" to each neighbor
- Sends list to each neighbor every T msec
- ? Receives lists from neighbors every T msec
- If neighbor X knows
- Distance from X to I is XI, and
- Distance from the router to X is m
- then delay from router to I via X is (XI m)
- Performs calculation for each neighbor to find
the best - Old table not used in calculation
31(No Transcript)
32Distance Vector Routing
- Count-to-Infinity Problem
- Good news spread fast, bad news leisurely
- Infinity has to be defined
33Link State Routing
- A router
- Discovers its neighbors and learn their network
addresses - HELLO - Measures the delay or cost to each neighbor -
ECHO - Constructs a packet telling all it has just
learned link state packet - Sends this packet to all other routers flooding
w/ duplicate avoidance - Computes the shortest path to every other router
Dijkstras algorithm
34Link State Routing
- In effect
- Complete topology and all delays are
experimentally measured and distributed to every
router - Dijkstra's algorithm is applied to find the
shortest path
35Link State Packets
36Hierarchical Routing
- Problem
- Network size grows ? Routing tables grow
- Solution
- Hierarchical routing
- Idea
- Routers are divided into "regions"
- Router knows detail about routing within its
region - Router knows nothing about internal structure of
other region
37Path length from 1A to 5C?
38Congestion Control
- Congestion
- Too many packets present in the subnet
- Effects
- Performance degraded
- Packet lost
39Congestion and Network Performance
(Could be achieved by congestion control)
(Without congestion control)
40Causes of Congestion
- Causes
- Too many packets need an output line
- ? queuing
- Problem not enough memory ? packets dropped
- Solution(?) adding more memory
- New problem timeout and retransmit ? worse
- Slow processors
- Low bandwidth lines
- Congestion tends to feed upon itself and become
worse
41Congestion Control v.s. Flow Control
- Flow control relates to traffic between two
machines, while congestion control is more global - Examples
- No congestion, flow control needed
- Flow control not needed, congestion
- Confusion
- Congestion control might send back "slow down"
messages - ? Not an acknowledgement
42Congestion Control - General Principles
- Two groups
- Open loop
- Closed loop feedback loop
- Explicit feedback
- Implicit feedback
- Source deduces existence of congestion by making
local observation - E.g., time needed for acknowledgement to come back
43Congestion Control - General Principles
- Closed Loop - Approach
- Monitor the system to detect when and where
congestion occurs - Pass this information to places where actions can
be taken - Adjust system operation to correct the problem
44Congestion Control
- Congestion (Load gt Resources)
- Solutions
- Increase resources
- Decrease load
45Congestion Prevention Policies
- Policies that affect congestion.
5-26
46Congestion Control in VC Subnets
- Admission control
- Alternative routes
- Resource reservation
- Based on negotiated agreement
47Congestion Control in VC Subnets
48Choke Packets
- Used in both VC and datagram subnets
- Approach
- Each router monitors output line utilization
- Threshold for "warning state"
- A receiving router
- Checks packet to see if output line in warning
state - If yes then
- send a "choke packet" back to source host
- original packet tagged and forwarded
49Choke Packet
- Source, upon receiving a choke packet
- Reduces traffic by a percentage after receiving
choke packet - Choke packet referred to same destination is
ignored for a fixed time interval - After time interval expired, listens
- If choke packet received then
- goto the step of reducing traffic
- else
- increase traffic
50Choke Packet
- Typically
- First choke packet causes data rate reduced to
50, then 25, - Traffic is increased in smaller increments
- Why?
51Hop-by-Hop Choke Packets
- Problem in high speed and long distance ? slow
reaction - Solution
- Hop-by-hop choke packets
- Buffers needed in routers
- Effects
- Quick relief at the price of more buffers
52Hop-by-Hop Choke Packets
- (a) A choke packet that affects only the source.
- (b) A choke packet that affects each hop it
passes through.
53Load Shedding
- Discard whatever cannot be handled
- Which packets to drop?
- Application-dependent
- Priorities
54Load Shedding
- Strategies
- Wine or milk
- Priority
- Priority classes
- Coupled with traffic shaping token bucket
- ? Packet without token sent with lowest priority
- Allowing VC set up with exceeding specification
- ? Contingent on low priority
- Header field needed (ATM 1bit)
- Discard as early as possible!
55Jitter Control
- Jitter variation in packet arrival time
- Necessary for audio/video transmission
- Control
- Delay jitter is bounded by computing expected
transit time for each hop along path - Packet is checked for behind/ahead schedule
- Behind sent out ASAP
- Ahead held for a while
- Usually buffering is used to eliminate jitters
56Internetworking
- A collection of interconnected networks.
57How Networks Differ
58How Networks Can Be Connected
59Concatenated Virtual Circuits
- A sequence of VCs is set up from source through
one or more gateways to destination - Each gateway maintains tables of information of
VCs - Best when all networks have roughly the same
properties
60Concatenated Virtual Circuits
61Connectionless Internetworking
- Packets are not required to follow same sequence
of connections - Routing per packet
- ? Possibly higher bandwidth than VC
- Packets might arrive out of order
- Problems
- Format
- Addressing
62Connectionless Internetworking
63Tunneling
- Encapsulating packets of a protocol in the
payload of packets of another protocol - Useful in
- Internetworking
- VPN
- IPv4 to IPv6 transition
-
64Tunneling
65Internetwork Routing
- AS (Autonomous System)
- Each network in internetwork independent of
others - Two-Level Routing
- Interior gateway protocol
- Exterior gateway protocol
- Differences between interior and exterior
routings - International boundaries
- Cost
- Quality of service
66Fragmentation
- Why maximal packet size
- Hardware
- OS
- Protocols
- Standards
- Retransmission reduction
- Prevention of one packet occupying channel too
long
67Fragmentation
- Maximum packet size different in different
protocol - Examples ATM 48 bytes, IP 65,515 bytes
- Problem
- Large size packets want to go through network of
smaller packet size - Solution Fragmentation
- Allowing gateways to break packets into
fragments, each as a separate internet packet - Problem Easy to break but difficult to put back
together
68Fragmentation Strategies
- Transparent fragmentation
- Nontransparent fragmentation
Transparent fragmentation
G5
Nontransparent fragmentation
69Transparent Fragmentation
- Properties
- Fragmentation transparent to subsequent networks
- Same exit gateway in each network
- Procedure
- Fragmentation
- Each fragment is addressed to same exit gateway
- Fragments are combined at exit gateway
70Transparent Fragmentation
- Simple
- Problems
- Combination
- Performance
- Overhead on repeated assembling
71Nontransparent Fragmentation
- Properties
- Combination done at destination host
- One or more exit gateway(s)
- Procedure
- Fragmentation
- Each fragment is addressed to exit gateway(s)
- Fragments are combined at destination host
- Higher performance in datagram model
- Problems
- Every host must be able to reassemble
- Overhead in packet header
72Nontransparent Fragmentation
- Numbering
- Required for assembly
- Assembly approach
- Elementary fragment size defined
- Fragments of a packet
- maximum packet size of another network except
for the last one - Header fields
- Packet number
- Number of first elementary fragment
- End-of-packet bit
73(No Transcript)