routing – Router on one side of a GRE tunnel not adding OSPF route through the tunnel whilst the router on the other side is

I have configured GRE tunnel between the Dublin and Carlow routers with the following commands:
//Carlow
int tunnel 0
ip address 172.16.12.1 255.255.255.252
tunnel source s0/0/0
tunnel destination 87.44.50.6
//Dublin
int tunnel 0
ip address 172.16.12.2 255.255.255.252
tunnel source s0/0/0
tunnel destination 87.44.50.2
The tunnel has a network address of 172.16.12.0/30 (Dublin = 172.16.12.2, Carlow = 172.16.12.1).
Pings are successful over the tunnel so I tried to configure OSPF to allow for routing between the LANs.
I used the following commands to configure OSPF:
//Carlow
router ospf 2
network 172.16.12.0 0.0.0.3 area 0
network 87.44.50.24 0.0.0.7 area 0
//Dublin
router ospf 2
network 172.16.12.0 0.0.0.3 area 0
network 87.44.50.16 0.0.0.7 area 0
The result from this configuration so far is that:
-
On the Carlow router, an OSPF route to 87.44.50.16 has been added via 172.16.12.1 (the tunnel interface on the Dublin router)
-
On the Dublin router, no OSPF routes have been added.
I will add in below the running configuration on each router for OSPf
Carlow:
router ospf 2
log-adjacency-changes
network 172.16.12.0 0.0.0.3 area 0
network 84.44.50.24 0.0.0.7 area 0
!
router ospf 1
log-adjacency-changes
network 87.44.50.4 0.0.0.3 area 0
Dublin:
router ospf 2
log-adjacency-changes
network 172.16.12.0 0.0.0.3 area 0
network 87.44.50.16 0.0.0.7 area 0
!
router ospf 1
log-adjacency-changes
network 87.44.50.0 0.0.0.3 area 0
As requested I will add in the full configuration and routing table for each router.
Carlow configuration
version 15.1
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname Router
!
no ip cef
no ipv6 cef
!
license udi pid CISCO2901/K9 sn FTX1524Z6TY-
!
spanning-tree mode pvst
!
interface Tunnel0
ip address 172.16.12.2 255.255.255.252
mtu 1476
tunnel source Serial0/0/0
tunnel destination 87.44.50.2
!
interface GigabitEthernet0/0
ip address 87.44.50.25 255.255.255.252
duplex auto
speed auto
!
interface GigabitEthernet0/1
no ip address
duplex auto
speed auto
shutdown
!
interface Serial0/0/0
ip address 87.44.50.6 255.255.255.252
clock rate 2000000
!
interface Serial0/0/1
no ip address
clock rate 2000000
shutdown
!
interface Vlan1
no ip address
shutdown
!
router ospf 2
log-adjacency-changes
network 172.16.12.0 0.0.0.3 area 0
network 84.44.50.24 0.0.0.7 area 0
!
router ospf 1
log-adjacency-changes
network 87.44.50.4 0.0.0.3 area 0
!
ip classless
ip route 0.0.0.0 0.0.0.0 87.44.50.5
!
ip flow-export version 9
!
line con 0
!
line aux 0
!
line vty 0 4
login
!
end
Carlow – routing table
Codes: L - local, 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, E - EGP
i - IS-IS, 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 route
Gateway of last resort is 87.44.50.5 to network 0.0.0.0
87.0.0.0/8 is variably subnetted, 5 subnets, 2 masks
C 87.44.50.4/30 is directly connected, Serial0/0/0
L 87.44.50.6/32 is directly connected, Serial0/0/0
O 87.44.50.16/30 [110/1001] via 172.16.12.1, 00:04:36, Tunnel0
C 87.44.50.24/30 is directly connected, GigabitEthernet0/0
L 87.44.50.25/32 is directly connected, GigabitEthernet0/0
172.16.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 172.16.12.0/30 is directly connected, Tunnel0
L 172.16.12.2/32 is directly connected, Tunnel0
S* 0.0.0.0/0 [1/0] via 87.44.50.5
Dublin – configuration
version 15.1
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname Router
!
no ip cef
no ipv6 cef
!
license udi pid CISCO2901/K9 sn FTX152479Q8-
license boot module c2900 technology-package securityk9
!
spanning-tree mode pvst
!
interface Tunnel0
ip address 172.16.12.1 255.255.255.252
mtu 1476
tunnel source Serial0/0/0
tunnel destination 87.44.50.6
!
interface GigabitEthernet0/0
ip address 87.44.50.17 255.255.255.252
duplex auto
speed auto
!
interface GigabitEthernet0/1
no ip address
duplex auto
speed auto
shutdown
!
interface Serial0/0/0
ip address 87.44.50.2 255.255.255.252
clock rate 2000000
!
interface Serial0/0/1
no ip address
clock rate 2000000
shutdown
!
interface Vlan1
no ip address
shutdown
!
router ospf 2
log-adjacency-changes
network 172.16.12.0 0.0.0.3 area 0
network 87.44.50.16 0.0.0.7 area 0
!
router ospf 1
log-adjacency-changes
network 87.44.50.0 0.0.0.3 area 0
!
ip classless
ip route 0.0.0.0 0.0.0.0 87.44.50.1
!
ip flow-export version 9
!
line con 0
!
line aux 0
!
line vty 0 4
login
!
end
Dublin – routing table
Codes: L - local, 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, E - EGP
i - IS-IS, 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 route
Gateway of last resort is 87.44.50.1 to network 0.0.0.0
87.0.0.0/8 is variably subnetted, 4 subnets, 2 masks
C 87.44.50.0/30 is directly connected, Serial0/0/0
L 87.44.50.2/32 is directly connected, Serial0/0/0
C 87.44.50.16/30 is directly connected, GigabitEthernet0/0
L 87.44.50.17/32 is directly connected, GigabitEthernet0/0
172.16.0.0/16 is variably subnetted, 2 subnets, 2 masks
C 172.16.12.0/30 is directly connected, Tunnel0
L 172.16.12.1/32 is directly connected, Tunnel0
S* 0.0.0.0/0 [1/0] via 87.44.50.1
Source link