Friday, April 25, 2014

OSPF Neighbors at Different Subnets!!

Yesterday we had many challenges at facebook Group about different Cisco IGPs Cases , and one them was about configuring OSPF neighbors but in different subnets, so the only Case i Knew According to RFC2328 was Point-to-Point connection using ip unnumbered and virtual links, that's always works fine .

But what about multi-access interfaces e.g: fastethernet ?!! That was a bit confusing at the beginning but i had to go for a workaround solution which PPPOE + ip unnumbered which worked like a magic :D

So As usual we will use our simple Topology with two routers with R1 as PPPOE server and R2 as PPPOE Client:
R1 ==> fa0/0 ==> IP address should be 10.10.10.1/24
R2 ==> fa0/0 ==> IP address should be 20.20.20.20/24



So I will move These IPs to Loopback 0 in Both Routers and We will Start from There.

R1 (PPPOE Server):

R1(config)#int fa0/0
R1(config-if)#no ip add

R1(config)#int lo0
R1(config-if)#ip add 10.10.10.1 255.255.255.0
R1(config-if)#interface virtual-template 1
R1(config-if)# ip unnumbered Loopback0
R1(config)#bba-group pppoe MyGroup
R1(config-bba-group)#virtual-template 1

R1(config)# int fa0/0
R1(config-if)#pppoe enable group MyGroup
R1(config-if)# no shut



R2 (PPPOE Client):

R2(config)#int fa0/0
R2(config-if)#no ip add

R2(config)#int lo0
R2(config-if)#ip add 20.20.20.20 255.255.255.0

R2(config)#int di1
R2(config-if)#ip unnumbered Loopback0
R2(config-if)#encap ppp
R2(config-if)#mtu 1492
R2(config-if)#dialer pool 1
R2(config-if)#dialer persistent
R2(config-if)#int fa0/0
R2(config-if)# pppoe-client dial-pool-number 1
R2(config-if)#do debug pppoe pack
R2(config-if)# no shut
R2(config-if)#
*Apr 25 16:11:18.003: %LINK-3-UPDOWN: Interface Dialer1, changed state to up

R2(config-if)#
*Apr 25 16:11:28.111: pppoe_send_padi:
contiguous pak, size 60
         FF FF FF FF FF FF CA 01 0D 84 00 08 88 63 11 09
         00 00 00 10 01 01 00 00 01 03 00 08 5C 00 00 01
         00 00 08 90 00 00 00 00 00 00 00 00 00 00 00 00
         00 00 00 00 00 00 00 00 00 00 00 00
*Apr 25 16:11:28.143: PPPoE 0: I PADO  R:ca00.0d84.0008 L:ca01.0d84.0008 Fa0/0
contiguous pak, size 62
         CA 01 0D 84 00 08 CA 00 0D 84 00 08 88 63 11 07
         00 00 00 2A 01 01 00 00 01 03 00 08 5C 00 00 01
         00 00 08 90 01 02 00 02 52 31 01 04 00 10 71 77
         0C 36 9F 78 B7 3E 8A DB E7 12 C4 3A 95 89
R2(config-if)#
*Apr 25 16:11:30.159: OUT PADR from PPPoE Session
contiguous pak, size 62
         CA 00 0D 84 00 08 CA 01 0D 84 00 08 88 63 11 19
         00 00 00 2A 01 01 00 00 01 03 00 08 5C 00 00 01
         00 00 08 90 01 02 00 02 52 31 01 04 00 10 71 77
         0C 36 9F 78 B7 3E 8A DB E7 12 C4 3A 95 89
*Apr 25 16:11:30.271: PPPoE 2: I PADS  R:ca00.0d84.0008 L:ca01.0d84.0008 Fa0/0
contiguous pak, size 62
         CA 01 0D 84 00 08 CA 00 0D 84 00 08 88 63 11 65
         00 02 00 2A 01 01 00 00 01 03 00 08 5C 00 00 01
         00 00 08 90 01 02 00 02 52 31 01 04 00 10 71 77
         0C 36 9F 78 B7 3E 8A DB E7 12 C4 3A 95 89
*Apr 25 16:11:30.299: %DIALER-6-BIND: Interface Vi1 bound to profile Di1
*Apr 25 16:11:30.311: %LINK-3-UPDOWN: Interface Virtual-Access1, changed state to up
R2(config-if)#
*Apr 25 16:11:30.423: %LINEPROTO-5-UPDOWN: Line protocol on Interface Virtual-Access1, changed state to up
R2(config-if)#


It looks fine so far, so let's add Lo100 and Lo200 at both R1 and R2 and let's show the interfaces IPs:


R1#sh ip int br | ex una
Interface                  IP-Address      OK? Method Status                Protocol
Loopback0                  10.10.10.1      YES manual up                    up
Loopback100                100.100.100.100 YES manual up                    up
Virtual-Access2.1          10.10.10.1      YES unset  up                    up
Virtual-Template1          10.10.10.1      YES unset  down                  down


R2#sh ip int br | ex una
Interface                  IP-Address      OK? Method Status                Protocol
Dialer1                    20.20.20.20     YES TFTP   up                    up
Loopback0                  20.20.20.20     YES manual up                    up
Loopback200                200.200.200.200 YES manual up                    up



Now Let's test the connection between R1 and R2:

R1#ping 20.20.20.20
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 20.20.20.20, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 72/94/120 ms




So let's go for ospf config Between Both of them:


R1#sh run | se router ospf
router ospf 1
 network 0.0.0.0 255.255.255.255 area 0

R2#sh run | se router ospf
router ospf 1
 network 0.0.0.0 255.255.255.255 area 0



R2(config-router)#
*Apr 25 16:18:08.003: %OSPF-5-ADJCHG: Process 1, Nbr 10.10.10.1 on Dialer1 from LOADING to FULL, Loading Done

R2(config-router)#do sh ip os nei

Neighbor ID     Pri   State           Dead Time   Address         Interface
10.10.10.1        0   FULL/  -        00:00:31    10.10.10.1      Dialer1



R2(config-router)#do sh ip route os
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
       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 route, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      100.0.0.0/32 is subnetted, 1 subnets
O        100.100.100.100 [110/1786] via 10.10.10.1, 00:01:02, Dialer1



So let's test End to End Reachability :


R2(config-router)#do ping 100.100.100.100 so lo0
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 100.100.100.100, timeout is 2 seconds:
Packet sent with a source address of 20.20.20.20
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 72/88/128 ms
R2(config-router)#


Awesome Right !!! :D :D








No comments:

Post a Comment