Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
CIS 82 Routing Protocols and Concepts Rick Graziani Cabrillo College graziani@cabrillo edu Spring 2!1!
"his Presentation
For detailed information see the notes section within this PowerPoint. "his presentation is based on the #$ploration course%book& Routing Protocols and Concepts 'otes section (a) contain additional details For a cop) o* this presentation and access to () web site *or other CC'+& CC'P& and ,ireless resources please e(ail (e *or a userna(e and password #(ail- graziani@cabrillo edu ,eb Site- www cabrillo edu%.rgraziani
Note
"his chapter contains (ostl) introductor) (aterial 0ost o* not all o* this in*or(ation will be e$plained in (ore detail in later chapters or later courses "he bootup process and the I1S are e$a(ined in a later course 2o not worr) or *ocus too (uch on the details *or now "his will all be e$a(ined and e$plained in the *ollowing chapters
"opics
Inside the Router Routers are co(puters Router CP< and 0e(or) Internetwork 1perating S)ste( Router 5ootup Process Router Ports and Inter*aces Routers and the 'etwork =a)er Path 2eter(ination and Switching Function Packet Fields and Fra(e For(ats 5est Path and 0etrics #>ual Cost =oad 5alancing Path 2eter(ination Switching Function C=I Con*iguration and +ddressing I(ple(enting 5asic +ddressing Sche(es 5asic Router Con*iguration 5uilding the Routing "able Introducing the Routing "able 2irectl) Connected 'etworks Static Routing 2)na(ic Routing Routing "able Principles
A router is a computer "he *irst router ?+RP+'#"@ I0P ?Inter*ace 0essage Processor@ Aone)well 81: (inico(puter +ugust /!& 1;:;
9
Routers *orwarding packets (packet switching) Fro( the original source to the final destination Selects best path + router connects multiple networks Inter*aces on di**erent IP networks
1!
"he routerBs pri(ar) responsibilit) 2eter(ining the best path Forwarding packets toward their destination
11
IP Packet enters routerBs #thernet inter*ace Router e$a(ines the packetBs destination IP address Router searches *or a best (atch between packetBs destination IP address and network address in routing table <sing the e$it7inter*ace in the route& the packet is *orwarded to the ne$t router or the *inal destination
Routing table 2eter(ines best path 5est (atch between destination IP address and network 12 address in routing table
!an different I#& images +n I1S i(age is a *ile that contains the entire I1S *or that router I#& features #$a(ple IPv6 or a routing protocol such as Inter(ediate S)ste(CtoCInter(ediate S)ste( ?IS-IS@
13
18
5ootup Process
startup"config
I#&
,here is the per(anent con*iguration *ile stored used during boot7upD ,here is the backup ?partial@ cop) o* the I1S storedD ,here is I1S per(anentl) stored be*ore it is copied into R+0D ,here are all changes to the con*iguration i((ediatel) storedD
N%RA! (') R#! (() R#! (() F)A&* (C) RA! (A)
A
running"config I#& (running)
'
startup"config
C
I#&
(
'ootup program ios (partial) 19
+ + + + + + +
startup"config
I#&
startup"config I#&
'
A
running"config I#& (running)
'
startup"config
C
I#&
(
'ootup program ios (partial)
1;
21
Port 7 (anage(ent ports used *or ad(inistrati4e access Interface 7 capable o* sending and recei4ing user tra**ic Note- However, these terms are often used interchangeably.
22
0anage(ent Ports
Console port "er(inal PC running ter(inal e(ulator so*tware 'o need *or network access <sed *or initial con*iguration Au1iliar (AU2) port 'ot all routers ha4e au$iliar) ports +t ti(es& can be used si(ilarl) to a console port Can also be used to attach a (ode( Note- Au iliary !orts will not be used in this curriculum. 2/
Router Inter*aces
Interfaces " Recei4e and *orward packets Earious t)pes o* networks 2i**erent t)pes o* media and connectors 2i**erent t)pes o* interfaces Fast 3thernet inter*aces 7 )ANs &erial interfaces 7 4AN connections including 5,& (&)&23 and I&(N
Router Inter*aces
Router Inter*ace (ifferent network IP address and subnet mask o* that network Cisco IOS will not allow two active interfaces on the same 28 router to belong to the same network.
=+' Inter*aces
3thernet and Fast 3thernet interfaces Connects the router to the =+' )a er . !AC address Participates in the 3thernet +ddress Resolution Protocol ?ARP@ 0aintains +RP cache *or that inter*ace Sends +RP re>uests when needed Responds with +RP replies when re>uired ")picall) an R6738 Iack ?<"P@ Router to switch- straight"through cable Router to router- crosso$er cable
2:
,+' Inter*aces
Point"to"Point6 I&(N6 and Frame Rela interfaces Connects routers to e$ternal networks "he =a)er 2 encapsulation can be di**erent t)pes including PPP Fra(e Rela) A2=C ?Aigh7=e4el 2ata =ink Control@ Note- MA# addresses are used only on $thernet interfaces and are not on %A& interfaces. =a)er 2 ,+' encapsulation t)pes and addresses are co4ered in a later course
29
)a er / de$ice because its pri(ar) *orwarding decision is based on the in*or(ation in the =a)er / IP packet ?destination IP address@ "his is known as routing
28
2;
#thernet Fra(e
=a)er 2 addresses- +ddressing PC%Router7to7PC%Router within a network =a)er / addresses 1riginal source la)er / address ?IP@ to *inal destination la)er / address ?IP@ 2oes not change ?unless '+" is used@
/1
5est Path
RouterBs deter(ine best7path to a network 2epends on the routing protocol + protocol used to between routers to deter(ine 7best path8 Routing protocols use their own rules and metrics A metric9 Juantitati4e 4alue used to (easure the distance to a gi4en route 'est path9 Path with the lowest metric /2
5o reach the ,<.-,=>-,-?@.0 network it is . hops $ia R. and . hops $ia R0-
+ +
,<.-,=>-,-?@.0
,hat happens i* a routing table has two or (ore paths with the sa(e (etric to the sa(e destination networkD ?e;ual"cost metric@ Router will per*or( e;ual"cost load balancing
//
+ 5, +
5/
,<.-,=>-,-?@.0
Can a router use (ultiple paths i* the paths ?cost& (etric@ to reach the destination network are not e>ualD 3IARP routing protocol which supports une;ual cost load balancing
/3
Packet Forwarding
Packet *orwarding in4ol4es two *unctions1 Path deter(ination *unction 2 Switching *unction
/8
Path 2eter(ination
Router recei4es packet 2estination IP address (atches a network on one o* its directl) connected networks Packet is *orwarded out that network
(irectl connected network Path determination *unction is the process o* how the router deter(ines which path to use when *orwarding a packet Router searches its routing table *or (atch with packet:s destination IP address 1ne o* three path deter(inations results *ro( this search (irectl connected network Remote network No route determined /:
Path 2eter(ination
Router recei4es packet 2estination IP address (atches a re(ote network which can onl) be reached 4ia another router Packet is *orwarded out that network to the ne$t7hop router
Remote network
/9
Path 2eter(ination
Router recei4es packet 2estination IP address does '1" (atch an) network in the routerBs routing table Packet is dropped No route determined
2oes this (ean the network does not e$istD 'o& onl) that the router does not know about that network ?later@
/8
&witching function is the process used b) a router to +ccept a packet on one inter*ace and Forward it out another inter*ace #ncapsulate the packet in the appropriate data7link *ra(e t)pe *or the outgoing data link
/;
,<.-,=>-0-,?
Path Forwarding
,<.-,=>-,-,?
)a er / IP Packet
(est- IP ,<.-,=>-0-,? &ource IP ,<.-,=>-,-,? IP fields (ata 5railer
,hat does a router do with a packet recei4ed *ro( one network and destined *or another networkD 1 2ecapsulates the =a)er / packet b) re(o4ing the =a)er 2 *ra(e header and trailer 2 #$a(ines the destination IP address o* the IP packet to *ind the best path in the routing table / #ncapsulates the =a)er / packet into a new =a)er 2 *ra(e and *orwards the *ra(e out the e$it inter*ace 3!
Re(e(ber- #ncapsulation
"hese addresses do not changeK "hese change *ro( host to router& router to router& and router to host
)a er . (ata )ink Frame
(estination Address &ource Address 5 pe (ata 5railer
)a er / IP Packet
(estination IP Address &ource IP Address #ther IP fields (ata
)a er / IP Packet
(est- IP ,<.-,=>-0-,? &ource IP ,<.-,=>-,-,? IP fields (ata 5railer
"his is Iust a su((ar) "he details will be shown ne1tC Now for the detailsB
32
)a er / IP Packet
(est- IP ,<.-,=>-0-,? &ource IP ,<.-,=>-,-,? IP fields (ata 5railer
3/
)a er / IP Packet
(est- IP ,<.-,=>-0-,? &ource IP ,<.-,=>-,-,? IP fields (ata 5railer 5railer
R5A Routing 5able *ops Ne1t"hop"ip 31it"interface ? (ir-Conne? ? (ir-Conn e, , ,<.-,=>-.-. e, . ,<.-,=>-.-. e,
33
)a er / IP Packet
(est- IP ,<.-,=>-0-,? &ource IP ,<.-,=>-,-,? IP fields (ata 5railer
R5' Routing 5able *ops Ne1t"hop"ip 31it"interface , ,<.-,=>-.-, e? ? (ir-Conn e? ? (ir-Conn s? , ,<.-,=>-/-. s?
38
)a er / IP Packet
(est- IP ,<.-,=>-0-,? &ource IP ,<.-,=>-,-,? IP fields (ata 5railer
R5C Routing 5able Network *ops Ne1t"hop"ip 31it"interface ,<.-,=>-,-?@.0 . ,<.-,=>-/-, s? ,<.-,=>-.-?@.0 , ,<.-,=>-/-, s? ,<.-,=>-/-?@.0 ? (ir-Conn s? ,<.-,=>-0-?@.0 ? (ir-Conn e?
3:
)a er / IP Packet
(est- IP ,<.-,=>-0-,? &ource IP ,<.-,=>-,-,? IP fields (ata 5railer
39
)a er / IP Packet
(est- IP ,<.-,=>-0-,? &ource IP ,<.-,=>-,-,? IP fields (ata 5railer
38
'efore we begin9 2ownload- Packet "racer File http-%%netacad cabrillo edu%curriculu(%graziani%cis82%labs7e2%e2717872 p 2ownload and Install Packet "racer )ou ha4e not done so alread) http-%%www cabrillo edu%.rgraziani%courses%cis81 ht(l 2ownload =ab http-%%netacad cabrillo edu%curriculu(%graziani%cis82%labs7e2%enL#Routi
3;
Aands7on =abs
Networking )ab9 Room .D?0 and C5C Net)ab
Check"out Pods
8!
81
=
I(portant- + console connection is not the sa(e as a network connectionK
82
*era *erm, Hy!er*erminal, Putty, etc. P#+ ,erial !ort - .outer+ #onsole Port .ollover or #onsole #able
Console Port
8/
NIC
,hat ,hat
,hen should )ou not use a network connection to con*igure the routerD
router 'telnet). so*tware%co((and do )ou needD *#P/IP, *erminal !rom!t '01,), *era *erm, etc. cable and ports do )ou useD P# - .outer+ $thernet &I# $thernet straight"through cable %hen the change may 83 connection. disconnect the telnet
,hen can )ou use a network connection to the routerD %hen there is a network connection to the
NIC &erial
Console Port
88
Serial Connectors
S(art Serial G1lderH Serial
28!! ha4e the Golder&H larger serial inter*aces =ater Cisco routers use the s(art serial inter*aces which allows (ore data to be *orwarded across *ewer cable pins
8:
Serial Cables
(C3 Cable (53 Cable
Router is t)picall) a 2"# de4ice "he 2"# cable is connected to the serial inter*ace on the router to a CS<%2S< de4ice ?2C#@ (C3 &ide (53 &ide
89
88
2ownload- Packet "racer File http-%%netacad cabrillo edu%curriculu(%graziani%cis82%labs7e2%e2717872 pkt 2ownload =ab http-%%netacad cabrillo edu%curriculu(%graziani%cis82%labs7e2%#2L=abL1L8L2Lcabrillo doc 8;
( ( ( (
S S S S
u* u* u* u*
u* u* u* u*
Fast#thernet ! F Fast#thernet !%! Fast#thernet 1 F Fast#thernet !%1 F Fast#thernet 1%! Serial ! F Serial !%! F Serial !%!%! Serial 1 F Serial !%1 F Serial !%!%1
:!
Router(config)# )anner *otd - message Router(config)# interface type number Router(config-if)# ip address address mask Router(config-if)# description description Router(config-if)# no s&'tdo(n
:1
1ther Co((ands
Router# cop% r'nning.config start'p.config Router# Router# Router# Router# s&o( s&o( s&o( s&o( r'nning.config ip ro'te ip interface )rief interfaces
:2
2i**erent 0odes
Router# &ostna*e 1 / / In,alid in*ut detected at 010 )ar2er% Router# config're ter*inal Router(config)# &ostna*e 1 R1(config)#
Serial Connectors
S(art Serial G1lderH Serial
28!! ha4e the Golder&H larger serial inter*aces =ater Cisco routers use the s(art serial inter*aces which allows (ore data to be *orwarded across *ewer cable pins
:3
Serial Connectors
(C3 Cable
(53 Cable
Router is t)picall) a 2"# de4ice "he 2"# cable is connected to the serial inter*ace on the router to a CS<%2S< de4ice ?2C#@
:8
::
"he I1S o*ten sends unsolicited (essages 2oes not a**ect the co((and Can cause )ou to lose )our place when t)ping
:9
"o keep the unsolicited output separate *ro( )our input& enter line con*iguration (ode *or the console port and add the logging s%nc&rono's
:8
Fa?@,
:;
Fa?@,
9!
Fa?@,
91
Eeri*)ing Inter*aces
R1# s&o( interfaces @so)e interfaces not sho-n+ 2ast#t&ernet0/0 is 'p; line *rotocol is 'p (connected) Aard-are is 5ance; address is 0000.eca0.1511 (.ia !!e!%fBe<%e<Be) 9escri*tion4 R1 5A6 Internet address is 192.168.1.1/2! M=8 1>!! .?tes; C: 1!!!!! K.it; 95( 1!! usec; rel? $>>"$>>; load 1"$>> #ncaps'lation 3 53; loo*.ac2 not set ARP t?*e4 ARPA; 3 5 6i*eo't 0!:00:00; 5ast in*ut !!4!!4!'; out*ut !!4!!4!>; out*ut hang ne,er 5ast clearing of Dsho- interfaceE counters ne,er 7'e'eing strateg%: fifo Out*ut Fueue 4!"<! (siGe")aH) > )inute in*ut rate ! .its"sec; ! *ac2ets"sec > )inute out*ut rate ! .its"sec; ! *ac2ets"sec ! *ac2ets in*ut; ! .?tes; ! no .uffer Recei,ed ! .roadcasts; ! runts; ! giants; ! throttles @out*ut o)itted+ Serial0/0 is 'p; line *rotocol is 'p (connected) Aard-are is A9&<>B! 9escri*tion4 5in2 to R$ Internet address is 192.168.2.1/2! M=8 1>!! .?tes; C: 1><< K.it; 95( $!!!! usec; rel? $>>"$>>; load 1"$>> #ncaps'lation 8"LC; loo*.ac2 not set; 2ee*ali,e set (1! sec) 5ast in*ut ne,er; out*ut ne,er; out*ut hang ne,er 92 @out*ut o)itted+
'ote- s&'tdo(n is the de*ault no s&'tdo(n does not show in the con*iguration
9/
Sa4e Con*iguration
R1# cop% r'nning.config start'p.config R1# s&o( start'p.config 8sing B$' .?tes I ,ersion 1$%7 I hostna)e R1 I interface Fast thernet!"! descri*tion R1 5A6 i* address 1#$%1&'%1%1 $>>%$>>%$>>%! I interface Serial!"! descri*tion 5in2 to R$ i* address 1#$%1&'%$%1 $>>%$>>%$>>%! cloc2 rate &<!!! I .anner )otd 1J 333333333333333333333333333333333333333333 :AR6I6KII 8nauthoriGed Access Prohi.itedII 333333333333333333333333333333333333333333 1J line con ! *ass-ord cisco login line ,t? ! < *ass-ord cisco login I end
93
9:
Routing table is a data *ile in R+0 that is used to store route in*or(ation about 2irectl) connected networks Re(ote networks
99
#$it Inter*aces
98
directl connected network is a network that is directl) attached to one o* the router inter*aces ,hen a routerBs inter*ace is con*igured with an IP address and subnet (ask& the inter*ace beco(es a host on that attached network +cti4e directl) connected networks are added to the routing table 9;
Re(ote 'etwork
+ remote network is a network that is not directl) connected to the router + re(ote network is a network that can onl) be reached b) sending the packet to another router Re(ote networks are added to the routing table using- ?later@ 2)na(ic routing protocol Static routes
8!
<sing 'et=ab
81
'et=ab
5asic Router Pod
82