0% found this document useful (0 votes)
21 views

Unit-4 1 Network Layer

Uploaded by

payuuu567
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
21 views

Unit-4 1 Network Layer

Uploaded by

payuuu567
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 101

Unit-4

The Network Layer

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Outline of Unit
• Design issues
• Routing algorithms
• Optimality principle
• Shortest path routing
• Flooding
• Distance vector routing
• Link state routing
• Congestion control algorithms
• Principles
• Prevention policies
• Congestion control in virtual circuit subnets
• Congestion control in datagram subnets
• Load shedding
• Jitter control
• Quality of service
• Requirements
• Techniques for achieving good quality of service
• Internetworking
• Tunnelling
• The network layer in the internet
• The IP protocol
• IP addresses
• Internet control protocol
• OSPF
• BGP

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Various functions of network layer
Addressing: Maintains the address at the frame header of
both source and destination and performs addressing to detect
various devices in network.
Packeting: This is performed by Internet Protocol. The
network layer converts the packets from its upper layer.
Routing: It is the most important functionality. The network
layer chooses the most relevant and best path for the data
transmission from source to destination.
Inter-networking: It works to deliver a logical connection
across multiple devices.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Network Layer Design Issues

1. Store-and-forward packet switching


2. Services provided to transport layer
3. Implementation of connectionless service
4. Implementation of connection-oriented service
5. Comparison of virtual-circuit and datagram
networks

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
1. Store-and-Forward Packet Switching

ISP’s equipment

The environment of the network layer protocols.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
2. Services Provided to the Transport Layer

1. Offering services must not depend on router


technology.
2. Transport layer need to be procted from
number, type, topology of routers.
3. Network addresses available to transport
layer use uniform numbering plan
– even across LANs and WANs

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
3. Implementation of Connectionless Service
ISP’s equipment

A’s table (initially) A’s table (later) C’s Table E’s Table

Routing within a datagram network


Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
4. Implementation of Connection-Oriented Service

ISP’s equipment

A’s table C’s Table E’s Table

Routing within a virtual-circuit network


Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
5. Comparison of Virtual-Circuit and Datagram Networks

Comparison of datagram and virtual-circuit networks


Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Routing Algorithms

• The main function of the network layer is


routing packets from the source machine to
the destination machine.

• Routing algorithm is that part of the


network layer software, and responsible for
deciding which output line an incoming
packet should be transmitted on.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Routing Algorithms

In this process, a routing table is created which


contains information regarding routes that data
packets follow. Various routing algorithms are
used for the purpose of deciding which route an
incoming data packet needs to be transmitted on
to reach the destination efficiently.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Routing Algorithms(2)

• Router has two process inside it

a. Forwarding/Routing
b. Filling and updating the routing table

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Routing Algorithms
Certain property are desirable in
Routing algorithm:

1. Correctness
2. Simplicity
3. Robustness
4. Stability
5. Fairness
6. Efficiency
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Fairness vs. Efficiency

Network with a conflict between fairness and efficiency.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Routing Algorithms
• Optimality principle
• Shortest path algorithm
• Flooding
• Distance vector routing
• Link state routing
• Routing in ad hoc networks
• Broadcast routing
• Multicast routing
• Anycast routing
• Routing for mobile hosts
• Routing in ad hoc networks
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The Optimality Principle(1)

• The Optimality Principal: This simple states that if router J


is on the optimal path form router I to router k, then the
optimal path from J to K also falls along this same path.

• Sink tree: Set of optimal routes from all sources to a given


destination form a tree rooted at the destination; not
necessarily unique; no loops

• Benchmark against which other routing algorithms can be


measured

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The Optimality Principle(2)

(a) A network. (b) A sink tree for router B.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Shortest Path Algorithm (1)
• The shortest path algorithm just finds the least expensive
path through the network, based on the cost function.

•To choose a route between a given pair of routers, the


algorithm just finds the shortest path between them on the
graph.

• Dijkstra's algorithm use to compute the shortest path through


a graph

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Shortest Path Algorithm (2)

The first five steps used in computing the shortest path from A
to D. The arrows indicate the working node
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Flooding(1)
• Flooding is the static routing algorithm. In this algorithm,
every incoming packet is sent on all outgoing lines except the
line on which it has arrived.
•Disadvantage: Duplicate Packet
•Application: Millatry, Distributed Database

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Flooding(2)
• Several measures are takes to stop the duplication of packets. These
are:
1. One solution is to include a hop counter in the header of each packet.
This counter is decremented at each hop along the path. When this
counter reaches zero the packet is discarded.

2. Another technique is to keep the track of the packed that have been
flooded, to avoid sending them a second time. For this, the source
router put a sequence number in each packet it receives from its hosts.
Each router then needs a list per source router telling which sequence
numbers originating at that source have already been seen. If an
incoming packet is on the list, it is not flooded.

3. Another solution is to use selective flooding. In selective flooding the


routers do not send every incoming packet out on every output line.
Instead packet is sent only on those lines which are approximately
going in the right direction.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Flooding(3)
Some important use:
1. Ensures that a packet is delivered to every node

2. Flooding is tremendously robust. Even if large number of


routers are blown to bits, flooding will find a path if one
exists.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Distance Vector Routing(1)
• Computer networks generally use dynamic routing
algorithms that are more complex than flooding, but more
efficient because they find shortest paths for the current
topology.

• Two dynamic algorithms in particular, distance vector


routing and link state routing, are the most popular.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Distance Vector Routing(1)
• In this routing scheme, each router periodically shares its
knowledge about the entire network with its neighbors.

• Each router has a table with information about network.


These tables are updated by exchanging information with
the immediate neighbors.

• It is also known as Belman-Ford or Ford-Fulkerson


Algorithm.

• It is used in the original ARPANET, and in the Internet as


RIP.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Distance Vector Routing(2)
• Neighboring nodes in the subnet exchange their tables
periodically to update each other on the state of the subnet
(which makes this a dynamic algorithm).

• If a neighbor claims to have a path to a node which is shorter


than your path, you start using that neighbor as the route to
that node.

• Distance might the measured as the number of hopes or


using another matric.

• If the matric is propagation delay, the router can measure it


directly with special ECHO packet.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Distance Vector Routing

(a) A network.
(b) Input from A, I, H, K, and the new routing table for J.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The Count-to-Infinity Problem

The count-to-infinity problem

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Solution of Count-to-Infinity Problem

1. Route Poisoning : Send Negative msg with infinity


2. Split Horizon : direct connected node not accept the route
from other node
3. Trigger Update : When node/link down it trigger msg to all
4. Hold Down Timer : timer on till down node/link is up\

• In real network combination of the above method is used


to prevent loop.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Link State Routing(1)
• The primary problem with distance vector is the
algorithm often took to long to converge after the
network topology changed (due to counter infinity
problem).

• The idea behind link state routing is fairly simple


and can be stated as five parts.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Link State Routing(2)
Each router must do the following things to make it
work:

1. Discover neighbors, learn network addresses.


2. Set distance/cost metric to each neighbor.
3. Construct packet telling all learned.
4. Send packet to, receive packets from other routers.
5. Compute shortest path to every other router.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
1. Learning about the Neighbors (1)

Nine routers and a broadcast LAN.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
1. Learning about the Neighbors (2)

A graph model of previous slide.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
2. Setting link cost
• Find the distance from source to linked node
• Setup cost using bandwidth of link
• Send Hello packet and find the delay

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
3. Building Link State Packets

(a) A network. (b) The link state packets for this network.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
3. Building Link State Packets
Sequence number: each packet contains a sequence number,
this keep tracks how many times packet has been sent.

Age: shows the life of packet in network, after passing by one


hope it’s decremented by one.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
4. Distributing the Link State Packets
• The fundamental idea is to use flooding to distribute the link
state packets to all routers.

• To keep the flood check, each packet contain sequence


number that is incremented for each new packet sent.

• Router keep track of all the (source, sequence) pairs of


they see.

Problem:
• If the sequence number wrap out.
• If a router ever crashes
• Sequence number ever corrupted
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Conclusion of link state routing
• Compared to distance vector routing, link state routing
require more memory and computation.
• Link state routing is widely used in actual network.

• Example of Link State routing is:


• IS-IS (intermediate system-intermediate system)
• OSPF(open shortest path first)

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Congestion Control
• Too many packets present in (a part of) the network causes
packet delay and loss that degrades performance. This
situation is called congestion.

• Congestion can be brought on by several factors:


1. If all of a sudden, streams of packets begin arriving
2. Slow processors can also cause congestion

• We would like to design networks that avoid congestion where


possible and do not suffer from congestion collapse if they do
become congested.

• Unfortunately, congestion cannot wholly be avoided.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Congestion Control

When too much traffic is offered, congestion sets in and


performance degrades sharply.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Congestion Control
• Difference between congestion control and flow control

• Congestion control has to do with making sure the subnet is able to


carry the offered traffic.

• Flow control, in contrast, relates to the point-to-point traffic between a


given sender and a given receiver.

• Example : 1 - fiber optic network with a capacity of 1000 gigabits/sec


on which a supercomputer is trying to transfer a file to a personal
computer at 1 Gbps. – No congestion but flow control is needed.

• Example : 2 - consider a store-and-forward network with 1-Mbps lines


and 1000 large computers, half of which are trying to transfer files at
100 kbps to the other half. – No flow control but congestion control
needed as total offered traffic exceeds what the network can handle.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
General Principles of Congestion Control
• Many problems in complex systems, such as computer networks,
can be viewed from a control theory point of view.

• This approach leads to dividing all solutions into two groups: open
loop and closed loop.

• Open loop solutions attempt to solve the problem by good design,


in essence, to make sure it does not occur in the first place.

• Accept new traffic.


• Deciding when to discard packets and which ones, and
• Making scheduling decisions at various points in the network.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
General Principles of Congestion Control
• Closed loop solutions are based on the concept of a feedback loop.

• This approach has three parts when applied to congestion control:


1. Monitor the system to detect when and where congestion occurs.
2. Pass this information to places where action can be taken.
3. Adjust system operation to correct the problem.

• The closed loop algorithms are also divided into two subcategories:
Explicit feedback versus implicit feedback.

1. In explicit feedback algorithms, packets are sent back from the point of
congestion to warn the source.
2. In implicit algorithms, the source deduces the existence of congestion
by making local observations, such as the time needed for
acknowledgements to come back.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Congestion Prevention Policies (Open Loop)

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Congestion Prevention Policies (Open Loop)

• Network Provisioning :

• Sometimes resources can be added dynamically when there is


serious congestion.

• Turning on sparse router or enabling lines that are only for backups

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Congestion Control in Virtual-Circuit Subnets
• Admission Control:

•One technique that is widely used in virtual-circuit networks to


keep congestion at bay is admission control.

• The idea is simple: do not set up a new virtual circuit unless


the network can carry the added traffic without becoming
congested.

• By analogy, in the telephone system, when a switch gets


overloaded it practices admission control by not giving dial
tones.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Congestion Control in Virtual-Circuit Subnets
• Admission Control

• Traffic is typically bursty—the average rate is only half the


story.

• Example : Browsing the Web is more difficult to handle than


a streaming movie with the same long-term throughput

• What about when new virtual circuit will lead to congestion?

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Congestion Control in Virtual-Circuit Subnets

(a) A congested network. (b) The portion of the network that is


not congested. A virtual circuit from A to B is also shown.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Congestion Control in Datagram Subnets
• Each router can easily monitor the utilization of its output
lines and other resources.

• Different way to handle congestion :

1. The Warning Bit :

• The old DECNET architecture signaled the warning state by


setting a special bit in the packet’s header.

• As long as the warning bits continued to flow in, the source


continued to decrease its transmission rate.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
2. Choke Packets:

• Implicit congestion notification

• The most direct way to notify a sender of congestion is to


tell it directly.

• In this approach, the router selects a congested packet and


sends a choke packet back to the source host, giving it the
destination found in the packet.

• it is likely that multiple choke packets will be sent to a given


host and destination.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
2. Choke Packets:

• Explicit congestion notification:


• When the network delivers the packet, the destination can note that
there is congestion and inform the sender when It sends a reply packet.

• The sender can then throttle its transmissions as before.

• Two bits in the IP packet header are used to record whether the packet
experienced congestion.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
A choke packet that affects only the source..
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
3. Hop-by-hop backpressure:

• At high speeds or over long distances, many new packets


may be transmitted after congestion has been signaled
because of the delay before the signal takes effect.

• Consider, for example, a host in San Francisco (router A in


Fig. 5-26) that is sending traffic to a host in New York
(router D in Fig. 5-26) at the OC-3 speed of 155 Mbps.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
A choke packet that affects each hop it passes through.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Load Shedding
• When none of the above methods make the congestion
disappear, routers can bring out the heavy artillery: load
shedding.
• Load shedding is a fancy way of saying that when routers
are being inundated by packets that they cannot handle,
they just throw them away.
• More intelligent load shedding requires cooperation from
the senders
• The key question for a router drowning in packets is which
packets to drop.
• The former policy (old is better than new) is often called wine
policy and the latter (new is better than old) is often called milk
policy because most people would rather drink new milk and old
wine than the alternative.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Load Shedding
• Random Early Detection:
• By having routers drop packets early, before the situation
has become hopeless, there is time for the source to take
action before it is too late. A popular algorithm for doing this
is called RED (Random Early Detection).
• To determine when to start discarding, routers maintain a
running average of their queue lengths. When the average
queue length on some link exceeds a threshold, the link is
said to be congested and a small fraction of the packets are
dropped at random.
• RED routers improve performance compared to routers that
drop packets only when their buffers are full, though they
may require tuning to work well.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
5. Load Shedding (2)

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Jitter Control
• The variation (i.e., standard deviation) in the packet arrival
times is called jitter.

• A. High Jitter
• B. Low Jitter

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Jitter Control
• When a packet arrives at a router, the router checks to see
how much the packet is behind or ahead of its schedule.

• This information is stored in the packet and updated at


each hop.

• If the packet is ahead of schedule, it is held just long


enough to get it back on schedule.

• If it is behind schedule, the router tries to get it out the door


quickly.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Quality of Service
• An easy solution to provide good quality of service is to build a
network with enough capacity for whatever traffic will be thrown at it.
The name for this solution is overprovisioning.

• With quality of service mechanisms, the network can honor the


performance guarantees that it makes even when traffic spikes, at
the cost of turning down some requests.

• Four issues must be addressed to ensure quality of service:


1. What applications need from the network.
2. How to regulate the traffic that enters the network.
3. How to reserve resources at routers to guarantee performance.
4. Whether the network can safely accept more traffic.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Application requirements
• A stream of packets from a source to a destination is called a flow.
• In a connection-oriented network, all the packets belonging to a flow
follow the same route;
• In a connectionless network, they may follow different routes.
• The needs of each flow can be characterized by four primary
parameters:
• reliability,
• delay,
• jitter, and
• bandwidth.

• Together these determine the QoS (Quality of Service) the flow


requires.

• Several common applications and the stringency of their requirements


are listed in next diagram.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Application requirements

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Application requirements
• The first four applications have stringent requirements on reliability. No
bits may be delivered incorrectly.
• File transfer applications, including e-mail and video, are not delay
sensitive. If all packets are delayed uniformly by a few seconds, no
harm is done.
• Interactive applications, such as Web surfing and remote login, are
more delay sensitive.
• Real-time applications, such as telephony and videoconferencing have
strict delay requirements.
• The first three applications are not sensitive to the packets arriving with
irregular time intervals between them.
• Video and especially audio are extremely sensitive to jitter. If a user is
watching a video over the network and the frames are all delayed by
exactly 2.000 seconds, no harm is done. But if the transmission time
varies randomly between 1 and 2 seconds, the result will be terrible.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Techniques for Achieving Good Quality of Service
• Now that we know something about QoS requirements, how do we
achieve them?
• Well, to start with, there is no magic bullet.
• No single technique provides efficient, dependable QoS in an optimum
way.
• Instead, a variety of techniques have been developed, with practical
solutions often combining multiple techniques.
• We will now examine some of the techniques system designers use to
achieve QoS.

1. Overprovisioning
2. Buffering
3. Traffic Shaping
4. The Leaky Bucket Algorithm
5. The Token Bucket Algorithm
6. Admission Control

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
1. Overprovisioning
• An easy solution is to provide so much router capacity, buffer space, and
bandwidth that the packets just fly through easily.

• The trouble with this solution is that it is expensive.

• As time goes on and designers have a better idea of how much is enough,
this technique may even become practical.

• To some extent, the telephone system is overprovisioned.

• It is rare to pick up a telephone and not get a dial tone instantly.

• There is simply so much capacity available there that demand can always
be met.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
2. Buffering
• Flows can be buffered on the receiving side before being delivered.
• Buffering them does not affect the reliability or bandwidth, and increases
the delay, but it smooths out the jitter.
• For audio and video on demand, jitter is the main problem, so this
technique helps a lot.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
3. Traffic Shaping
• Traffic shaping is a technique for regulating the
average rate and burstiness of a flow of data that
enters the network.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Traffic Shaping (1)

(a) Shaping packets. (b) A leaky bucket. (c) A token bucket

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
4. Leaky Bucket

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
4. Token Bucket

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
5. Token Bucket

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
6. Admission Control
• The goal in taking load into account when computing routers is
to shift traffic away from hotspot that will be the first place in the
network to experience congestion.

• Link weight : link bandwidth, propagation delay, average


queuing delay

• Techniques can contribute to successful solution:

• Multipath routing : (multiple path from source to destination),


ex. Traffic can be spread across both of the link.

• Shift Traffic across routes slowly

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
6. Admission Control

A network in which the East and West parts


are connected by two links.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Internetworking

• How networks differ


• How networks can be connected
• Concatenated virtual circuit
• Connectionless internetworking
• Tunneling
• Internetwork routing
• Packet fragmentation

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
How Networks Differ

Some of the many ways networks can differ

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
How Networks Can Be Connected

(a) A packet crossing different networks.


(b) Network and link layer protocol processing.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Tunneling (1)

Tunneling a packet from Paris to London.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The Network Layer Principles (1)

1. Make sure it works


2. Keep it simple
3. Make clear choices
4. Exploit modularity
5. Expect heterogeneity
...

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The Network Layer Principles (2)

...
6. Avoid static options and parameters
7. Look for good design (not perfect)
8. Strict sending, tolerant receiving
9. Think about scalability
10. Consider performance and cost

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The Network Layer in the Internet (1)

• The IP Version 4 Protocol


• IP Addresses
• IP Version 6
• Internet Control Protocols
• Label Switching and MPLS
• OSPF—An Interior Gateway Routing Protocol
• BGP—The Exterior Gateway Routing Protocol
• Internet Multicasting
• Mobile IP
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The Network Layer in the Internet (2)

The Internet is an interconnected collection of many networks.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The IP Version 4 Protocol (1)

The IPv4 (Internet Protocol) header.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The IP Version 4 Protocol (1)
• Version : The Version field keeps track of which version of
the protocol the datagram belongs to. Version 4 dominates
the Internet today, and that is where we have started our
discussion.

• IHL (Internet Header Length) : Since the header length is


not constant, a field in the header, IHL, is provided to tell
how long the header is, in 32-bit words.

• DSCP (Differentiated Services Code Point) : The Type of


service field provided 3 bits to signal priority and 3 bits to
signal whether a host cared more about delay, throughput,
or reliability. However, no one really knew what to do with
these bits at routers, so they were left unused for many
years.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The IP Version 4 Protocol (1)
• Total Length: The Total length includes everything in the
datagram—both header and data. The maximum length is
65,535 bytes. At present, this upper limit is tolerable, but
with future networks, larger datagram's may be needed.

• Identification: The Identification field is needed to allow the


destination host to determine which packet a newly arrived
fragment belongs to. All the fragments of a packet contain
the same Identification value.

• DF : DF stands for Don’t Fragment. It is an order to the


routers not to fragment the packet. By marking the
datagram with the DF bit, the sender knows it will either
arrive in one piece, or an error message will be returned to
the sender.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The IP Version 4 Protocol (1)
• MF : MF stands for More Fragments. All fragments except
the last one have this bit set. It is needed to know when all
fragments of a datagram have arrived.

• Fragment Offset : This offset tells the exact position of the


fragment in the original IP Packet.

• Time to live : The TtL (Time to live) field is a counter used


to limit packet lifetimes.

• Protocol : Tells the Network layer at the destination host, to


which Protocol this packet belongs to, i.e. the next level
Protocol. For example protocol number of ICMP is 1, TCP
is 6 and UDP is 17.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
The IP Version 4 Protocol (1)
• Header Checksum: This field is used to keep checksum
value of entire header which is then used to check if the
packet is received error-free.

• Source Address: 32-bit address of the Sender (or source)


of the packet.

• Destination Address: 32-bit address of the Receiver (or


destination) of the packet.

• Options: This is optional field, which is used if the value of


IHL is greater than 5. These options may contain values for
options such as Security, Record Route, Time Stamp, etc.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
IP Addresses (6)

IP address formats

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
IP Addresses (7)

Special IP addresses

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Private IP vs Public IP

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Private IP vs Public IP

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Static IP vs Dynamic IP

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Static IP vs Dynamic IP

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
NAT (Network Address Translation)

Placement and operation of a NAT box.

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
IP Version 6 Goals
• Support billions of hosts
• Reduce routing table size
• Simplify protocol
• Better security
• Attention to type of service
• Aid multicasting
• Roaming host without changing address
• Allow future protocol evolution
• Permit coexistence of old, new protocols. . .
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
IP Version 6 (1)

The IPv6 fixed header (required).

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
DHCP Client Initialization

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Routing Algorithm Classification

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Interior Gateway Protocol (IGP) and Exterior Gateway Protocol (EGP)

Autonomous System

Autonomous System : An autonomous system (AS) is a very large network or


group of networks with a single routing policy.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Interior Gateway Protocol (IGP) / Interior Border Gateway Protocol

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
Exterior Gateway Protocol (EGP) Exterior Border Gateway Protocol

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011
End

Unit 4

Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011

You might also like