4

I have a router running Cisco IOS XR with established L2 ISIS adjacency with a neighbor router. I would like to inject only the IPv4 address configured on loopback interface into the ISIS. The route for IPv4 address configured on Loopback0 can be seen below:

RP/0/RP0/CPU0:PE2#sh route 172.16.0.22/32
Sun Apr 18 20:13:11.393 UTC

Routing entry for 172.16.0.22/32
  Known via "local", distance 0, metric 0 (connected)
  Installed Apr 18 20:06:41.281 for 00:06:30
  Routing Descriptor Blocks
    directly connected, via Loopback0
      Route metric is 0
  Redist Advertisers:
    4 (protoid=4, clientid=21)

RP/0/RP0/CPU0:PE2#`

At first I tried with route-policy below:

RP/0/RP0/CPU0:PE2#sh run route-policy allow-lo 
Sun Apr 18 20:15:02.546 UTC
route-policy allow-lo
  if destination in (172.16.0.22/32) then
    done
  else
    drop
  endif
end-policy
!

RP/0/RP0/CPU0:PE2#

This route policy was configured under ISIS configuration:

RP/0/RP0/CPU0:PE2#sh run router isis 
Sun Apr 18 20:15:50.689 UTC
router isis lab
 is-type level-2-only
 net 49.0000.1720.1600.0022.00
 address-family ipv4 unicast
  redistribute connected route-policy allow-lo
 !
/* output removed for brevity */

As this did not seem to have affect, then I tagged the 172.16.0.22/32 route with tag 10 and tried with policy below:

RP/0/RP0/CPU0:PE2#sh run route-policy allow-lo 
Sun Apr 18 20:19:39.017 UTC
route-policy allow-lo
  if tag eq 10 then
    done
  else
    drop
  endif
end-policy
!

RP/0/RP0/CPU0:PE2#

Again, this had no affect. According to Cisco documentation destination and tag seem to be the two reasonable attributes with redistribution attach point for filtering routes.

How to restrict routes redistributed into ISIS in IOS XR?

2
  • 1
    Do you need to specify level-2 on your redistribute statement? Apr 18 at 22:17
  • 1
    Do you mean redistribute connected level-2 route-policy allow-lo? If yes, then this didn't work.
    – Martin
    Apr 19 at 6:37
4

As a workaround, I configured Lo0 interface as a passive and advertised only passive interfaces into ISIS:

RP/0/RP0/CPU0:PE2#sh run router isis lab
Mon Apr 19 11:01:50.732 UTC
router isis lab
 is-type level-2-only
 net 49.0000.1720.1600.0022.00
 address-family ipv4 unicast
  advertise passive-only
 !
 interface Loopback0
  passive
  address-family ipv4 unicast
  !
 !
  /* output removed for brevity */
RP/0/RP0/CPU0:PE2#

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.