EIGRP or OSPF – Which should I use?
Kevin Delgadillo, PLM, IP Routing, NSSTG
Ernie Mikulic, PM, OSPF, PfR, SAF
© 2010 Cisco Systems, Inc. All rights reserved.
Cisco Public
1
Which routing protocol is better?
Which routing protocol should I use in my
network?
Should I switch from the one I’m using?
IPv4
Ends
Merge
RST-3210 IPv6
11048_05_2005_X2© 2008 Cisco Systems,
© 2005
Cisco
Systems,
Inc. All rights reserved.
Inc.
All rights
reserved.
Cisco Public
22
The Questions
 Is one routing protocol better
than any other protocol?
 Define “Better!”
 Uses less resources?
 Easier to troubleshoot?
 Both are good choices
 Cisco offers full-featured
implementations of both today
 Cisco EIGRP/OSPF
deployment in the enterprise is
~50/50 today
© 2008 Cisco Systems, Inc. All rights reserved.
 Converges faster?
Cisco Public
 Easier to configure?
 Scales to a larger number of
routers, routes, or neighbors?
 More flexible?
 …
3
The Questions
 The answer is yes if:
The network is complex
enough to “bring out” a
protocol’s specific advantages
You can define a specific
feature (or set of features) that
will benefit your network
tremendously…
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
4
The Questions
 But, then again, the
answer is no! 
 Every protocol has
some features and not others,
different scaling
properties, etc.
 Let’s consider some specific
topics for each protocol....
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
5
EIGRP or OSPF: Which Routing Protocol?
 Link State & Distance Vector
 Convergence Speed
 Topology and Heirarchy
 Summary
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
6
Link State & Distance Vector
 Link state
• OSPF is an example
• Each router tells the world about its neighbors
• All information passed is connectivity related
• Each node in the network constructs a connectivity map of the network
• Each node keeps identical link-state database from which routing table is
derived
• More complex than distance vector protocols
 Distance vector
• EIGRP is an example (but does not behave like a “pure” DV protocol)
• Each router tells its neighbors about its world
• Each node shares its routing table with its neighbors
• Simpler than link state protocols
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
7
Convergence Speed
 Equal Cost Convergence
 OSPF Convergence
 EIGRP Convergence
 Convergence Summary
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
8
Convergence Speed
 Which protocol converges faster?
 OSPF verses EIGRP
Is DUAL faster, or Dijkstra SPF?
 Rules of Thumb
The more routers involved in convergence, the slower convergence will
be
The more routes involved in convergence, the slower convergence will
be
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
9
Convergence Speed
 Three steps to convergence
Detect the failure
Calculate new routes around the topology change
Add changed routing information to the routing table
 The first and third steps are similar for any routing
protocol, so we’ll focus on the second step
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
10
Equal Cost
 Start with B>C>E and B>D>E
being equal cost
A
 If C fails, B and E can shift from
sharing traffic between C and D to
sending traffic to D only
 Number of routers involved in
convergence: 2 (B and E)
B
C
D
 Convergence time is in the
milliseconds
E
F
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
11
OSPF
 C fails
 B and E flood new topology
information
A
 All routers run SPF to
calculate new shortest paths
through the network
B
SPF
 B and E change their routing
tables to reflect the changed
topology
 Number of routers involved in
convergence: 2 (B and E)
C
SPF
D
E
F
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
12
OSPF
 Within a single flooding domain (OSPF area)
 Convergence time depends on flooding timers, SPF
timers, and number of nodes/leaves in the SPF tree
 What happens when we cross a flooding domain
boundary?
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
13
OSPF
 E floods topology changes to
C and D
A
 C and D summarize these
topology changes and flood it
to B
 B builds a summary from the
summary flooded to B, and
floods it into area 2
Area 2
B
Area 0
C
D
 A calculates a route to B, then
recurses C onto B
E
 Convergence time is
dependent on the network
design
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
Area 1
F
14
OSPF– Convergence Data
2.500
2.000
 Convergence time with default
timers and tuned timers
Time
IPv4 OSPF
1.500
IPv6 OSPF
1.000
Linear (IPv4
OSPF)
Linear (IPv6
OSPF)
0.500
 IPv4 and IPv6 IGP convergence
times are similar
- The IPv6 IGP implementations
0.000
0
500
1000
1500
2000
2500
3000
Number of Prefixes
Time
might not be fully optimized yet
- Not all Fast Convergence
optimizations might be available
0.5
0.45
0.4
0.35
0.3
0.25
0.2
0.15
0.1
0.05
0
IPv4 OSPF
IPv6 OSPF
Linear (IPv6
OSPF)
Linear (IPv4
OSPF)
0
500
1000
1500
2000
2500
3000
Number of Prefixes
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
All specifications subject to change without notice
15
OSPF
 Within a flooding domain
The average convergence time, with default timers, is on the order of
seconds
With optimal SPF/LSA timers, the convergence time can be in the
milliseconds
 Outside the flooding domain
Network design and route aggregation are the primary determining
factors of convergence speed
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
16
EIGRP
A
10
 DUAL works on a simple
geometric principle:
If my neighbor’s cost (RD) to
reach a given destination is less
than my best cost (FD), then the
alternate path (FS) cannot be a
loop
30
35
B
10
15
C
D
10
10
20
E
 B>D>E>F is 35
10
 B>C>E>F is 30
 D>E>F is 20, which is less
than the best path, 30, so
B>D>E>F cannot be a loop
 FC Rule: Choose FS for path
where RD<FD
F
 FD = Feasible Distance
 RD = Reported Distance
 FC = Feasibility Condition
 FS = Feasible Successor
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
17
EIGRP
 B will install the path through
C, and mark the path through
D as a Feasible Successor
(FS) in the topology table
 When C fails, B looks for
alternate loop free paths (FS)
A
10
B
10
15
 Finding one, it installs it
 Local repair, no flooding
 Convergence time is in the
milliseconds
 Number of routers involved in
convergence: 2 (B and E)
C
D
10
10
E
10
F
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
18
EIGRP
 If the second path cannot be
proven loop free
A
 B and E detect the failure, and
have no alternate path
B
 B queries A and D
A replies that it has no path
D replies with its alternate path
C
D
 E queries D and F
F replies that it has no path
E
D replies with its alternate path
 Hop-by-hop queries; no flooding
F
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
19
EIGRP
 For paths with feasible successors, convergence time is in the
milliseconds
The existence of feasible successors is dependent on the network
design
 For paths without feasible successors, convergence time is
dependent on the number of routers that have to handle and reply
to the query
Query range is dependent on network design
 Good design is the key to fast convergence in an EIGRP network
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
20
Convergence Summary
 We can sort typical convergence times into three
groups:
Best
EIGRP with a feasible successor
OSPF with modified SPF/LSA throttle timers
EIGRP without a feasible successor and good design
OSPF with default timers
EIGRP without a feasible successor without good design
Good
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
21
Convergence Summary
 It’s possible to converge in under one second using
either protocol, with the right network design
 Rules of Thumb:
More aggregation tends towards better performance for EIGRP
Less aggregation tends towards better performance for OSPF
If you’re going to use OSPF, tune the SPF/LSA timers
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
22
Topology
 Hub and Spoke
 Full Mesh
 Support for Hierarchy
 Topology Summary
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
23
OSPF Hub and Spoke
 OSPF relies on every router within a flooding domain to
have the exact same view of the network’s topology
(link state database) to calculate loop free paths
 OSPF flooding rules have implications for scaling and
design in hub and spoke networks
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
24
OSPF Hub and Spoke
 Although B can only reach C
through A, it still receives all of
C’s routing information
 As the number of remote sites
increases, the amount of
information each remote site
must process and store also
increases
A
D
B
 This limits scaling in link state
hub and spoke networks
C
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
reachability
only
through A
all link state
information
is flooded
to B
25
OSPF Hub and Spoke
 Controlling route distribution
10.1.1.0/24
 There’s no way to allow C and
D to receive information about
10.1.1.0/24, and not E and F
Area 0
A
B
F
E
Area 1
D
C
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
26
EIGRP Hub and Spoke
 If A loses its connection to
10.1.1.0/24, it builds and
transmits five queries: one to
each remote, and one to B
10.1.1.0/24
 Controlling query range
A
B
 Each of the remote sites will
query B
 B must process and reply to
five queries
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
27
 If these spokes are remotes
sites, they have two
connections for resiliency, not
so they can transit traffic
between A and B
10.1.1.0/24
EIGRP Hub and Spoke
A
B
 A should never use the spokes
as a path to anything, so
there’s no reason to learn
about, or query for, routes
through these spokes
Don’t Use
These Paths
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
28
 To signal A and B that the
paths through the spokes
should not be used, the spoke
routers can be configured as
EIGRP stubs
10.1.1.0/24
EIGRP Hub and Spoke
A
B
router#config t#
router(config)#router eigrp 100
router(config-router)#EIGRP stub connected
router(config-router)#
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
29
 Marking the spokes as stubs
allows them to signal A and B
that they are not valid transit
paths
 A simply will not query the
remotes, reducing the total
number of queries in this
example to 1
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
10.1.1.0/24
EIGRP Hub and Spoke
A
B
30
 Marking these remotes
as stubs also reduces
the topological complexity
(meshiness) of the network
 Without stub configuration on
spokes, B believes it has five
paths to 10.1.1.0/24,
so it has to maintain
five topology table entries
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
10.1.1.0/24
EIGRP Hub and Spoke
A
B
31
 Routers which are configured
as EIGRP stubs will only
advertise locally connected or
redistributed destinations
 These remotes will not pass
A’s advertisement of
10.1.1.0/24 to B
10.1.1.0/24
EIGRP Hub and Spoke
A
B
 B will only have one path to
10.1.1.0/24
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
32
Full Mesh
 Full mesh topologies are
complex:
2 routers = 1 link
3 routers = 3 links
4 routers = 6 links
5 routers = 10 links
6 routers = 15 links
…
 Adjacencies = links(links-1)/2
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
33
OSPF Full Mesh
 Flooding routing information
through a full mesh topology is
also complicated
 Each router will, with optimal
timing, receive at least one
copy of every new piece of
information from each
neighbor on the full mesh
 OSPF uses notion of
Designated Router (DR) to
improve scalability in mesh
networks
New Information
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
34
EIGRP Full Mesh
 Routes must be advertised
between every pair of peers in
the mesh so each router has
the correct next hop and
routing information
Summarize
Summarize
Summarize
Summarize
Summarize
 Number the links so they can
be summarized to a single
advertisement at the edge
 Good for smaller mesh
networks, summarization more
important for larger mesh
networks
Summarize
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
35
OSPF Support for Hierarchy
 Summarization and filtering
occur at flooding domain
borders
Summarization and filtering can
also be configured at routers
redistributing routes into OSPF
Summarization
 OSPF requires a hierarchical
design
area 0
 In a two layer hierarchy, the
flooding domain border
naturally lies on the
aggregation/core boundary
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
36
EIGRP Support for Hierarchy
 Auto-summarization enabled
by default at classful network
boundaries
 EIGRP enables you to
summarize at any desired
boundary
 Proper network design is still
needed!
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
Core
Distribution
Access
Summarization
 EIGRP does not require a
heirarchical design
37
Topology Summary
 Rules of Thumb
EIGRP performs better in large scale hub and spoke
environments
OSPF perform better in large full mesh environments, if tuned
correctly
EIGRP tends to perform better in more strongly hierarchical
network models, OSPF in flatter networks
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
38
Other Considerations - 1
 EIGRP forms adjacencies and exchanges routing updates with
neighbors
 OSPF forms adjacencies with DR/BDR
OSPF can be more efficient than EIGRP for large meshed networks
 EIGRP uses metric based on bandwidth and delay
 OSPF uses interface cost (inversely proportional to bandwidth)
EIGRP may provide more flexibility in selecting best path
 EIGRP by default limits usage to at most 50% of link bandwidth in
worst case
 OSPF uses 100% of link bandwidth when required
EIGRP may be better suited for lower bandwidth WAN applications
 EIGRP provides feature velocity, but is Cisco-proprietary
 OSPF is an Internet RFC standard
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
39
Other Considerations - 2
 EIGRP sends hop-by-hop queries only when Feasible Successor
cannot be found
 OSPF regularly syncs LSA database and floods network with topology
change
EIGRP can be more efficient by minimizing routing information exchanged
 EIGRP is a conceptually simpler routing protocol
 OSPF’s rules for different types of areas and LSAs can be
conceptually more difficult to understand
Some customers believe EIGRP is easier to implement, but both are
feature-rich and scalable
 EIGRP supports automatic summarization
 OSPF’s requires manual summarization
Care is needed in either case to ensure proper summarization!
 EIGRP supports both equal and unequal cost load sharing
 OSPF only supports equal cost load sharing
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
40
Summary
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
41
Which routing protocol is better?
Which routing protocol should I use in my network?
Should I switch from the one I’m using?
Did we answer these questions???
IPv4
Ends
Merge
RST-3210 IPv6
11048_05_2005_X2© 2008 Cisco Systems,
© 2005
Cisco
Systems,
Inc. All rights reserved.
Inc.
All rights
reserved.
Cisco Public
42
42
Summary
 There is no “right” answer!
 “IT DEPENDS…”
 Consider:
Your business requirements
Your network design & topology
Convergence time requirements dictated by your applications
Other intangible factors
 EIGRP and OSPF are generally pretty close in
capabilities and development (GR, BFD, IPv4/IPv6)
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
43
Summary
Rules of Thumb
Large
Mesh
Flat
Hub and
Spoke
Hierarchical
OSPF
EIGRP
Flat
Complex
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
Aggregated
Simpler
44
© 2008 Cisco Systems, Inc. All rights reserved.
Cisco Public
45