SlideShare a Scribd company logo
1 of 45
Download to read offline
Routing Concept
Sirak Kaewjamnong
Computer Network Tech and Security
2
Agenda
• Basic concepts
• Routing components
• Classes of routing protocol
• Internet routing protocol
3
What’s Routing
Routing - path finding from one end to the
other
• Routing occurs at layer 3
• Bridging occurs at layer 2
Physical link
Data link layer
Network layer
Transport layer
Session layer
Presentation layer
Application layer
Physical link
Data link layer
Network layer
Transport layer
Session layer
Presentation layer
Application layer
Physical link
Data link layer
Network layer
Network A Network B
4
IP Routing
• IP performs:
• search for a matching host address
• search for a matching network address
• search for a default entry
• Routing done by IP router, when it searches the
routing table and decide which interface to end a
packet out.
incoming
which interface ?
5
Routing Tables
• Routing is carried out in a router by consulting
routing table.
• No unique format for routing tables, typically
table contains:
– address of a destination
– IP address of next hop router
– network interface to be used
– subnet mask for the this interface
– distance to the destination
6
Routing Component
• Three important routing elements :
– algorithm
– database
– protocol
• Algorithm : can be differentiate based on several
key characteristics
• Database : table in routers or routing table
• Protocol: the way information for routing to be
gathered and distributed
7
Routing Algorithm
Design goals
• Optimality - compute the best route
• Simplicity/low overhead - efficient with a
minimum software and utilization overhead
• Robustness/stability- perform correctly in the face
of unusual circumstances
• Rapid convergence- responds quickly when the
network changes
• Flexibility- accurate adapt to a variety of network
8
Routing Protocols
• Routing protocol : protocol to exchange of
information between routers about the current
state of the network
• Routing protocol jobs
– create routing table entries
– keep routing table up-to-date
– compute the best choice for the next hop router
9
Routing Metrics
• How do we decide that one route is better than
another?
• Solution : using a metric as a measurement to
compare routes
• Metrics may be distance, throughput, delay, error
rate, and cost.
• Today, IP supports Delay, Throughput, Reliability
and Cost (DTRC)
10
Hop Count
• A hop is defined as a passage through one router
R1 R2
R3
1 hop 1 hop
1 hop 1 hop
2 hops
11
Routing Algorithm Types
• Static V.S. Dynamic
• Source routing V.S. Hop-by-hop
• Centralize V.S. Distributed
• Distance vector V.S. Link state
12
Routing Algorithm: Static Route
• Manually configuration routing table
• Can’t react dynamically to network change such
as router’s crash
• Work well with small network or simple topology
• Unix hosts use command route to add an entry
point to point
connection
route to this
way only, no need
for update
13
Routing Algorithm: Static Technique
Flooding
• Every incoming packet is sent out every outgoing
• Retransmit on all outgoing at each node
• Simple technique, require no network information
• Generate vast numbers of duplicate packet
incoming
flooding
14
Routing Algorithm: Dynamic Route
Dynamic route
• Network protocol adjusts automatically for
topology or traffic changes
• Unix hosts run routing daemon routed or gated
15
Routing Algorithm: Dynamic Route operation
• Routing protocol maintains and distributes
routing information
Update Routing Information
Routing
Table
Routing
Table
Routing
Protocol
Routing
Protocol
16
Routing Algorithm: Source Routing
• Source routing
– Source will determine the entire route
– Routers only act as store-forward devices
• Hop-by-hop
– Routers determine the path based on theirs own
calculation
17
Routing Algorithm: Distance Vector
• Distance means routing metric
• Vector means destination
• Flood routing table only to its neighbors
• RIP is an example
• Also known as Bellmann-Ford algorithm or Ford-
Fulkerson algorithm
18
Distance Vector Algorithm
• Using hop count as a metric
• Each router periodically sends a copy of its
routing table to neighbors
• send <network X, hopcount Y>
routing table
W 0
X 0
Y 1
Z 2
routing table
W 1
X 0
Y 0
Z 1
routing table
W 2
X 1
Y 0
Z 0
W X Y Z
R1 R2 R3
19
Distance Vector Routing Update
• Step by step from router to router
• Slow convergence
R1 R2 R3
topology
change
Œ
recompute R3’s
routing table

R3 sends out
the updated table
Ž
recompute R2’s
routing table

R2 sends out
the updated table

recompute R1’s
routing table
20
Distance Vector: Broadcast (I)
• The first round
R1
R2
R3
R4
I
J
K
L
M
I, 1 hop
J, 1 hop
I, 1 hop
K, 1 hop
L, 1 hop
N
J, 1 hop
K, 1 hop
M, 1 hop
N, 1 hop
L, 1 hop
M, 1 hop
O 1 hop
O
R5
N, 1 hop
O, 1 hop
21
Distance Vector: Broadcast (II)
• The second round
R1
R2
R3
R4
I
J
K
L
M
I, 1 hop
J, 1 hop
K, 2 hops
L, 2 hops
M, 2 hops
N, 2 hops
I, 1 hop
K, 1 hop
L, 1 hop
J, 2 hops
M, 2 hops
N, 2 hops
O, 2 hops
N
J, 1 hop
K, 1 hop
M, 1 hop
N, 1 hop
I, 2 hops
L, 2 hops
O, 2 hops
L, 1 hop
M, 1 hop
O, 1 hop
I, 2 hops
K, 2 hops
J, 2 hops
N, 2 hops
O
R5
N, 1 hop
O, 1 hop
J, 2 hops
K, 2 hops
M, 1 hop
L, 2 hops
22
Distance Vector: Broadcast (III)
• The third round
R1
R2
R3
R4
I
J
K
L
M
I, 1 hop
J, 1 hop
K, 2 hops
L, 2 hops
M, 2 hops
N, 2 hops
O, 3 hops
I, 1 hop
K, 1 hop
L, 1 hop
J, 2 hops
M, 2 hops
N, 2 hops
O, 2 hops
N
J, 1 hop
K, 1 hop
M, 1 hop
N, 1 hop
I, 2 hops
L, 2 hops
O, 2 hops
L, 1 hop
M, 1 hop
O, 1 hop
I, 2 hops
K, 2 hops
J, 2 hops
N, 2 hops
O
R5
N, 1 hop
O, 1 hop
J, 2 hops
K, 2 hops
M, 1 hop
L, 2 hops
I, 3 hops
23
Distance Vector: Crashed Recovery
• R3 crashed
• New complete route of R1
R1
R2 R3
R4
I
J
K
L
M
N
O
R5
R1 routing table
hop via
1 N/A
1 N/A
2 R2
2 R2
2 R3
2 R3
3 R5
net
I
J
K
L
M
N
O
hop via
1 N/A
1 N/A
2 R2
2 R2
3 R2
4 R2
3 R2
net
I
J
K
L
M
N
O
24
Count to Infinity
• R2 does not hear any thing from R3
• R1 says : don’t worry, I can reach R3 in 2 hops,
R2 update hop count to 3
• R1 sees R2’s update, then update itself to 4 and so
on……
R1 R2 R3
hop count to R3
2 1 initial
2 3 1st round
4 3 2nd round
4 5 3rd round
I J
R3 crashed
25
Split Horizon
• Solve by set distance “16” as infinity
• No destination can be more than 15 hops away
from any other
• Distance to X is not reported on the line that
packet for X are sent
• Actually, it reports with infinity
R1 R2 R3
I J R3 crashed
to R3
to R3
26
Dijkstra’s Shortest Path First Algorithm
• Routers send out update messages whenever the
state of a link changes. Hence the name: “Link
State” algorithm.
• Each router calculates lowest cost path to all
others, starting from itself.
• At each step of the algorithm, router adds the next
shortest (i.e. lowest-cost) path to the tree.
• Finds spanning tree routed on source router.
27
Open Shortest Path First (OSPF)
• RIP limited in large internets
• OSPF preferred interior routing protocol for
TCP/IP based internets
• Link state routing used
28
Routing Algorithm: Link State
• Flood routing information to all nodes
• Each router finds who is up and flood this
information to the entire routers
• Use the link state to build a shortest path map to
everybody
• OSPF is an example
• Also known as Shortest Path First (SPF) algorithm
29
Flooding
• Packet sent by source router to every neighbor
• Incoming packet resent to all outgoing links
except source link
• Duplicate packets already transmitted are
discarded
– Prevent incessant retransmission
• All possible routes tried so packet will get through
if route exists
– Highly robust
• At least one packet follows minimum delay route
– Reach all routers quickly
• All nodes connected to source are visited
– All routers get information to build routing table
• High traffic load
30
Link State Overview
• Using cost as a metric
• Exchange its connection and cost to its neighbors
• Each router compute the set of optimum path to all
destination (Shortest Path First)
link state
W 0
X 0
link state
X 0
Y 0
link state
Y 0
Z 0
W X Y Z
31
Link State Concept
• Each router initially begins with directly
connected network
• Determine full knowledge of distant routers and
theirs connection
R2
R1
R3
R4
exchange link
state packets
Routing
Table
Œ


build topological
database
Ž
compute SPF update routing
table
32
Link State Routing Update
• Send information to other routers
• Fast convergence
R2
R1
R3
R4
topology
change
33
OSPF Overview
• Router maintains descriptions of state of
local links
• Transmits updated state information to all
routers it knows about
• Router receiving update must acknowledge
– Lots of traffic generated
• Each router maintains database
– Directed graph
34
Link Costs
• Cost of each hop in each direction is called
routing metric
• OSPF provides flexible metric scheme
based on type of service (TOS)
– Normal (TOS) 0
– Minimize monetary cost (TOS 2)
– Maximize reliability (TOS 4)
– Maximize throughput (TOS 8)
– Minimize delay (TOS 16)
35
Areas
• Make large internets more manageable
• Configure as backbone and multiple areas
• Area – Collection of contiguous networks
and hosts plus routers connected to any
included network
• Backbone – contiguous collection of
networks not contained in any area, their
attached routers and routers belonging to
multiple areas
36
Operation of Areas
• Each are runs a separate copy of the link
state algorithm
– Topological database and graph of just that area
– Link state information broadcast to other
routers in area
– Reduces traffic
– Intra-area routing relies solely on local link
state information
37
Comparison
Distance Vector Link State
pass a copy of pass links state update
whole routing table
add metric from calculate the shortest path
router to router to other routers
frequent periodic update: event updated: fast
slow convergence convergence
38
Internet Routing Architecture
Autonomous
System
Autonomous
System
Autonomous
System
IGP
IGP
IGP
BGP4
BGP4
BGP4
IGP
IGP
IGP IGP
IGP
IGP
EGP/BGP EGP/BGP EGP/BGP EGP/BGP
EGP/BGP
EGP/BGP
Autonomous
System
Autonomous
System
39
Routing in the Internet
The Internet uses hierarchical routing
• The Internet is split into Autonomous Systems (AS’s)
• Within an AS, the administrator chooses an Interior
Gateway Protocol (IGP)
• Examples of IGPs: RIP (rfc 1058), OSPF (rfc 1247).
• Between AS’s, the Internet uses an Exterior Gateway
Protocol
• AS’s today use the Border Gateway Protocol, BGP-4 (rfc
1771)
40
Autonomous System
• AS is a collectionof LANs and WANs and the
interconnectting routers which under the control of
one management authority
• The same AS runs the same Interior Gateway
Protocol
• Why setting up AS? - establish a direct link to
each other rather than route through the core
Internet
• How to select AS? - register and get the AS
number from IAB
41
Gateway Protocol
• Interior gateway protocol
– exchange routing information between routers
within a single AS
– RIP, RIP II, OSPF
• Exterior gateway protocol
– collect network-reachablity information for the
AS
– EGP, BGP
42
Interior Routing Protocols
• RIP
• Uses distributed Bellman-Ford algorithm.
• Updates sent every 30 seconds.
• No authentication.
• Originally in BSD UNIX.
• OSPF
• Link-state updates sent (using flooding) as and when
required.
• Every router runs Dijkstra’s algorithm.
• Authenticated updates.
• Autonomous system may be partitioned into “areas”.
43
Exterior Routing Protocols
Problems:
• Topology: The Internet is a complex mesh of different
AS’s with very little structure.
• Autonomy of AS’s: Each AS defines link costs in
different ways, so not possible to find lowest cost paths.
• Trust: Some AS’s can’t trust others to advertise good
routes (e.g. two competing backbone providers), or to
protect the privacy of their traffic (e.g. two warring
nations).
• Policies: Different AS’s have different objectives (e.g.
route over fewest hops; use one provider rather than
another).
44
Border Gateway Protocol (BGP-4)
• BGP is not a link-state or distance-vector routing
protocol.
• BGP advertises complete paths (a list of AS’s).
• Example of path advertisement:
• “The network 171.64/16 can be reached via the path
{AS1, AS5, AS13}”.
• Paths with loops are detected locally and ignored.
• Local policies pick the preferred path among
options.
• When a link/router fails, the path is “withdrawn”.
45
References
• http://www.cisco.com/en/US/products/hw/routers/p
s274/index.html
• http://www.cisco.com/en/US/products/hw/routers/p
s274/products_data_sheet09186a008010fba1.html
• Computer Networks with Internet Technology
By William Stallings Chapter 11 Interior Routing Protocols

More Related Content

Similar to routing

Tcil_Concept of Routing_n_protocols.pptx
Tcil_Concept of Routing_n_protocols.pptxTcil_Concept of Routing_n_protocols.pptx
Tcil_Concept of Routing_n_protocols.pptxVINAYTANWAR18
 
Day 8 1 introducing routing n
Day 8 1 introducing routing nDay 8 1 introducing routing n
Day 8 1 introducing routing nCYBERINTELLIGENTS
 
Computer networks unit iii
Computer networks    unit iiiComputer networks    unit iii
Computer networks unit iiiJAIGANESH SEKAR
 
Lecture number 5 Theory.pdf(machine learning)
Lecture  number  5 Theory.pdf(machine learning)Lecture  number  5 Theory.pdf(machine learning)
Lecture number 5 Theory.pdf(machine learning)ZainabShahzad9
 
Routing and IP in Advance Computer Network,Vikram Snehi
Routing and IP in Advance Computer Network,Vikram  SnehiRouting and IP in Advance Computer Network,Vikram  Snehi
Routing and IP in Advance Computer Network,Vikram SnehiMR. VIKRAM SNEHI
 
computer Netwoks - network layer
computer Netwoks - network layercomputer Netwoks - network layer
computer Netwoks - network layerSendhil Kumar
 
06.CS2005-NetworkLayer-2021_22(1) (1).pptx
06.CS2005-NetworkLayer-2021_22(1) (1).pptx06.CS2005-NetworkLayer-2021_22(1) (1).pptx
06.CS2005-NetworkLayer-2021_22(1) (1).pptxPocketRocketDC
 
CCNA ppt Day 5
CCNA ppt Day 5CCNA ppt Day 5
CCNA ppt Day 5VISHNU N
 
Unit 3_Network Layer_Part II.pptx
Unit 3_Network Layer_Part II.pptxUnit 3_Network Layer_Part II.pptx
Unit 3_Network Layer_Part II.pptxHODElex
 
16 coms 525 tcpip - routing protocols -all
16    coms 525 tcpip - routing protocols -all16    coms 525 tcpip - routing protocols -all
16 coms 525 tcpip - routing protocols -allPalanivel Kuppusamy
 
Unit 4_Network Layer_Part II.pptx
Unit 4_Network Layer_Part II.pptxUnit 4_Network Layer_Part II.pptx
Unit 4_Network Layer_Part II.pptxHODElex
 
Routing protocols.pptx
Routing protocols.pptxRouting protocols.pptx
Routing protocols.pptxMNSUAM
 

Similar to routing (20)

Chapter07
Chapter07Chapter07
Chapter07
 
Routing.ppt
Routing.pptRouting.ppt
Routing.ppt
 
Tcil_Concept of Routing_n_protocols.pptx
Tcil_Concept of Routing_n_protocols.pptxTcil_Concept of Routing_n_protocols.pptx
Tcil_Concept of Routing_n_protocols.pptx
 
Day 8 1 introducing routing n
Day 8 1 introducing routing nDay 8 1 introducing routing n
Day 8 1 introducing routing n
 
Qs.pptx
Qs.pptxQs.pptx
Qs.pptx
 
Computer networks unit iii
Computer networks    unit iiiComputer networks    unit iii
Computer networks unit iii
 
Lecture number 5 Theory.pdf(machine learning)
Lecture  number  5 Theory.pdf(machine learning)Lecture  number  5 Theory.pdf(machine learning)
Lecture number 5 Theory.pdf(machine learning)
 
Routing Protocols
Routing ProtocolsRouting Protocols
Routing Protocols
 
Ns lecture1: Introduction to Routing Protocol
Ns lecture1: Introduction to Routing ProtocolNs lecture1: Introduction to Routing Protocol
Ns lecture1: Introduction to Routing Protocol
 
11 routing
11 routing11 routing
11 routing
 
Routing and IP in Advance Computer Network,Vikram Snehi
Routing and IP in Advance Computer Network,Vikram  SnehiRouting and IP in Advance Computer Network,Vikram  Snehi
Routing and IP in Advance Computer Network,Vikram Snehi
 
computer Netwoks - network layer
computer Netwoks - network layercomputer Netwoks - network layer
computer Netwoks - network layer
 
06.CS2005-NetworkLayer-2021_22(1) (1).pptx
06.CS2005-NetworkLayer-2021_22(1) (1).pptx06.CS2005-NetworkLayer-2021_22(1) (1).pptx
06.CS2005-NetworkLayer-2021_22(1) (1).pptx
 
CCNA ppt Day 5
CCNA ppt Day 5CCNA ppt Day 5
CCNA ppt Day 5
 
Router
RouterRouter
Router
 
Unit 3_Network Layer_Part II.pptx
Unit 3_Network Layer_Part II.pptxUnit 3_Network Layer_Part II.pptx
Unit 3_Network Layer_Part II.pptx
 
Network layer
Network layerNetwork layer
Network layer
 
16 coms 525 tcpip - routing protocols -all
16    coms 525 tcpip - routing protocols -all16    coms 525 tcpip - routing protocols -all
16 coms 525 tcpip - routing protocols -all
 
Unit 4_Network Layer_Part II.pptx
Unit 4_Network Layer_Part II.pptxUnit 4_Network Layer_Part II.pptx
Unit 4_Network Layer_Part II.pptx
 
Routing protocols.pptx
Routing protocols.pptxRouting protocols.pptx
Routing protocols.pptx
 

Recently uploaded

办理(CSU毕业证书)澳洲查理斯特大学毕业证成绩单原版一比一
办理(CSU毕业证书)澳洲查理斯特大学毕业证成绩单原版一比一办理(CSU毕业证书)澳洲查理斯特大学毕业证成绩单原版一比一
办理(CSU毕业证书)澳洲查理斯特大学毕业证成绩单原版一比一diploma 1
 
WhatsApp 9892124323 ✓Call Girls In Khar ( Mumbai ) secure service - Bandra F...
WhatsApp 9892124323 ✓Call Girls In Khar ( Mumbai ) secure service -  Bandra F...WhatsApp 9892124323 ✓Call Girls In Khar ( Mumbai ) secure service -  Bandra F...
WhatsApp 9892124323 ✓Call Girls In Khar ( Mumbai ) secure service - Bandra F...Pooja Nehwal
 
NO1 Qualified Best Black Magic Specialist Near Me Spiritual Healer Powerful L...
NO1 Qualified Best Black Magic Specialist Near Me Spiritual Healer Powerful L...NO1 Qualified Best Black Magic Specialist Near Me Spiritual Healer Powerful L...
NO1 Qualified Best Black Magic Specialist Near Me Spiritual Healer Powerful L...Amil baba
 
(ANIKA) Wanwadi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(ANIKA) Wanwadi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(ANIKA) Wanwadi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(ANIKA) Wanwadi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...ranjana rawat
 
Vip Udupi Call Girls 7001305949 WhatsApp Number 24x7 Best Services
Vip Udupi Call Girls 7001305949 WhatsApp Number 24x7 Best ServicesVip Udupi Call Girls 7001305949 WhatsApp Number 24x7 Best Services
Vip Udupi Call Girls 7001305949 WhatsApp Number 24x7 Best Servicesnajka9823
 
《伯明翰城市大学毕业证成绩单购买》学历证书学位证书区别《复刻原版1:1伯明翰城市大学毕业证书|修改BCU成绩单PDF版》Q微信741003700《BCU学...
《伯明翰城市大学毕业证成绩单购买》学历证书学位证书区别《复刻原版1:1伯明翰城市大学毕业证书|修改BCU成绩单PDF版》Q微信741003700《BCU学...《伯明翰城市大学毕业证成绩单购买》学历证书学位证书区别《复刻原版1:1伯明翰城市大学毕业证书|修改BCU成绩单PDF版》Q微信741003700《BCU学...
《伯明翰城市大学毕业证成绩单购买》学历证书学位证书区别《复刻原版1:1伯明翰城市大学毕业证书|修改BCU成绩单PDF版》Q微信741003700《BCU学...ur8mqw8e
 
Call Girls In Munirka>༒9599632723 Incall_OutCall Available
Call Girls In Munirka>༒9599632723 Incall_OutCall AvailableCall Girls In Munirka>༒9599632723 Incall_OutCall Available
Call Girls In Munirka>༒9599632723 Incall_OutCall AvailableCall Girls in Delhi
 
VIP Call Girl Saharanpur Aashi 8250192130 Independent Escort Service Saharanpur
VIP Call Girl Saharanpur Aashi 8250192130 Independent Escort Service SaharanpurVIP Call Girl Saharanpur Aashi 8250192130 Independent Escort Service Saharanpur
VIP Call Girl Saharanpur Aashi 8250192130 Independent Escort Service SaharanpurSuhani Kapoor
 
vip Model Basti Call Girls 9999965857 Call or WhatsApp Now Book
vip Model Basti Call Girls 9999965857 Call or WhatsApp Now Bookvip Model Basti Call Girls 9999965857 Call or WhatsApp Now Book
vip Model Basti Call Girls 9999965857 Call or WhatsApp Now Bookmanojkuma9823
 
(办理学位证)加州州立大学北岭分校毕业证成绩单原版一比一
(办理学位证)加州州立大学北岭分校毕业证成绩单原版一比一(办理学位证)加州州立大学北岭分校毕业证成绩单原版一比一
(办理学位证)加州州立大学北岭分校毕业证成绩单原版一比一Fi sss
 
Russian Call Girls Kolkata Chhaya 🤌 8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls Kolkata Chhaya 🤌  8250192130 🚀 Vip Call Girls KolkataRussian Call Girls Kolkata Chhaya 🤌  8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls Kolkata Chhaya 🤌 8250192130 🚀 Vip Call Girls Kolkataanamikaraghav4
 
定制加拿大滑铁卢大学毕业证(Waterloo毕业证书)成绩单(文凭)原版一比一
定制加拿大滑铁卢大学毕业证(Waterloo毕业证书)成绩单(文凭)原版一比一定制加拿大滑铁卢大学毕业证(Waterloo毕业证书)成绩单(文凭)原版一比一
定制加拿大滑铁卢大学毕业证(Waterloo毕业证书)成绩单(文凭)原版一比一zul5vf0pq
 
Hifi Babe North Delhi Call Girl Service Fun Tonight
Hifi Babe North Delhi Call Girl Service Fun TonightHifi Babe North Delhi Call Girl Service Fun Tonight
Hifi Babe North Delhi Call Girl Service Fun TonightKomal Khan
 
Call Girls In Andheri East Call 9892124323 Book Hot And Sexy Girls,
Call Girls In Andheri East Call 9892124323 Book Hot And Sexy Girls,Call Girls In Andheri East Call 9892124323 Book Hot And Sexy Girls,
Call Girls In Andheri East Call 9892124323 Book Hot And Sexy Girls,Pooja Nehwal
 
Beautiful Sapna Call Girls CP 9711199012 ☎ Call /Whatsapps
Beautiful Sapna Call Girls CP 9711199012 ☎ Call /WhatsappsBeautiful Sapna Call Girls CP 9711199012 ☎ Call /Whatsapps
Beautiful Sapna Call Girls CP 9711199012 ☎ Call /Whatsappssapnasaifi408
 
Call Girls in Dwarka Sub City 💯Call Us 🔝8264348440🔝
Call Girls in Dwarka Sub City 💯Call Us 🔝8264348440🔝Call Girls in Dwarka Sub City 💯Call Us 🔝8264348440🔝
Call Girls in Dwarka Sub City 💯Call Us 🔝8264348440🔝soniya singh
 
如何办理(Adelaide毕业证)阿德莱德大学毕业证成绩单Adelaide学历认证真实可查
如何办理(Adelaide毕业证)阿德莱德大学毕业证成绩单Adelaide学历认证真实可查如何办理(Adelaide毕业证)阿德莱德大学毕业证成绩单Adelaide学历认证真实可查
如何办理(Adelaide毕业证)阿德莱德大学毕业证成绩单Adelaide学历认证真实可查awo24iot
 

Recently uploaded (20)

办理(CSU毕业证书)澳洲查理斯特大学毕业证成绩单原版一比一
办理(CSU毕业证书)澳洲查理斯特大学毕业证成绩单原版一比一办理(CSU毕业证书)澳洲查理斯特大学毕业证成绩单原版一比一
办理(CSU毕业证书)澳洲查理斯特大学毕业证成绩单原版一比一
 
WhatsApp 9892124323 ✓Call Girls In Khar ( Mumbai ) secure service - Bandra F...
WhatsApp 9892124323 ✓Call Girls In Khar ( Mumbai ) secure service -  Bandra F...WhatsApp 9892124323 ✓Call Girls In Khar ( Mumbai ) secure service -  Bandra F...
WhatsApp 9892124323 ✓Call Girls In Khar ( Mumbai ) secure service - Bandra F...
 
NO1 Qualified Best Black Magic Specialist Near Me Spiritual Healer Powerful L...
NO1 Qualified Best Black Magic Specialist Near Me Spiritual Healer Powerful L...NO1 Qualified Best Black Magic Specialist Near Me Spiritual Healer Powerful L...
NO1 Qualified Best Black Magic Specialist Near Me Spiritual Healer Powerful L...
 
(ANIKA) Wanwadi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(ANIKA) Wanwadi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(ANIKA) Wanwadi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(ANIKA) Wanwadi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
 
Vip Udupi Call Girls 7001305949 WhatsApp Number 24x7 Best Services
Vip Udupi Call Girls 7001305949 WhatsApp Number 24x7 Best ServicesVip Udupi Call Girls 7001305949 WhatsApp Number 24x7 Best Services
Vip Udupi Call Girls 7001305949 WhatsApp Number 24x7 Best Services
 
Low rate Call girls in Delhi Justdial | 9953330565
Low rate Call girls in Delhi Justdial | 9953330565Low rate Call girls in Delhi Justdial | 9953330565
Low rate Call girls in Delhi Justdial | 9953330565
 
《伯明翰城市大学毕业证成绩单购买》学历证书学位证书区别《复刻原版1:1伯明翰城市大学毕业证书|修改BCU成绩单PDF版》Q微信741003700《BCU学...
《伯明翰城市大学毕业证成绩单购买》学历证书学位证书区别《复刻原版1:1伯明翰城市大学毕业证书|修改BCU成绩单PDF版》Q微信741003700《BCU学...《伯明翰城市大学毕业证成绩单购买》学历证书学位证书区别《复刻原版1:1伯明翰城市大学毕业证书|修改BCU成绩单PDF版》Q微信741003700《BCU学...
《伯明翰城市大学毕业证成绩单购买》学历证书学位证书区别《复刻原版1:1伯明翰城市大学毕业证书|修改BCU成绩单PDF版》Q微信741003700《BCU学...
 
Call Girls In Munirka>༒9599632723 Incall_OutCall Available
Call Girls In Munirka>༒9599632723 Incall_OutCall AvailableCall Girls In Munirka>༒9599632723 Incall_OutCall Available
Call Girls In Munirka>༒9599632723 Incall_OutCall Available
 
VIP Call Girl Saharanpur Aashi 8250192130 Independent Escort Service Saharanpur
VIP Call Girl Saharanpur Aashi 8250192130 Independent Escort Service SaharanpurVIP Call Girl Saharanpur Aashi 8250192130 Independent Escort Service Saharanpur
VIP Call Girl Saharanpur Aashi 8250192130 Independent Escort Service Saharanpur
 
vip Model Basti Call Girls 9999965857 Call or WhatsApp Now Book
vip Model Basti Call Girls 9999965857 Call or WhatsApp Now Bookvip Model Basti Call Girls 9999965857 Call or WhatsApp Now Book
vip Model Basti Call Girls 9999965857 Call or WhatsApp Now Book
 
(办理学位证)加州州立大学北岭分校毕业证成绩单原版一比一
(办理学位证)加州州立大学北岭分校毕业证成绩单原版一比一(办理学位证)加州州立大学北岭分校毕业证成绩单原版一比一
(办理学位证)加州州立大学北岭分校毕业证成绩单原版一比一
 
Russian Call Girls Kolkata Chhaya 🤌 8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls Kolkata Chhaya 🤌  8250192130 🚀 Vip Call Girls KolkataRussian Call Girls Kolkata Chhaya 🤌  8250192130 🚀 Vip Call Girls Kolkata
Russian Call Girls Kolkata Chhaya 🤌 8250192130 🚀 Vip Call Girls Kolkata
 
CIVIL ENGINEERING
CIVIL ENGINEERINGCIVIL ENGINEERING
CIVIL ENGINEERING
 
定制加拿大滑铁卢大学毕业证(Waterloo毕业证书)成绩单(文凭)原版一比一
定制加拿大滑铁卢大学毕业证(Waterloo毕业证书)成绩单(文凭)原版一比一定制加拿大滑铁卢大学毕业证(Waterloo毕业证书)成绩单(文凭)原版一比一
定制加拿大滑铁卢大学毕业证(Waterloo毕业证书)成绩单(文凭)原版一比一
 
Hifi Babe North Delhi Call Girl Service Fun Tonight
Hifi Babe North Delhi Call Girl Service Fun TonightHifi Babe North Delhi Call Girl Service Fun Tonight
Hifi Babe North Delhi Call Girl Service Fun Tonight
 
Call Girls In Andheri East Call 9892124323 Book Hot And Sexy Girls,
Call Girls In Andheri East Call 9892124323 Book Hot And Sexy Girls,Call Girls In Andheri East Call 9892124323 Book Hot And Sexy Girls,
Call Girls In Andheri East Call 9892124323 Book Hot And Sexy Girls,
 
Beautiful Sapna Call Girls CP 9711199012 ☎ Call /Whatsapps
Beautiful Sapna Call Girls CP 9711199012 ☎ Call /WhatsappsBeautiful Sapna Call Girls CP 9711199012 ☎ Call /Whatsapps
Beautiful Sapna Call Girls CP 9711199012 ☎ Call /Whatsapps
 
Call Girls in Dwarka Sub City 💯Call Us 🔝8264348440🔝
Call Girls in Dwarka Sub City 💯Call Us 🔝8264348440🔝Call Girls in Dwarka Sub City 💯Call Us 🔝8264348440🔝
Call Girls in Dwarka Sub City 💯Call Us 🔝8264348440🔝
 
如何办理(Adelaide毕业证)阿德莱德大学毕业证成绩单Adelaide学历认证真实可查
如何办理(Adelaide毕业证)阿德莱德大学毕业证成绩单Adelaide学历认证真实可查如何办理(Adelaide毕业证)阿德莱德大学毕业证成绩单Adelaide学历认证真实可查
如何办理(Adelaide毕业证)阿德莱德大学毕业证成绩单Adelaide学历认证真实可查
 
young call girls in Gtb Nagar,🔝 9953056974 🔝 escort Service
young call girls in Gtb Nagar,🔝 9953056974 🔝 escort Serviceyoung call girls in Gtb Nagar,🔝 9953056974 🔝 escort Service
young call girls in Gtb Nagar,🔝 9953056974 🔝 escort Service
 

routing

  • 1. Routing Concept Sirak Kaewjamnong Computer Network Tech and Security
  • 2. 2 Agenda • Basic concepts • Routing components • Classes of routing protocol • Internet routing protocol
  • 3. 3 What’s Routing Routing - path finding from one end to the other • Routing occurs at layer 3 • Bridging occurs at layer 2 Physical link Data link layer Network layer Transport layer Session layer Presentation layer Application layer Physical link Data link layer Network layer Transport layer Session layer Presentation layer Application layer Physical link Data link layer Network layer Network A Network B
  • 4. 4 IP Routing • IP performs: • search for a matching host address • search for a matching network address • search for a default entry • Routing done by IP router, when it searches the routing table and decide which interface to end a packet out. incoming which interface ?
  • 5. 5 Routing Tables • Routing is carried out in a router by consulting routing table. • No unique format for routing tables, typically table contains: – address of a destination – IP address of next hop router – network interface to be used – subnet mask for the this interface – distance to the destination
  • 6. 6 Routing Component • Three important routing elements : – algorithm – database – protocol • Algorithm : can be differentiate based on several key characteristics • Database : table in routers or routing table • Protocol: the way information for routing to be gathered and distributed
  • 7. 7 Routing Algorithm Design goals • Optimality - compute the best route • Simplicity/low overhead - efficient with a minimum software and utilization overhead • Robustness/stability- perform correctly in the face of unusual circumstances • Rapid convergence- responds quickly when the network changes • Flexibility- accurate adapt to a variety of network
  • 8. 8 Routing Protocols • Routing protocol : protocol to exchange of information between routers about the current state of the network • Routing protocol jobs – create routing table entries – keep routing table up-to-date – compute the best choice for the next hop router
  • 9. 9 Routing Metrics • How do we decide that one route is better than another? • Solution : using a metric as a measurement to compare routes • Metrics may be distance, throughput, delay, error rate, and cost. • Today, IP supports Delay, Throughput, Reliability and Cost (DTRC)
  • 10. 10 Hop Count • A hop is defined as a passage through one router R1 R2 R3 1 hop 1 hop 1 hop 1 hop 2 hops
  • 11. 11 Routing Algorithm Types • Static V.S. Dynamic • Source routing V.S. Hop-by-hop • Centralize V.S. Distributed • Distance vector V.S. Link state
  • 12. 12 Routing Algorithm: Static Route • Manually configuration routing table • Can’t react dynamically to network change such as router’s crash • Work well with small network or simple topology • Unix hosts use command route to add an entry point to point connection route to this way only, no need for update
  • 13. 13 Routing Algorithm: Static Technique Flooding • Every incoming packet is sent out every outgoing • Retransmit on all outgoing at each node • Simple technique, require no network information • Generate vast numbers of duplicate packet incoming flooding
  • 14. 14 Routing Algorithm: Dynamic Route Dynamic route • Network protocol adjusts automatically for topology or traffic changes • Unix hosts run routing daemon routed or gated
  • 15. 15 Routing Algorithm: Dynamic Route operation • Routing protocol maintains and distributes routing information Update Routing Information Routing Table Routing Table Routing Protocol Routing Protocol
  • 16. 16 Routing Algorithm: Source Routing • Source routing – Source will determine the entire route – Routers only act as store-forward devices • Hop-by-hop – Routers determine the path based on theirs own calculation
  • 17. 17 Routing Algorithm: Distance Vector • Distance means routing metric • Vector means destination • Flood routing table only to its neighbors • RIP is an example • Also known as Bellmann-Ford algorithm or Ford- Fulkerson algorithm
  • 18. 18 Distance Vector Algorithm • Using hop count as a metric • Each router periodically sends a copy of its routing table to neighbors • send <network X, hopcount Y> routing table W 0 X 0 Y 1 Z 2 routing table W 1 X 0 Y 0 Z 1 routing table W 2 X 1 Y 0 Z 0 W X Y Z R1 R2 R3
  • 19. 19 Distance Vector Routing Update • Step by step from router to router • Slow convergence R1 R2 R3 topology change Œ recompute R3’s routing table  R3 sends out the updated table Ž recompute R2’s routing table  R2 sends out the updated table  recompute R1’s routing table
  • 20. 20 Distance Vector: Broadcast (I) • The first round R1 R2 R3 R4 I J K L M I, 1 hop J, 1 hop I, 1 hop K, 1 hop L, 1 hop N J, 1 hop K, 1 hop M, 1 hop N, 1 hop L, 1 hop M, 1 hop O 1 hop O R5 N, 1 hop O, 1 hop
  • 21. 21 Distance Vector: Broadcast (II) • The second round R1 R2 R3 R4 I J K L M I, 1 hop J, 1 hop K, 2 hops L, 2 hops M, 2 hops N, 2 hops I, 1 hop K, 1 hop L, 1 hop J, 2 hops M, 2 hops N, 2 hops O, 2 hops N J, 1 hop K, 1 hop M, 1 hop N, 1 hop I, 2 hops L, 2 hops O, 2 hops L, 1 hop M, 1 hop O, 1 hop I, 2 hops K, 2 hops J, 2 hops N, 2 hops O R5 N, 1 hop O, 1 hop J, 2 hops K, 2 hops M, 1 hop L, 2 hops
  • 22. 22 Distance Vector: Broadcast (III) • The third round R1 R2 R3 R4 I J K L M I, 1 hop J, 1 hop K, 2 hops L, 2 hops M, 2 hops N, 2 hops O, 3 hops I, 1 hop K, 1 hop L, 1 hop J, 2 hops M, 2 hops N, 2 hops O, 2 hops N J, 1 hop K, 1 hop M, 1 hop N, 1 hop I, 2 hops L, 2 hops O, 2 hops L, 1 hop M, 1 hop O, 1 hop I, 2 hops K, 2 hops J, 2 hops N, 2 hops O R5 N, 1 hop O, 1 hop J, 2 hops K, 2 hops M, 1 hop L, 2 hops I, 3 hops
  • 23. 23 Distance Vector: Crashed Recovery • R3 crashed • New complete route of R1 R1 R2 R3 R4 I J K L M N O R5 R1 routing table hop via 1 N/A 1 N/A 2 R2 2 R2 2 R3 2 R3 3 R5 net I J K L M N O hop via 1 N/A 1 N/A 2 R2 2 R2 3 R2 4 R2 3 R2 net I J K L M N O
  • 24. 24 Count to Infinity • R2 does not hear any thing from R3 • R1 says : don’t worry, I can reach R3 in 2 hops, R2 update hop count to 3 • R1 sees R2’s update, then update itself to 4 and so on…… R1 R2 R3 hop count to R3 2 1 initial 2 3 1st round 4 3 2nd round 4 5 3rd round I J R3 crashed
  • 25. 25 Split Horizon • Solve by set distance “16” as infinity • No destination can be more than 15 hops away from any other • Distance to X is not reported on the line that packet for X are sent • Actually, it reports with infinity R1 R2 R3 I J R3 crashed to R3 to R3
  • 26. 26 Dijkstra’s Shortest Path First Algorithm • Routers send out update messages whenever the state of a link changes. Hence the name: “Link State” algorithm. • Each router calculates lowest cost path to all others, starting from itself. • At each step of the algorithm, router adds the next shortest (i.e. lowest-cost) path to the tree. • Finds spanning tree routed on source router.
  • 27. 27 Open Shortest Path First (OSPF) • RIP limited in large internets • OSPF preferred interior routing protocol for TCP/IP based internets • Link state routing used
  • 28. 28 Routing Algorithm: Link State • Flood routing information to all nodes • Each router finds who is up and flood this information to the entire routers • Use the link state to build a shortest path map to everybody • OSPF is an example • Also known as Shortest Path First (SPF) algorithm
  • 29. 29 Flooding • Packet sent by source router to every neighbor • Incoming packet resent to all outgoing links except source link • Duplicate packets already transmitted are discarded – Prevent incessant retransmission • All possible routes tried so packet will get through if route exists – Highly robust • At least one packet follows minimum delay route – Reach all routers quickly • All nodes connected to source are visited – All routers get information to build routing table • High traffic load
  • 30. 30 Link State Overview • Using cost as a metric • Exchange its connection and cost to its neighbors • Each router compute the set of optimum path to all destination (Shortest Path First) link state W 0 X 0 link state X 0 Y 0 link state Y 0 Z 0 W X Y Z
  • 31. 31 Link State Concept • Each router initially begins with directly connected network • Determine full knowledge of distant routers and theirs connection R2 R1 R3 R4 exchange link state packets Routing Table Œ   build topological database Ž compute SPF update routing table
  • 32. 32 Link State Routing Update • Send information to other routers • Fast convergence R2 R1 R3 R4 topology change
  • 33. 33 OSPF Overview • Router maintains descriptions of state of local links • Transmits updated state information to all routers it knows about • Router receiving update must acknowledge – Lots of traffic generated • Each router maintains database – Directed graph
  • 34. 34 Link Costs • Cost of each hop in each direction is called routing metric • OSPF provides flexible metric scheme based on type of service (TOS) – Normal (TOS) 0 – Minimize monetary cost (TOS 2) – Maximize reliability (TOS 4) – Maximize throughput (TOS 8) – Minimize delay (TOS 16)
  • 35. 35 Areas • Make large internets more manageable • Configure as backbone and multiple areas • Area – Collection of contiguous networks and hosts plus routers connected to any included network • Backbone – contiguous collection of networks not contained in any area, their attached routers and routers belonging to multiple areas
  • 36. 36 Operation of Areas • Each are runs a separate copy of the link state algorithm – Topological database and graph of just that area – Link state information broadcast to other routers in area – Reduces traffic – Intra-area routing relies solely on local link state information
  • 37. 37 Comparison Distance Vector Link State pass a copy of pass links state update whole routing table add metric from calculate the shortest path router to router to other routers frequent periodic update: event updated: fast slow convergence convergence
  • 38. 38 Internet Routing Architecture Autonomous System Autonomous System Autonomous System IGP IGP IGP BGP4 BGP4 BGP4 IGP IGP IGP IGP IGP IGP EGP/BGP EGP/BGP EGP/BGP EGP/BGP EGP/BGP EGP/BGP Autonomous System Autonomous System
  • 39. 39 Routing in the Internet The Internet uses hierarchical routing • The Internet is split into Autonomous Systems (AS’s) • Within an AS, the administrator chooses an Interior Gateway Protocol (IGP) • Examples of IGPs: RIP (rfc 1058), OSPF (rfc 1247). • Between AS’s, the Internet uses an Exterior Gateway Protocol • AS’s today use the Border Gateway Protocol, BGP-4 (rfc 1771)
  • 40. 40 Autonomous System • AS is a collectionof LANs and WANs and the interconnectting routers which under the control of one management authority • The same AS runs the same Interior Gateway Protocol • Why setting up AS? - establish a direct link to each other rather than route through the core Internet • How to select AS? - register and get the AS number from IAB
  • 41. 41 Gateway Protocol • Interior gateway protocol – exchange routing information between routers within a single AS – RIP, RIP II, OSPF • Exterior gateway protocol – collect network-reachablity information for the AS – EGP, BGP
  • 42. 42 Interior Routing Protocols • RIP • Uses distributed Bellman-Ford algorithm. • Updates sent every 30 seconds. • No authentication. • Originally in BSD UNIX. • OSPF • Link-state updates sent (using flooding) as and when required. • Every router runs Dijkstra’s algorithm. • Authenticated updates. • Autonomous system may be partitioned into “areas”.
  • 43. 43 Exterior Routing Protocols Problems: • Topology: The Internet is a complex mesh of different AS’s with very little structure. • Autonomy of AS’s: Each AS defines link costs in different ways, so not possible to find lowest cost paths. • Trust: Some AS’s can’t trust others to advertise good routes (e.g. two competing backbone providers), or to protect the privacy of their traffic (e.g. two warring nations). • Policies: Different AS’s have different objectives (e.g. route over fewest hops; use one provider rather than another).
  • 44. 44 Border Gateway Protocol (BGP-4) • BGP is not a link-state or distance-vector routing protocol. • BGP advertises complete paths (a list of AS’s). • Example of path advertisement: • “The network 171.64/16 can be reached via the path {AS1, AS5, AS13}”. • Paths with loops are detected locally and ignored. • Local policies pick the preferred path among options. • When a link/router fails, the path is “withdrawn”.