SR-TE ポリシーを介した EVPN VPWS 優先パスの設定
SR-TE ポリシー機能を介して EVPN VPWS 優先パスを確実に設定するには、次のタスクを実行する必要があります。
-
ISIS でのプレフィックス SID の設定
-
ISIS での隣接関係 SID の設定
-
セグメントリストの設定
-
SR-TE ポリシーの設定
-
SR-TE ポリシーを介した EVPN VPWS の設定
ISIS でのプレフィックス SID の設定
/* Configure Prefix-SID on PE1 */
Router# configure
Router(config)# segment-routing
Router(config-sr)# global-block 180000 200000
Router(config-sr)# exit
!
Router# configure
Route(config)# router isis core
Route(config-isis)# is-type level-2-only
Route(config-isis)# net 49.0002.0330.2000.0031.00
Route(config-isis)# nsr
Route(config-isis)# nsf ietf
Route(config-isis)# log adjacency changes
Route(config-isis)# address-family ipv4 unicast
Route(config-isis-af)# metric-style wide level 2
Route(config-isis-af)# mpls traffic-eng level-2-only
Route(config-isis-af)# mpls traffic-eng router-id 1.1.1.1
Route(config-isis-af)# segment-routing mpls sr-prefer
Route(config-isis-af)# segment-routing prefix-sid-map advertise-local
Route(config-isis-af)# exit
!
Route(config-isis)# interface loopback 0
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-af)# prefix-sid index 180010
Route(config-isis-af)# commit
Route(config-isis-af)# exit
/* Configure Prefix-SID on P1 */
Router# configure
Router(config)# segment-routing
Router(config-sr)# global-block 180000 200000
Router(config-sr)# exit
!
Router# configure
Router(config)# router isis core
Router(config-isis)# is-type level-2-only
Router(config-isis)# net 49.0002.0330.2000.0021.00
Router(config-isis)# nsr
Router(config-isis)# nsf ietf
Router(config-isis)# log adjacency changes
Router(config-isis)# address-family ipv4 unicast
Router(config-isis-af)# metric-style wide level 2
Router(config-isis-af)# mpls traffic-eng level-2-only
Router(config-isis-af)# mpls traffic-eng router-id loopback0
Router(config-isis-af)# segment-routing mpls sr-prefer
Router(config-isis-af)# segment-routing prefix-sid-map advertise-local
Router(config-isis-af)# exit
!
Router(config-isis)# interface loopback 0
Router(config-isis-if)# address-family ipv4 unicast
Router(config-isis-af)# prefix-sid index 180015
Router(config-isis-af)# commit
Router(config-isis-af)# exit
/* Configure Prefix-SID on P2 */
Router# configure
Router(config)# segment-routing
Router(config-sr)# global-block 180000 200000
Router(config-sr)# exit
!
Router# configure
Route(config)# router isis core
Route(config-isis)# is-type level-2-only
Route(config-isis)# net 49.0002.0330.2000.0022.00
Route(config-isis)# nsr
Route(config-isis)# nsf ietf
Route(config-isis)# log adjacency changes
Route(config-isis)# address-family ipv4 unicast
Route(config-isis-af)# metric-style wide level 2
Route(config-isis-af)# mpls traffic-eng level-2-only
Route(config-isis-af)# mpls traffic-eng router-id loopback0
Route(config-isis-af)# segment-routing mpls sr-prefer
Route(config-isis-af)# segment-routing prefix-sid-map advertise-local
Route(config-isis-af)# exit
!
Route(config-isis)# interface loopback 0
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-af)# prefix-sid index 180025
Route(config-isis-af)# commit
Route(config-isis-af)# exit
/* Configure Prefix-SID on PE3 */
Router# configure
Router(config)# segment-routing
Router(config-sr)# global-block 180000 200000
Router(config-sr)# exit
!
Router# configure
Route(config)# router isis core
Route(config-isis)# is-type level-2-only
Route(config-isis)# net 49.0002.0330.2000.3030.0030.0035.00
Route(config-isis)# address-family ipv4 unicast
Route(config-isis-af)# metric-style wide level 2
Route(config-isis-af)# mpls traffic-eng level-2-only
Route(config-isis-af)# mpls traffic-eng router-id loopback0
Route(config-isis-af)# segment-routing mpls sr-prefer
Route(config-isis-af)# segment-routing prefix-sid-map advertise-local
Route(config-isis-af)# exit
!
Route(config-isis)# interface loopback0
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-af)# prefix-sid index 180020
Route(config-isis-af)# commit
Route(config-isis-af)# exit
ISIS での隣接関係 SID の設定
/* Configure Adjacency-SID on PE1 */
Router# configure
Router(config)# segment-routing
Router(config-sr)# local-block 15000 15999
!
Router# configure
Route(config)# router isis core
Route(config-isis)# interface Bundle-Ether121
Route(config-isis-if)# circuit-type level-2-only
Route(config-isis-if)# point-to-point
Route(config-isis-if)# hello-padding disable
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-if-af)# adjacency-sid absolute 15101
Route(config-isis-if-af)# exit
!
Router# configure
Route(config)# router isis core
Route(config-isis)# interface TenGigE0/0/1/6
Route(config-isis-if)# circuit-type level-2-only
Route(config-isis-if)# point-to-point
Route(config-isis-if)# hello-padding disable
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-if-af)# adjacency-sid absolute 15102
Route(config-isis-if-af)# commit
/* Configure Adjacency-SID on P1 */
Router# configure
Router(config)# segment-routing
Router(config-sr)# local-block 15000 15999
!
Router# configure
Route(config)# router isis core
Route(config-isis)# interface Bundle-Ether121
Route(config-isis-if)# circuit-type level-2-only
Route(config-isis-if)# point-to-point
Route(config-isis-if)# hello-padding disable
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-if-af)# metric 20
Route(config-isis-if-af)# adjacency-sid absolute 15200
Route(config-isis-if-af)# commit
!
Router# configure
Route(config)# router isis core
Route(config-isis)# interface TenGigE0/0/0/7
Route(config-isis-if)# circuit-type level-2-only
Route(config-isis-if)# point-to-point
Route(config-isis-if)# hello-padding disable
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-if-af)# adjacency-sid absolute 15202
Route(config-isis-if-af)# commit
!
/* Configure Adjacency-SID on P2 */
Router# configure
Router(config)# segment-routing
Router(config-sr)# local-block 15000 15999
!
Router# configure
Route(config)# router isis core
Route(config-isis)# interface TenGigE0/0/0/7
Route(config-isis-if)# circuit-type level-2-only
Route(config-isis-if)# point-to-point
Route(config-isis-if)# hello-padding disable
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-if-af)# metric 20
Route(config-isis-if-af)# adjacency-sid absolute 15201
Route(config-isis-if-af)# exit
!
Router# configure
Route(config)# router isis core
Route(config-isis)# interface TenGigE0/0/0/5
Route(config-isis-if)# circuit-type level-2-only
Route(config-isis-if)# point-to-point
Route(config-isis-if)# hello-padding disable
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-if-af)# metric 20
Route(config-isis-if-af)# adjacency-sid absolute 15204
Route(config-isis-if-af)# commit
/* Configure Adjacency-SID on PE3 */
Router# configure
Router(config)# segment-routing
Router(config-sr)# local-block 15000 15999
!
Router# configure
Route(config)# router isis core
Route(config-isis)# interface TenGigE0/0/0/1
Route(config-isis-if)# circuit-type level-2-only
Route(config-isis-if)# point-to-point
Route(config-isis-if)# hello-padding disable
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-if-af)# adjacency-sid absolute 15301
Route(config-isis-if-af)# exit
!
Router# configure
Route(config)# router isis core
Route(config-isis)# interface TenGigE0/0/0/2
Route(config-isis-if)# circuit-type level-2-only
Route(config-isis-if)# point-to-point
Route(config-isis-if)# hello-padding disable
Route(config-isis-if)# address-family ipv4 unicast
Route(config-isis-if-af)# adjacency-sid absolute 15302
Route(config-isis-if-af)# commit
セグメントリストの設定
/* Configure Segment-list on PE1 using prefix-SID */
Router# configure
Router(config)# segment-routing
Router(config-sr)# global-block 180000 200000
Router(config-sr)# traffic-eng
Router(config-sr-te)# logging
Router(config-sr-te-log)# policy status
Router(config-sr-te-log)# exit
!
Router# configure
Router(config)# segment-routing
Router(config-sr)# traffic-eng
Router(config-sr-te)# segment-list name pref_sid_to_PE3
Router(config-sr-te-sl)# index 1 mpls label 180020 <-----------------------using prefix-SID
Router(config-sr-te-sl)# exit
/* Configure Segment-list on PE1 using adjacency-SID */
Router# configure
Router(config)# segment-routing
Router(config-sr)# local-block 15000 15999
Router(config-sr)# traffic-eng
Router(config-sr-te)# logging
Router(config-sr-te-log)# policy status
Router(config-sr-te-log)# exit
!
Router# configure
Router(config)# segment-routing
Router(config-sr)# traffic-eng
Router(config-sr-te)# segment-list name pref_adj_sid_to_PE3
Router(config-sr-te-sl)# index 1 mpls label 15101 <-----------------------using adjacency-SID
Router(config-sr-te-sl)# index 2 mpls label 15202 <-----------------------using adjacency-SID
Router(config-sr-te-sl)# exit
SR-TE ポリシーの設定
/* Configure SR-TE Policy */
Router# configure
Router(config)# segment-routing
Router(config-sr)# traffic-eng
Router(config-sr-te)# policy pref_sid_to_PE3
Router(config-sr-te-policy)# color 9001 end-point ipv4 20.20.20.20
Router(config-sr-te-policy)# candidate-paths
Router(config-sr-te-policy)# preference 10
Router(config-sr-te-pp-info)# explicit segment-list pref_sid_to_PE3
Router(config-sr-te-pp-info)# commit
Router(config-sr-te-pp-info)# exit
!
Router# configure
Router(config)# segment-routing
Router(config-sr)# traffic-eng
Router(config-sr-te)# policy pref_adj_sid_to_PE3
Router(config-sr-te-policy)# color 9001 end-point ipv4 20.20.20.20
Router(config-sr-te-policy)# candidate-paths
Router(config-sr-te-policy)# preference 200
Router(config-sr-te-pp-info)# explicit segment-list pref_adj_sid_to_PE3
Router(config-sr-te-pp-info)# commit
Router(config-sr-te-pp-info)# exit
/* You can configure multiple preferences for an SR policy. Among the configured preferences, the largest number takes the highest precedence */
Router# configure
Router(config)# segment-routing
Router(config-sr)# global-block 180000 200000
Router(config-sr)# local-block 15000 15999
Router(config-sr)# traffic-eng
Router(config-sr-te)# policy 1013
Router(config-sr-te-policy)# color 1013 end-point ipv4 2.2.2.2
Router(config-sr-te-policy)# candidate-paths
Router(config-sr-te-policy)# preference 100
Router(config-sr-te-pp-info)# explicit segment-list PE1-P1_BE121
Router(config-sr-te-pp-info)# exit
!
Router(config-sr-te-policy)# preference 200
Router(config-sr-te-pp-info)# explicit segment-list PE1-PE3-P1-t0016
Router(config-sr-te-pp-info)# exit
!
Router(config-sr-te-policy)# preference 700 <----------largest number takes the precendence
Router(config-sr-te-pp-info)# explicit segment-list PE1-P1
Router(config-sr-te-pp-info)# commit
Router(config-sr-te-pp-info)# exit
SR-TE ポリシーを介した EVPN VPWS の設定
Router# configure
Router(config)# l2vpn
Router(config-l2vpn)# pw-class 1001
Router(config-l2vpn-pwc)# encapsulation mpls
Router(config-l2vpn-pwc-mpls)# preferred-path sr-te policy pref_sid_to_PE3 fallback disable
Router(config-l2vpn-pwc-mpls)# commit
Router(config-l2vpn-pwc-mpls)# exit
!
Router(config)# l2vpn
Router(config-l2vpn)# xconnect group evpn_vpws
Router(config-l2vpn-xc)# p2p evpn_vpws_1001
Router(config-l2vpn-xc-p2p)# interface tengi0/1/0/1.1001
Router(config-l2vpn-xc-p2p)# neighbor evpn evi 1001 target 10001 source 20001
Router(config-l2vpn-xc-p2p-pw)# pw-class 1001
Router(config-l2vpn-xc-p2p-pw)# commit
Router(config-l2vpn-xc-p2p-pw)# exit
/* If Fallback Enable is configured, which is the default option, and if the SR-policy is down, then EVPN VPWS will still continue to be UP using the regular IGP path, and not using the SR-policy */
show l2vpn xconnect detail
EVPN: neighbor 20.20.20.20, PW ID: evi 1001, ac-id 10001, state is up ( established )
Preferred path Inactive : SR TE pref_sid_to_PE3, Statically configured, fallback enabled
Tunnel : Down
LSP: Up
/* If Fallback Disable is configured, and if the SR-policy is down, or if it misconfigured in dual homed mode, then the L2VPN PW will be down */
show l2vpn xconnect detail
EVPN: neighbor 20.20.20.20, PW ID: evi 1001, ac-id 10001, state is down ( local ready )
Preferred path Active : SR TE pref_sid_to_PE3, Statically configured, fallback disabled
Tunnel : Down
実行コンフィギュレーション
/* Configure Prefix-SID in ISIS */
PE1:
configure
segment-routing
global-block 180000 200000
!
router isis core
is-type level-2-only
net 49.0002.0330.2000.0031.00
nsr
nsf ietf
log adjacency changes
address-family ipv4 unicast
metric-style wide level 2
mpls traffic-eng level-2-only
mpls traffic-eng router-id 1.1.1.1
segment-routing mpls sr-prefer
segment-routing prefix-sid-map advertise-local
interface Loopback0
address-family ipv4 unicast
prefix-sid index 180010
P1:
configure
segment-routing
global-block 180000 200000
router isis core
is-type level-2-only
net 49.0002.0330.2000.0021.00
nsr
nsf ietf
log adjacency changes
address-family ipv4 unicast
metric-style wide level 2
mpls traffic-eng level-2-only
mpls traffic-eng router-id Loopback0
segment-routing mpls sr-prefer
segment-routing prefix-sid-map advertise-local
interface Loopback0
address-family ipv4 unicast
prefix-sid index 180015
P2:
configure
segment-routing
global-block 180000 200000
router isis core
is-type level-2-only
net 49.0002.0330.2000.0022.00
nsr
nsf ietf
log adjacency changes
address-family ipv4 unicast
metric-style wide level 2
mpls traffic-eng level-2-only
mpls traffic-eng router-id Loopback0
segment-routing mpls sr-prefer
segment-routing prefix-sid-map advertise-local
interface Loopback0
address-family ipv4 unicast
prefix-sid index 180025
PE3:
configure
segment-routing
global-block 180000 200000
router isis core
is-type level-2-only
net 49.0002.0330.2000.3030.0030.0035.00
address-family ipv4 unicast
metric-style wide level 2
mpls traffic-eng level-2-only
mpls traffic-eng router-id Loopback0
segment-routing mpls sr-prefer
segment-routing prefix-sid-map advertise-local
interface Loopback0
address-family ipv4 unicast
prefix-sid index 180020
/* Configure Adjacency-SID in ISIS */
PE1:
configure
segment-routing
local-block 15000 15999
!
router isis core
!
interface Bundle-Ether121
circuit-type level-2-only
point-to-point
hello-padding disable
address-family ipv4 unicast
adjacency-sid absolute 15101
interface TenGigE0/0/1/6
circuit-type level-2-only
point-to-point
hello-padding disable
address-family ipv4 unicast
adjacency-sid absolute 15102
P1:
configure
segment-routing
local-block 15000 15999
router isis core
!
interface Bundle-Ether121
circuit-type level-2-only
point-to-point
hello-padding disable
address-family ipv4 unicast
metric 20
adjacency-sid absolute 15200
interface TenGigE0/0/0/0/7
circuit-type level-2-only
point-to-point
hello-padding disable
address-family ipv4 unicast
metric 20
adjacency-sid absolute 15202
P2:
configure
segment-routing
local-block 15000 15999
router isis core
!
interface TenGigE0/0/0/5
circuit-type level-2-only
point-to-point
hello-padding disable
address-family ipv4 unicast
metric 20
adjacency-sid absolute 15204
interface TenGigE0/0/0/0/7
circuit-type level-2-only
point-to-point
hello-padding disable
address-family ipv4 unicast
metric 20
adjacency-sid absolute 15201
PE3:
configure
segment-routing
local-block 15000 15999
router isis core
!
interface TenGigE0/0/0/1
circuit-type level-2-only
point-to-point
hello-padding disable
address-family ipv4 unicast
adjacency-sid absolute 15301
!
!
interface TenGigE0/0/0/2
circuit-type level-2-only
point-to-point
hello-padding disable
address-family ipv4 unicast
adjacency-sid absolute 15302
/* Configure Segment-list */
PE1:
configure
segment-routing
global-block 180000 200000
traffic-eng
logging
policy status
segment-routing
traffic-eng
segment-list name pref_sid_to_PE3
index 1 mpls label 180020
!
!
configure
segment-routing
local-block 15000 15999
traffic-eng
logging
policy status
segment-routing
traffic-eng
segment-list name pref_adj_sid_to_PE3
index 1 mpls label 15101
index 2 mpls label 15202
!
!
/* Configure SR-TE policy */
segment-routing
traffic-eng
policy pref_sid_to_PE3
color 9001 end-point ipv4 20.20.20.20
candidate-paths
preference 10
explicit segment-list pref_sid_to_PE3
!
!
segment-routing
traffic-eng
policy pref_adj_sid_to_PE3
color 9001 end-point ipv4 20.20.20.20
candidate-paths
preference 200
explicit segment-list pref_adj_sid_to_PE3
!
!
/* You can configure multiple preferences for an SR policy. Among the configured preferences, the largest number takes the highest precedence */
segment-routing
traffic-eng
policy 1013
color 1013 end-point ipv4 2.2.2.2
candidate-paths
preference 100
explicit segment-list PE1-P1_BE121
!
preference 200
explicit segment-list PE1-PE3-P1-t0016
!
preference 700
explicit segment-list PE1-P1
!
/* Configure EVPN VPWS over SR-TE policy */
PE1:
configure
l2vpn
pw-class 1001
encapsulation mpls
preferred-path sr-te policy pref_sid_to_PE3 fallback disable
xconnect group evpn_vpws
p2p evpn_vpws_1001
interface tengi0/1/0/1.1001
neighbor evpn evi 1001 target 10001 source 20001
pw-class 1001
!
SR-TE ポリシーを介した EVPN VPWS 優先パスの確認
PE1#show segment-routing traffic-eng forwarding policy name pref_sid_to_PE3 detail
Policy Segment Outgoing Outgoing Next Hop Bytes
Name List Label Interface Switched
------------- --------------- ----------- ------------------- --------------- ------------
pref_sid_to_PE3
15102 TenGigE0/0/1/6 20.20.20.20 81950960
Label Stack (Top -> Bottom): { 15101, 15102 }
Path-id: 1, Weight: 0
Packets Switched: 787990
Local label: 34555
Packets/Bytes Switched: 1016545/105720680
(!): FRR pure backup
PE1#show mpls forwarding tunnels sr-policy name pref_sid_to_PE3
Tunnel Outgoing Outgoing Next Hop Bytes
Name Label Interface Switched
------------- ----------- ------------ --------------- ------------
pref_sid_to_PE3 (SR) 15102 TenGigE0/0/1/6 20.20.20.20 836516512
PE1#show l2vpn xconnect group evpn_vpws xc-name evpn_vpws_1001 detail
Group evpn_vpws, XC evpn_vpws_1001, state is up; Interworking none
AC: Bundle-Ether12.1001, state is up
Type VLAN; Num Ranges: 1
Outer Tag: 1000
Rewrite Tags: []
VLAN ranges: [1, 1]
MTU 1500; XC ID 0xc0000018; interworking none
Statistics:
packets: received 642304, sent 642244
bytes: received 61661184, sent 61655424
drops: illegal VLAN 0, illegal length 0
EVPN: neighbor 20.20.20.20, PW ID: evi 1001, ac-id 10001, state is up ( established )
XC ID 0xa0000007
Encapsulation MPLS
Source address 10.10.10.10
Encap type Ethernet, control word enabled
Sequencing not set
Preferred path Active : SR TE pref_sid_to_PE3, Statically configured, fallback disabled
Tunnel : Up
Load Balance Hashing: src-dst-mac
関連コマンド
-
adjacency-sid
-
index
-
prefix-sid
-
segment-routing
該当するセグメント ルーティング コマンドについては、『Segment Routing Command Reference for Cisco NCS 5500 Series Routers』を参照してください。