04-28-2022 12:10 PM
Hello,
R15 is advertising its loopback0 15.15.15.15. R16 is redistributing routes received from R15. Similarly R17 and R18 are also redistributed routes received from neighbor.I have posted the configuration of all the routers. On R16, I expect 15.15.15.15 as an intra area route. but I see 15.15.15.15 as an External route. And if I ping 15.15.15.15 from R16 ping goes to R17 ->R18 -> R15. I am not sure why external route is preferred on intra-area route on R1.
RP/0/0/CPU0:ios#show route ospf
Thu Apr 28 19:07:37.789 UTC
O E2 15.15.15.15/32 [110/1] via 100.160.170.17, 00:15:36, GigabitEthernet0/0/0/1
R17---------------R16-------R15
| |
| |
|_______________R18______ __|
xrv15
------
int gi0/0/0/0
ip address 100.150.160.15 255.255.255.0
no sh
int gi0/0/0/1
ip address 100.150.180.15 255.255.255.0
no sh
int lo0
ip address 15.15.15.15 255.255.255.255
router ospf 1
redistribute ospf 2
area 0
int gi0/0/0/0
int lo0
router ospf 2
redistribute ospf 1
area 0
int gi0/0/0/1
xrv16
-------------
int gi0/0/0/0
ip address 100.150.160.16 255.255.255.0
no sh
int gi0/0/0/1
ip address 100.160.170.16 255.255.255.0
no sh
int lo0
ip address 16.16.16.16 255.255.255.255
router ospf 1
redistribute ospf 2
area 0
int gi0/0/0/0
router ospf 2
redistribute ospf 1
area 0
int gi0/0/0/1
xrv17
-------------
int gi0/0/0/0
ip address 100.170.180.17 255.255.255.0
no sh
int gi0/0/0/1
ip address 100.160.170.17 255.255.255.0
no sh
int lo0
ip address 17.17.17.17 255.255.255.255
router ospf 1
redistribute ospf 2
area 0
int gi0/0/0/1
router ospf 2
redistribute ospf 1
area 0
int gi0/0/0/0
xrv18
-------------
int gi0/0/0/1
ip address 100.150.180.18 255.255.255.0
no sh
int gi0/0/0/0
ip address 100.170.180.18 255.255.255.0
no sh
int lo0
ip address 18.18.18.18 255.255.255.255
router ospf 1
redistribute ospf 2
area 0
int gi0/0/0/0
router ospf 2
redistribute ospf 1
area 0
int gi0/0/0/1
Thanks,
Sachin
Solved! Go to Solution.
04-28-2022 01:27 PM
Hi @sachin30720041 ,
This is expected behavior. The cost to 15.15.15.15 through ospf 1 is 2 and the cost through ospf 2 is 1. The intra area vs external type 2 doesn't come into play when routes are learnt via 2 ospf routing processes. Only the cost will be taken in consideration in this context. This is why the route via ospf 2 is preferred.
Regards,
04-28-2022 12:39 PM - edited 04-28-2022 01:50 PM
..
first check the Loopback is advertise as LAS5 or LSA1 ?
second refer to link and change distance.
04-28-2022 01:20 PM - edited 04-28-2022 01:21 PM
It seems to me that you configure all Router as ABR. This probably is causing this behavior.
04-28-2022 01:23 PM
15.15.15.15 are present in LSA-1 and LSA-5.
04-28-2022 01:27 PM
Hi @sachin30720041 ,
This is expected behavior. The cost to 15.15.15.15 through ospf 1 is 2 and the cost through ospf 2 is 1. The intra area vs external type 2 doesn't come into play when routes are learnt via 2 ospf routing processes. Only the cost will be taken in consideration in this context. This is why the route via ospf 2 is preferred.
Regards,
04-28-2022 01:45 PM
xrv16
-------------
int gi0/0/0/0
ip address 100.150.160.16 255.255.255.0 <- not same subnet !!!
no sh
router ospf 1
redistribute ospf 2
area 0
int gi0/0/0/0
xrv17
-------------
int gi0/0/0/1
ip address 100.160.170.17 255.255.255.0 <- not same subnet !!!
no sh
router ospf 1
redistribute ospf 2
area 0
int gi0/0/0/1
Misconfig the interface and router OSPF process
04-28-2022 01:54 PM
can I see show ospf interface for all router ?
04-28-2022 01:54 PM
HI @MHM Cisco World ,
xrv16 and xrv17 do share a common subnet.
xrv16
-------------
int gi0/0/0/1
ip address 100.160.170.16 255.255.255.0
xrv17
-------------
int gi0/0/0/1
ip address 100.160.170.17 255.255.255.0
Regards,
04-28-2022 01:58 PM
@Harold Ritter but the OSPF process 1 have different interface !!!! i.e. the subnet between router is same but each side use different OSPF process.!!!!
04-28-2022 02:03 PM
That is not really what is at stake here. The original poster is asking why R16 prefers the E2 over the intra area route. Fixing what you pointed out will not change the outcome of why R16 prefers the E2.
Regards,
04-28-2022 02:09 PM
Lo is LSA5 not LSA1 so Lo is redistribute to this router not learn direct as intra-area.
after we fix this issue router will prefer intra-area because it cost "one link between R16 and R15" than "R17-R18-R15".
04-28-2022 02:18 PM - edited 04-28-2022 02:28 PM
Hi @MHM Cisco World ,
Intra area cost for 15.15.15.15 on R16 is 2 (1 for link between R16 and R15 and 1 for lo0). The E2 routes has a cost of 1 (external cost) as it is E2 it will not consider the internal cost. If these two routes where learnt via one ospf process the intra area would be preferred, but as they are learnt via two ospf processes, the intra area vs E2 does not come into play.
Regards,
04-28-2022 02:23 PM - edited 04-28-2022 02:23 PM
also router with two interface and run two different process one for each interface , how this work?
He design lab and we must guide him to right design.
04-28-2022 02:40 PM
> also router with two interface and run two different process one for each interface , how this work?
It works because of the redistribution between ospf 1 and ospf 2 on each and every router.
> He design lab and we must guide him to right design.
I believe the goal of the original poster is simply to experiment with different things. Feel free to provide guidance and recommendations.
Regards,
04-28-2022 02:45 PM
@Harold Ritter @sachin30720041
R1-OSPF2-R2-OSPF1-R3-OSPF2 ....etc. are this work ???
He must config two process OSPF 1 and OSPF 2 and there is ASBR in boundary between the two process
other routers inside Area of OSPF 1 must run one process not all router is boundary and behave like ASBR.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide