Dynamic Multipoint VPN [OSPF]
- R1(config)# interface Tunnel0
-
- ip address 172.16.134.1 255.255.255.0
- no ip redirects
- ip mtu 1400
- ip nhrp authentication cisco123
- ip nhrp map multicast dynamic
- ip nhrp network-id 123
- tunnel source FastEthernet0/0
- tunnel mode gre multipoint
- R3(config)# interface Tunnel0
-
- ip address 172.16.134.3 255.255.255.0
- ip mtu 1400
- ip nhrp authentication cisco123
- ip nhrp map 172.16.134.1 10.1.12.1
- ip nhrp network-id 123
- ip nhrp nhs 172.16.134.1
- tunnel source FastEthernet0/0
- tunnel destination 10.1.12.1
- R4(config)# interface Tunnel0
-
- ip address 172.16.134.4 255.255.255.0
- ip mtu 1400
- ip nhrp authentication cisco123
- ip nhrp map 172.16.134.1 10.1.12.1
- ip nhrp network-id 123
- ip nhrp nhs 172.16.134.1
- tunnel source FastEthernet0/0
- tunnel destination 10.1.12.1
- R1(config)# router ospf 1
-
- router-id 172.16.134.1
- network 1.1.1.1 0.0.0.0 area 0
- network 172.16.134.1 0.0.0.0 area 0
- R1(config)# interface Tunnel0
-
- ip ospf network point-to-multipoint // Remember for Phase 1 HUB should be OSPF Network of Point to Multipoint
- ip ospf hello-interval 10 // For Point to Multipoint, the Hello Timer gets changed to 40s. But since our spokes have 10s, we have to change this!
- R3(config)#router ospf 1
-
- router-id 172.16.134.3
- network 3.3.3.3 0.0.0.0 area 0
- network 172.16.134.3 0.0.0.0 area 0
- R3(config)#interface Tunnel0
-
- ip ospf network point-to-point // Spokes should be of OSPF network type Point to Point
- R4(config)#router ospf 1
-
- router-id 172.16.134.4
- network 4.4.4.4 0.0.0.0 area 0
- network 172.16.134.4 0.0.0.0 area 0
- R4(config)#interface Tunnel0
-
- ip ospf network point-to-point // Spokes should be of OSPF network type Point to Point
- R1(config)# crypto isakmp policy 10
-
- authentication pre-share
- R1(config)# crypto isakmp key cisco4 address 0.0.0.0 0.0.0.0
- R1(config)# crypto ipsec transform-set TSET esp-3des esp-sha-hmac
-
- mode transport
- R1(config)# crypto ipsec profile DMVPN
-
- set transform-set TSET
- R1(config)# interface Tunnel0
-
- tunnel protection ipsec profile DMVPN
- R3(config)# crypto isakmp policy 10
-
- authentication pre-share
- R3(config)# crypto isakmp key cisco3 address 0.0.0.0 0.0.0.0 // We cannot use peer ip address, because the OSPF adjacency will FAIL!
- R3(config)# crypto ipsec transform-set TSET esp-3des esp-sha-hmac
-
- mode transport
- R3(config)# crypto ipsec profile DMVPN
-
- set transform-set TSET
- R3(config)# interface Tunnel0
-
- tunnel protection ipsec profile DMVPN
- R4(config)# crypto isakmp policy 10
-
- authentication pre-share
- R4(config)# crypto isakmp key cisco4 address 0.0.0.0 0.0.0.0 // We cannot use peer ip address, because the OSPF adjacency will FAIL!
- R4(config)# crypto ipsec transform-set TSET esp-3des esp-sha-hmac
-
- mode transport
- R4(config)# crypto ipsec profile DMVPN
-
- set transform-set TSET
- R4(config)# interface Tunnel0
-
- tunnel protection ipsec profile DMVPN
R1#sh ip ospf neigh
Neighbor ID Pri State Dead Time Address Interface
172.16.134.3 0 FULL/DROTHER 00:00:32 172.16.134.3 Tunnel0
172.16.134.4 0 FULL/DROTHER 00:00:30 172.16.134.4 Tunnel0
1.0.0.0/32 is subnetted, 1 subnets
O 1.1.1.1 [110/11112] via 172.16.134.1, 00:09:21, Tunnel0
3.0.0.0/24 is subnetted, 1 subnets
C 3.3.3.0 is directly connected, Loopback0
4.0.0.0/32 is subnetted, 1 subnets
O 4.4.4.4 [110/22223] via 172.16.134.1, 00:09:02, Tunnel0
172.16.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 172.16.134.0/24 is directly connected, Tunnel0
O 172.16.134.1/32 [110/11111] via 172.16.134.1, 00:09:21, Tunnel0
10.0.0.0/24 is subnetted, 1 subnets
C 10.1.23.0 is directly connected, FastEthernet0/0
S* 0.0.0.0/0 [1/0] via 10.1.23.2
1.0.0.0/32 is subnetted, 1 subnets
O 1.1.1.1 [110/11112] via 172.16.134.1, 00:11:37, Tunnel0
3.0.0.0/32 is subnetted, 1 subnets
O 3.3.3.3 [110/22223] via 172.16.134.1, 00:11:37, Tunnel0
4.0.0.0/24 is subnetted, 1 subnets
C 4.4.4.0 is directly connected, Loopback0
172.16.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 172.16.134.0/24 is directly connected, Tunnel0
O 172.16.134.1/32 [110/11111] via 172.16.134.1, 00:11:37, Tunnel0
10.0.0.0/24 is subnetted, 1 subnets
C 10.1.24.0 is directly connected, FastEthernet0/0
S* 0.0.0.0/0 [1/0] via 10.1.24.2
172.16.134.3/32 via 172.16.134.3, Tunnel0 created 00:13:20, expire 01:46:39
Type: dynamic, Flags: unique registered
NBMA address: 10.1.23.3
172.16.134.4/32 via 172.16.134.4, Tunnel0 created 00:12:59, expire 01:47:00
Type: dynamic, Flags: unique registered
NBMA address: 10.1.24.4
172.16.134.1/32 via 172.16.134.1, Tunnel0 created 00:28:46, never expire
Type: static, Flags:
NBMA address: 10.1.12.1
172.16.134.1/32 via 172.16.134.1, Tunnel0 created 01:31:26, never expire
Type: static, Flags:
NBMA address: 10.1.12.1
IPv4 Crypto ISAKMP SA
dst src state conn-id slot status
10.1.12.1 10.1.24.4 QM_IDLE 1002 0 ACTIVE
10.1.12.1 10.1.23.3 QM_IDLE 1001 0 ACTIVE
4.4.4.4/32, version 37, epoch 0
0 packets, 0 bytes
via 172.16.134.1, Tunnel0, 0 dependencies
next hop 172.16.134.1, Tunnel0
valid adjacency
3.3.3.3/32, version 24, epoch 0
0 packets, 0 bytes
via 172.16.134.1, Tunnel0, 0 dependencies
next hop 172.16.134.1, Tunnel0
valid adjacency
Building configuration…
Current configuration : 351 bytes
!
interface Tunnel0
ip address 172.16.134.1 255.255.255.0no ip redirectsip mtu 1400ip nhrp authentication cisco123ip nhrp map multicast dynamicip nhrp network-id 123ip nhrp holdtime 360ip ospf network broadcast // The OSPF network has been changed to BROADCASTip ospf priority 255tunnel source FastEthernet0/0tunnel mode gre multipointtunnel protection ipsec profile DMVPN
R3#sh run int tun 0
Building configuration…Current configuration : 413 bytes
!
interface Tunnel0
ip address 172.16.134.3 255.255.255.0no ip redirectsip mtu 1400ip nhrp authentication cisco123ip nhrp map 172.16.134.1 10.1.12.1ip nhrp map multicast 10.1.12.1ip nhrp network-id 123ip nhrp holdtime 360ip nhrp nhs 172.16.134.1ip ospf network broadcast // The OSPF network has been changed to BROADCASTip ospf priority 0tunnel source FastEthernet0/0tunnel mode gre multipoint // Please note, before doing this you have to deconfigure the ‘tunnel destination’ commandtunnel protection ipsec profile DMVPN
Building configuration…Current configuration : 413 bytes
!
interface Tunnel0
ip address 172.16.134.4 255.255.255.0no ip redirectsip mtu 1400ip nhrp authentication cisco123ip nhrp map 172.16.134.1 10.1.12.1ip nhrp map multicast 10.1.12.1ip nhrp network-id 123ip nhrp holdtime 360ip nhrp nhs 172.16.134.1ip ospf network broadcast // The OSPF network has been changed to BROADCASTip ospf priority 0tunnel source FastEthernet0/0tunnel mode gre multipoint // Please note, before doing this you have to de-configure the ‘tunnel destination’ commandtunnel protection ipsec profile DMVPN
O 4.4.4.4 [110/11112] via 172.16.134.4, 00:13:19, Tunnel0 // OSPF learnt route has been updated to directly contact the SPOKE
3.0.0.0/32 is subnetted, 1 subnets
O 3.3.3.3 [110/11112] via 172.16.134.3, 00:15:23, Tunnel0 // OSPF learnt route has been updated to directly contact the SPOKE
3.3.3.3/32, version 30, epoch 0
0 packets, 0 bytes
via 172.16.134.3, Tunnel0, 0 dependencies
next hop 172.16.134.3, Tunnel0
invalid adjacency // Because it doesnt have the information of physical interface to reach 3.3.3.3. After pinging once, it will be updated!
4.4.4.4/32, version 31, epoch 0
0 packets, 0 bytes
via 172.16.134.4, Tunnel0, 0 dependencies
next hop 172.16.134.4, Tunnel0
invalid adjacency // Because it doesnt have the information of physical interface to reach 4.4.4.4. After pinging once, it will be updated!
Building configuration…
Current configuration : 351 bytes
!
interface Tunnel0
ip address 172.16.134.1 255.255.255.0no ip redirectsip mtu 1400ip nhrp authentication cisco123ip nhrp map multicast dynamicip nhrp network-id 123ip nhrp redirect // The extra command for Phase 3ip nhrp holdtime 360ip ospf network point-to-multipointtunnel source FastEthernet0/0tunnel mode gre multipointtunnel protection ipsec profile DMVPN
R3#sh run int tun 0
Building configuration…Current configuration : 413 bytes
!
interface Tunnel0
ip address 172.16.134.3 255.255.255.0no ip redirectsip mtu 1400ip nhrp authentication cisco123ip nhrp map 172.16.134.1 10.1.12.1ip nhrp map multicast 10.1.12.1ip nhrp network-id 123ip nhrp holdtime 360ip nhrp nhs 172.16.134.1ip nhrp shortcut // The extra command for Phase 3ip ospf network point-to-multipoint // The OSPF network has been changed to Point-to-Multipointip ospf priority 0tunnel source FastEthernet0/0tunnel mode gre multipoint // Please note, before doing this you have to deconfigure the ‘tunnel destination’ commandtunnel protection ipsec profile DMVPN
Building configuration…Current configuration : 413 bytes
!
interface Tunnel0
ip address 172.16.134.4 255.255.255.0no ip redirectsip mtu 1400ip nhrp authentication cisco123ip nhrp map 172.16.134.1 10.1.12.1ip nhrp map multicast 10.1.12.1ip nhrp network-id 123ip nhrp holdtime 360ip nhrp nhs 172.16.134.1ip nhrp shortcut // The extra command for Phase 3ip ospf network point-to-multipoint // The OSPF network has been changed to Point-to-Multipointip ospf priority 0tunnel source FastEthernet0/0tunnel mode gre multipoint // Please note, before doing this you have to de-configure the ‘tunnel destination’ commandtunnel protection ipsec profile DMVPN
Codes: C – connected, S – static, R – RIP, M – mobile, B – BGP
D – EIGRP, EX – EIGRP external, O – OSPF, IA – OSPF inter area
N1 – OSPF NSSA external type 1, N2 – OSPF NSSA external type 2
E1 – OSPF external type 1, E2 – OSPF external type 2
i – IS-IS, su – IS-IS summary, L1 – IS-IS level-1, L2 – IS-IS level-2
ia – IS-IS inter area, * – candidate default, U – per-user static route
o – ODR, P – periodic downloaded static routeGateway of last resort is 10.1.24.2 to network 0.0.0.04.0.0.0/24 is subnetted, 1 subnets
C 4.4.4.0 is directly connected, Loopback0
172.16.0.0/24 is subnetted, 1 subnets
C 172.16.134.0 is directly connected, Tunnel0
10.0.0.0/24 is subnetted, 1 subnets
C 10.1.24.0 is directly connected, FastEthernet0/0
S* 0.0.0.0/0 [1/0] via 10.1.24.2
Leave A Comment?