===== Cisco IOS OSPF Redistribution =====
{{tag>Cisco IOS Routing}}
Start OSPF configuration:
!
router ospf 10
router-id 10.20.0.1
passive-interface FastEthernet0/0.101
passive-interface FastEthernet0/0.102
!
\\
Outside interface configuration:
!
interface FastEthernet0/0
description Outside
no ip address
no mop enabled
!
interface FastEthernet0/0.101
description Internet-1
encapsulation dot1Q 101
ip address 50.123.234.66 255.255.255.248
!
interface FastEthernet0/0.102
description Internet-2
encapsulation dot1Q 102
ip address 60.234.123.130 255.255.255.248
!
\\
Inside interface configuration with OSPF areas:
!
interface FastEthernet0/1
description Inside
no ip address
no mop enabled
!
interface FastEthernet0/1.200
description PrivateWAN
encapsulation dot1Q 200
ip address 10.20.0.1 255.255.255.0
ip ospf 10 area 0.0.0.0
!
interface FastEthernet0/1.201
description Lan1
encapsulation dot1Q 201
ip address 10.20.1.1 255.255.255.0
ip ospf 10 area 0.0.0.201
!
interface FastEthernet0/1.202
description Lan2
encapsulation dot1Q 202
ip address 10.20.2.1 255.255.255.0
ip ospf 10 area 0.0.0.202
!
\\
IPs used for VPN configured and set to be redistributed and summarized via OSPF:
!
ip local pool iplp-vpn1 10.20.128.17 10.20.128.30
ip local pool iplp-vpn2 10.20.128.33 10.20.128.46
!
ip access-list standard ACL_OSPF_Distribute
permit 10.20.128.16 0.0.0.15
permit 10.20.128.32 0.0.0.15
!
route-map RMap_OSPF_Distibute permit 10
match ip address ACL_OSPF_Distribute
!
router ospf 10
redistribute connected subnets route-map RMap_OSPF_Distibute
redistribute static subnets route-map RMap_OSPF_Distibute
summary-address 10.20.128.16 255.255.255.240
summary-address 10.20.128.32 255.255.255.240
!