Skip to Content
Cisco IOS Cookbook, 2nd Edition
book

Cisco IOS Cookbook, 2nd Edition

by Kevin Dooley, Ian Brown
December 2006
Intermediate to advanced
1188 pages
72h 8m
English
O'Reilly Media, Inc.
Content preview from Cisco IOS Cookbook, 2nd Edition

Redistributing External Routes into OSPF

Problem

You want OSPF to distribute routes from another routing protocol.

Solution

The redistribute configuration command allows you to redistribute routes from another dynamic routing protocol into an OSPF process:

Router1#configure terminal 
Enter configuration commands, one per line.  End with CNTL/Z.
Router1(config)#router ospf 55
Router1(config-router)#redistribute eigrp 11 subnets   
Router1(config-router)#exit
Router1(config)#end
Router1#

One of the dangers when redistributing between routing protocols is that you will accidentally import more information than your routers can handle. In Version 12.3(2)T, Cisco added a feature to protect against this issue:

Router1#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Router1(config)#router ospf 55
Router1(config-router)#redistribute eigrp 11 subnets   
Router1(config-router)#redistribute maximum-prefix 1000 80
Router1(config-router)#exit
Router1(config)#end
Router1#

Discussion

Redistributing external routes from another routing protocol is similar to redistributing static routes, as we did in Recipe 8.5. In the example above, all of the routes that this router learns through EIGRP process number 11 will be propagated into OSPF as Type 2 external routes. Also, as shown in the following output from the show ip protocols command, because we also included the subnets keyword, every route will be redistributed. If we had not included this keyword, OSPF would only redistribute ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

IP Routing on Cisco IOS, IOS XE, and IOS XR: An Essential Guide to Understanding and Implementing IP Routing Protocols

IP Routing on Cisco IOS, IOS XE, and IOS XR: An Essential Guide to Understanding and Implementing IP Routing Protocols

Brad Edgeworth, Aaron Foss, Ramiro Garza Rios
Cisco Software-Defined Access

Cisco Software-Defined Access

Srilatha Vemula, Jason Gooley, Roddie Hasan

Publisher Resources

ISBN: 0596527225Supplemental ContentErrata Page