Putting It All Together
Problem
You want to combine all of best the elements in this chapter to create a good redundant ISP connection.
Solution
For simplicity, we will extend the single router dual ISP configuration of Recipe 9.4 rather than the dual router dual ISP example of Recipe 9.5. It should be clear from the discussion in Recipe 9.5 how to extend this example to the two-router case:
Router1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z. Router1(config)#interface
Router1(config-if)#
Serial0
description
Router1(config-if)#
connection to ISP #1, ASN 65510
ip address
Router1(config-if)#
192.168.1.6 255.255.255.252
exit
Router1(config)#interface
Router1(config-if)#
Serial1
description
Router1(config-if)#
connection to ISP #2, ASN 65520
ip address
Router1(config-if)#
192.168.2.6 255.255.255.252
exit
Router1(config)#interface
Router1(config-if)#
Ethernet0
description
Router1(config-if)#
connection to internal network, ASN 65500
ip address
Router1(config-if)#
172.18.5.2 255.255.255.0
exit
Router1(config)#ip as-path access-list
15
permit
Router1(config)#
^$
ip route
Router1(config)#
0.0.0.0 0.0.0.0 192.168.101.0 1
ip route
Router1(config)#
0.0.0.0 0.0.0.0 192.168.102.0 2
ip prefix-list
CREATE-DEFAULT
seq
10
permit
Router1(config)#
192.168.101.0/24
ip prefix-list
CREATE-DEFAULT
seq
20
permit
Router1(config)#
192.168.102.0/24
ip prefix-list
BLOCK-DEFAULT
seq
10
permit
0.0.0.0/0
ge
Router1(config)#
1
route-map
PREPEND
permit
Router1(config-route-map)#
10
set as-path prepend ...
Get Cisco IOS Cookbook, 2nd Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.