12-06-2022 01:10 PM
Attached topology. All routers interfaces are part of the same /24 & area 0.
1.1.1.1/32 is adv. from both R1 & R4. Is there a way I can influence R5 to prefer R1 over R4?
12-07-2022 08:35 AM
Hi @tlxbx ,
You are absolutely right. The revised access-list is the proper way to go.
Regards,
12-07-2022 08:10 AM
Perhaps:
route-map test deny 10
match ip address prefix-list prefix1
match ip next-hop prefix-list nh1
route-map test permit 20
!or
route-map test permit 10
match ip address prefix-list prefix1
match ip next-hop prefix-list nh1
set metric 32000
route-map test permit 20
The latter possibly supporting the "auto" fail-over @Harold Ritter suggested as a good thing (which often it is).
12-07-2022 08:24 AM - edited 12-07-2022 08:25 AM
Tried below & nothing changed.
route-map test permit 10
ip prefix-list nh1 seq 5 permit 192.168.0.1/32
!
ip prefix-list prefix1 seq 5 permit 1.1.1.1/32
!
route-map test permit 10
match ip address prefix-list prefix1
match ip next-hop prefix-list nh1
set metric 32000
!
route-map test permit 20
router ospf 1
log-adjacency-changes
network 0.0.0.0 255.255.255.255 area 0
distribute-list route-map test in
**********
R5#sh ip route os
1.0.0.0/32 is subnetted, 1 subnets
O 1.1.1.1 [110/2] via 192.168.0.4, 00:00:01, FastEthernet0/0
[110/2] via 192.168.0.1, 00:00:01, FastEthernet0/0
12-07-2022 11:44 AM - edited 12-07-2022 02:05 PM
Did you try first alternative?
PS:
I.e.:
route-map test deny 10
match ip address prefix-list prefix1
match ip next-hop prefix-list nh1
route-map test permit 20
12-07-2022 09:10 AM - edited 12-07-2022 11:47 AM
Hi @Joseph W. Doherty ,
Option 2 would have been a good idea, but the "distribute-list with route-map" feature doesn't allow to change anything on the route. Only the match statement will be taken in consideration. The set statement will be ignored.
Regards,
12-07-2022 02:03 PM
BTW, found this "working [?] example" of using a "set" with an OSPF distribute-lise: https://docs.ruckuswireless.com/fastiron/08.0.60/fastiron-08060-l3guide/GUID-EB1339A2-5DCB-41D0-A215-F3A9D69174D9.html
12-07-2022 02:39 PM - edited 12-07-2022 02:52 PM
Hi @Joseph W. Doherty ,
It definitely looks like IOS, but it is not. FastIron is an NOS from Ruckus, which is a competitor.
Regards,
12-06-2022 04:30 PM
I completely agree @Joseph W. Doherty . Sometimes the solution might be cumbersome than the problem itself.
Regards,
12-06-2022 06:13 PM
Thank you both for your input. I'd still like to complete it at least in a lab environment. If nothing else it will solidify my OSPF understanding
12-07-2022 02:47 AM
we can play with cost in two case
P2P
P2M
here we have broadcast, so only we change the network type to P2M to solve the problem
then
neighbor x.x.x.x cost <value>
this make R3 prefer either R1 or R2 for prefix Lo 1.1.1.1
12-07-2022 06:28 AM
Thank you. Can you do a lab with distribute-list as it didn't work for me?
It would look something like the following:
route-map test permit 10
match ip address prefix-list prefix1
match ip next-hop prefix-list nh1
!
ip prefix-list nh1 seq 5 permit <nexthop to R1>
ip prefix-list prefix1 seq 5 permit 1.1.1.1/32
!
router ospf xxx
distribute-list route-map test in
Regards,
12-07-2022 06:33 AM - edited 12-07-2022 06:35 AM
I am out now, but from my experience distrubte-list not work at all for this case , as @Harold Ritter mention before.
12-07-2022 06:51 AM
Hi @tlxbx ,
Have you been able to test the following configuration, which might be compatible with the IOS version you run.
access-list 199 permit ip host 192.168.0.1 host 1.1.1.1
router ospf 1
distribute-list 199 in
Regards
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