isis , ospf , bgp conf segments . Flashcards
small configurations
Leak lv2 routes in to lv1 routes isis
ip prefix-list LOOPBACKS permit 0.0.0.0/0 ge 32
route-map LOOPBACKS
match ip address prefix-list LOOPBACKS
router isis
redistribute isis ip level-2 into level 1 route-map LOOPBACKS
exit
ip prefix-list LOOPBACKS permit 0.0.0.0/0 ge 32
exit
route-maps LOOPBACKS
match ip address prefix-list LOOPBACKS
routeer isis
redistribute isis ip level-2 into level 1 LOOPBACKS
redistribute ospf loobacks in to isis
R1
router ospf 1
segment-routing mpls
network 0.0.0.0 255.255.255.255 area 0
!
int Gi1
ip ospf network point-to-point
int Gi1
no ip router isis
ip ospf network point-to-point
!
router ospf 1
segment-routing mpls
redistribute isis route-map LOOPBACKS
network 10.1.2.0 0.0.0.255 area 0
network 2.2.2.2 255.255.255.255 area 0
!
router isis
redistribute ospf 1 route-map LOOPBACKS
mpls segment routing for bpg lu
Here is the configuration for IOS-XR:
segment-routing mpls global-block 16000 23999
!
route-policy SID($SID)
set label-index $SID
end-policy
!
router bgp 100
address-family ipv4 unicast
network 1.1.1.1/32 route-policy SID(1)
Here is the configuration for IOS-XE:
segment-routing mpls
global-block 16000 23999
!
connected-prefix-sid-map
address-family ipv4
10.2.2.2/32 index 102 range 1
exit-address-family
!
!
router bgp 100
address-family ipv4
network 10.2.2.2 mask 255.255.255.255
segment-routing mpls
route policy explanation
set label-index $SID:
In the route-policy, the set label-index $SID command dynamically sets the label index to the value passed in as the $SID variable. When the policy is applied, this variable will be replaced with an actual SID value (e.g., 1, 2, 3, etc.).
router bgp 100 … route-policy SID(1):
In the BGP configuration, when you reference the route-policy SID(1), the value 1 replaces the $SID variable in the route-policy. This means the policy will set the label index to 1 for the BGP advertisement of the route 1.1.1.1/32.