ND-Chapter 3
ND-Chapter 3
1
Out lines
✓ Definition
✓ RIP V1 and V2
✓ RIP Characteristics
✓ OSPF
What is Routing Information Protocol (RIP)?
• Uses hop count as its only metric for selecting the best path.
Broadcast
Update Mechanism Multicast (224.0.0.9)
(255.255.255.255)
Simple Authentication
Authentication None
(password)
Maximum Hops 15 15
9
Encapsulated RIP Message
1
0
Encapsulated RIP Message
IP Packet
IP Source Address = Address of sending interface
IP Destination Address = Broadcast: 255.255.255.255
Protocol field = 17 for UDP
1
1
Encapsulated RIP Message
UDP Segment
Source Port = 520
Destination
1 Port = 520
2
Encapsulated RIP Message
Bit
0 7 8 15 16 23 24 31
Command=1or2 Version=1 Mustbezero
Route
Entry
Addressfamilyidentifier(2=IP) Mustbezero
IPAddress(NetworkAddress)
Mustbezero
Mustbezero
Metric (Hops)
MultipleRouteEntries,uptoamaximumof25
1
4
RIPv1 Message Format
0 7 8 15 16 23 24 31
Command = 1 or 2 Version = 1 Must be zero
Bit Address family identifier (2 = IP) Must be zero
IP Address (Network Address)
Must be zero
Must be zero
Route Metric (Hops)
Entry
Multiple Route Entries, up to a maximum of 25
192.168.3.0/24
RIP enabled on all
routers .1
.2 .2
192.168.2.0/24 192.168.4.0/24
192.168.1.0/24 192.168.5.0/24
.1
.1
.1 .1
10
Interface Configurations
R1 R3
interface FastEthernet0/0 interface FastEthernet0/0
ip address 192.168.1.1 255.255.255.0 ip address 192.168.5.1 255.255.255.0
! !
interface Serial0/0 interface Serial0/1
ip address 192.168.2.1 255.255.255.0 ip address 192.168.4.1 255.255.255.0
clockrate 64000
!
R2
interface FastEthernet0/0
ip address 192.168.3.1 255.255.255.0
!
interface Serial0/0
ip address 192.168.2.2 255.255.255.0
!
Don’t forget: no shutdown
interface Serial0/1
ip address 192.168.4.2 255.255.255.0
clockrate 64000
11
Verify
R1#show ip inter brief
Interface IP-Address OK? Method Status Protocol
FastEthernet0/0 192.168.1.1 YES manual up up
Serial0/0 192.168.2.1 YES manual up up
18
Enabling RIP
R1#
R1#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R1(config)#router ?
bgp Border Gateway Protocol (BGP) egp
Exterior Gateway Protocol (EGP)
eigrp Enhanced Interior Gateway Routing Protocol (EIGRP) igrp
Interior Gateway Routing Protocol (IGRP)
isis ISO IS-IS
iso-igrp IGRP for OSI networks mobile
Mobile routes
odr On Demand stub Routes
ospf Open Shortest Path First (OSPF) rip
Routing Information Protocol (RIP)
R1(config)#router rip
R1(config-router)#
R2(config)#router rip
R2(config-router)#
R3(config)#router rip
R3(config-router)#
20
Network Command
R1(config)#router rip
R1(config-router)#network 192.168.1.0
R1(config-router)#network 192.168.2.0
23
Verify: Running-config
R1#show running-config
Building configuration...
!
router rip
network 192.168.1.0
network 192.168.2.0
!
24
Verify: Routing Table
R1#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile,
25
Verify: Routing Table
R2#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile,
• R2 Routing Table
26
Verify: Routing Table
R3#show ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile,
• R3 Routing Table
27
R1: Receiving Updates
192.168.3.0 in 1 hops
192.168.4.0 in 1 hops
192.168.5.0 in 2 hops
28
R1: Sending Updates
192.168.1.0 metric 1
192.168.2.0 metric 1
192.168.3.0 metric 2
192.168.4.0 metric 2
192.168.5.0 metric 3
29
Passive Interface
R1(config)#router rip
R1(config-router)#passive-interface fa 0/0
R2(config)#router rip
R2(config-router)#passive-interface fa 0/0 X
R2(config)#router rip
R2(config-router)#passive-interface fa 0/0
192.168.3.0/24
RIP enabled on all
.1 routers
.2 .2
192.168.2.0/24 192.168.4.0/24
192.168.1.0/24 192.168.5.0/24
.1
.1
.1 .1
31
Review: Scenario A
R1
router rip
network 192.168.1.0
network 192.168.2.0
passive-interface fa 0/0
R2
router rip
network 192.168.2.0
network 192.168.3.0
network 192.168.4.0
passive-interface fa 0/0
R3
router rip
network 192.168.4.0
network 192.168.5.0
passive-interface fa 0/0
32
What is OSPF?
✓ OSPF (Open Shortest Path First) is a link-state routing protocol
used to determine the best path for routing packets within an IP
network.
✓ Open Standard protocol, meaning it's vendor-neutral and widely
supported across different devices.
✓ Uses Dijkstra’s algorithm to compute the shortest path.
✓ Designed for large-scale networks with hierarchical design
using areas.
How OSPF Works
✓ Link-State Advertisement (LSA): Routers share information about
their links with neighbors.
✓ Link-State Database (LSDB): Each router builds a database based
on received LSAs.
✓ Shortest Path First (SPF): Dijkstra’s algorithm calculates the best
paths using the LSDB.
✓ Area Structure: OSPF uses areas to reduce routing table size and
optimize network performance.
Use of OSPF
Common Use:
✓ Enterprise Networks: Ideal for large organizations with multiple routers.
Complex Configuration
✓ OSPF requires careful configuration, especially in larger, hierarchical networks.
Memory & CPU Intensive
✓ OSPF routers maintain a Link-State Database (LSDB), which grows as the
network expands.
Scalability Issues
✓ OSPF is scalable but struggles with very large networks (e.g., networks with
1000+ routers).
Overhead in Large Networks
✓ In large networks, flooding can cause high traffic overhead.
Cont..