2-Module 3 Lab Guide - Segment Routing v1.0
2-Module 3 Lab Guide - Segment Routing v1.0
The following will be the common topology and IP address plan used for this lab.
lo 0: lo 0:
[Link] [Link]
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/0
.1 .6
[Link]/24
R1 [Link]/24 R6
.1 .6
lo 0: lo 0:
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/1
[Link] [Link]
Gi0/0/0/1
R3 .3
.5
.5 R5
.3
Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/0/0/0
[Link]/24 .3 .3 [Link]/24 .5 .5 [Link]/24
lo 0: lo 0:
[Link] [Link]
Lab Notes
The basic Segment Routing lab topology comprises of 6 routers: R1, R2, R3, R4, R5 and R6. Multiple
sets of identical topologies will be used. Workshop attendees will be split up into groups of 6 where
each group member will be responsible for the configuration of a specific router.
All routers are running Cisco IOS-XRv 6.1.2 within GNS3. Login credentials are:
Username: cisco
Password: cisco
Please spend some time to be familiar with the network topology and addressing plan before you start
building the configuration on the routers.
1 ©APNIC
Created: 24 June 2014
Updated: 24 June 2014
Monday, September 04, 2017
lo 0: lo 0:
[Link] [Link]
SID: 16002 SID: 16004
SRGB: 16000-23999 SRGB: 16000-23999
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/0
.1 .6
[Link]/24
[Link]/24
.1
R1 R6 .6
lo 0: lo 0:
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/1
[Link] [Link]
Gi0/0/0/1
lo 0: lo 0:
[Link] [Link]
SID: 16003 SID: 16005
SRGB: 16000-23999 SRGB: 16000-23999
After the base Segment Routing configuration there will be a number of node and adjacency SIDs
allocated as per the table below:
2
APNIC SDN Workshop Lab
Part 2. Using SID index values with different SRGBs on all routers
The following reflects the Segment Routing configuration using SID index values and different
SRGBs.
lo 0: lo 0:
[Link] [Link]
SID index: 200 SID index: 400
SRGB: 17000-17999 SRGB: 19000-19999
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/0
.1 .6
[Link]/24
[Link]/24
.1
R1 R6 .6
lo 0: lo 0:
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/1
[Link] [Link]
Gi0/0/0/1
lo 0: lo 0:
[Link] [Link]
SID index: 300 SID index: 500
SRGB: 18000-18999 SRGB: 20000-20999
In this part, we use indexes instead of absolute SID values. In addition, we configure different SRGBs
on each of the routers.
The following figure includes the additional configuration required for this part.
lo 0: lo 0:
[Link] [Link]
lo1: lo1:
[Link]/32 [Link]/32
SID index: 200 SID index: 400
SRGB: 17000-17999 SRGB: 19000-19999
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/0
.1 .6
[Link]/24
[Link]/24
.1
R1 R6 .6
lo 0: lo 0:
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/1
[Link] [Link]
Gi0/0/0/1
lo1: lo1:
[Link]/32
SID index: 100
R3 .3
.5
.5 R5 [Link]/32
SID index: 600
.3
SRGB: 16000-16999 Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/0/0/0 SRGB: 21000-
.5 .5
[Link]/24 .3 .3 [Link]/24 [Link]/24 21999
lo 0: lo 0:
[Link] [Link]
lo1: lo1:
[Link]/32 [Link]/32
SID index: 300 SID index: 500
SRGB: 18000-18999 SRGB: 20000-20999
3 ©APNIC
Created: 24 June 2014
Updated: 24 June 2014
Monday, September 04, 2017
We configure explicitly-routed traffic-engineered paths and resolve them using Segment Routing
SIDs. Each router configures a unique path as per the table below.
4
APNIC SDN Workshop Lab
Lab Exercise
1. Base Segment Routing configuration:
lo 0: lo 0:
[Link] [Link]
SID: 16002 SID: 16004
SRGB: 16000-23999 SRGB: 16000-23999
0/
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/0
0/ 0/
2 0/
10 Gi
.2.
5.0
.1 /2 .6
4
[Link]/24
[Link]/24
24
0/
.1
R1 .3.
4. R6 .6
10 lo 0:
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/1
[Link]
Gi0/0/0/1
2 Gi
0/ SID: 16006
0/ 0/
0/ 0/
0/
R3 .3 Gi
2
.5
.5 R5 SRGB:
16000-23999
.3
Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/0/0/0
[Link]/24 .3 .3 [Link]/24 .5 .5 [Link]/24
lo 0: lo 0:
[Link] [Link]
SID: 16003 SID: 16005
SRGB: 16000-23999 SRGB: 16000-23999
config t
mpls traffic-eng
! Enables traffic engineering functionality on the node.
router ospf 1
segment-routing global-block 16000 23999
! Configure the SRGB for this node
segment-routing mpls
! Enables Segment Routing using the mpls dataplane. Also enables Segment Routing on all areas
and interfaces. Is also required to install SIDs received by OSPF into the forwarding table.
mpls traffic-eng router-id loopback0
! Configures loopback 0 as the traffic-engineering router identifier.
area [Link]
mpls traffic-eng
! Enables traffic-engineering functionality for OSPF.
interface loopback 0
prefix-sid absolute 16001
! Assigns an absolute SID value to loopback 0 (your SID value will depend on your router as per
the figure)
end
5 ©APNIC
Created: 24 June 2014
Updated: 24 June 2014
Monday, September 04, 2017
Please wait for all routers in your group to be configured before you issue the following
verification commands. Please also do not move to the next part until advised to do so by
your instructors.
ping mpls nil-fec labels 16006 output interface gigabitEthernet 0/0/0/0 nexthop
[Link]
! Ping a loopback prefix SID for a router other than your own. Change output interface and next-
hop accordingly.
show logging
6
APNIC SDN Workshop Lab
2. Using SID index values with different SRGBs on all routers
The following figure includes the additional configuration required for this part.
lo 0: lo 0:
[Link] [Link]
lo1: lo1:
[Link]/32 [Link]/32
SID index: 200 SID index: 400
SRGB: 17000-17999 SRGB: 19000-19999
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/0
.1 .6
[Link]/24
[Link]/24
.1
R1 R6 .6
lo 0: lo 0:
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/1
[Link] [Link]
Gi0/0/0/1
lo1: lo1:
[Link]/32
SID index: 100
R3 .3
.5
.5 R5 [Link]/32
SID index: 600
.3
SRGB: 16000-16999 Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/0/0/0 SRGB: 21000-
.5 .5
[Link]/24 .3 .3 [Link]/24 [Link]/24 21999
lo 0: lo 0:
[Link] [Link]
lo1: lo1:
[Link]/32 [Link]/32
SID index: 300 SID index: 500
SRGB: 18000-18999 SRGB: 20000-20999
config t
router ospf 1
area [Link]
interface loopback 0
prefix-sid index 100
! Assigns a SID index of 100 to loopback 0 (your index will depend on your router as per the
figure)
exit
exit
segment-routing global-block 16000 16999
! Changes the SRGB of the node to 16000-16999 (your range will depend on your router as per the
figure)
end
Please wait for all routers in your group to be configured before you issue the following
verification commands. Please also do not move to the next part until advised to do so by
your instructors.
ping mpls nil-fec labels 17600 output interface gigabitEthernet 0/0/0/0 nexthop
[Link]
! Ping a loopback prefix SID for a router other than your own. Change output interface and next-
hop accordingly.
The following figure includes the additional configuration required for this part.
lo 0: lo 0:
[Link] [Link]
lo1: lo1:
[Link]/32 [Link]/32
SID index: 200 SID index: 400
SRGB: 17000-17999 SRGB: 19000-19999
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/0
.1 .6
[Link]/24
[Link]/24
.1
R1 R6 .6
lo 0: lo 0:
Gi0/0/0/3
Gi0/0/0/3
Gi0/0/0/1
[Link] [Link]
Gi0/0/0/1
lo1: lo1:
[Link]/32
SID index: 100
R3 .3
.5
.5 R5 [Link]/32
SID index: 600
.3
SRGB: 16000-16999 Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/0/0/0 SRGB: 21000-
.5 .5
[Link]/24 .3 .3 [Link]/24 [Link]/24 21999
lo 0: lo 0:
[Link] [Link]
lo1: lo1:
[Link]/32 [Link]/32
SID index: 300 SID index: 500
SRGB: 18000-18999 SRGB: 20000-20999
Each router needs to be configured with a different explicit tunnel as per the table below.
8
APNIC SDN Workshop Lab
Router Destination Path
R1 R6 R1-R2-R3-R4-R5-R6
R2 R1 R2-R4-R6-R5-R3-R1
R3 R5 R3-R1-R2-R4-R6-R5
R4 R2 R4-R6-R5-R3-R1-R2
R5 R6 R5-R3-R1-R2-R4-R6
R6 R1 R6-R4-R5-R2-R3-R1
conf t
explicit-path name SR-TE-PATH-1
index 1 next-address strict ipv4 unicast [Link]
index 2 next-address strict ipv4 unicast [Link]
index 3 next-address strict ipv4 unicast [Link]
index 4 next-address strict ipv4 unicast [Link]
index 5 next-address strict ipv4 unicast [Link]
!
exit
! create an explicit path named SR-TE-PATH-1 with an explicitly-specified list of hops
interface tunnel-te0
ipv4 unnumbered Loopback0
destination [Link]
path-option 1 explicit name SR-TE-PATH-1 segment-routing
!
! create a tunnel interface with a destination of R6 and link the previously-created explicit path
SR-TE-PATH-1 with it
int lo1
ipv4 address [Link]/32
exit
! create a new loopback address on the router (use the address corresponding to your router as per
the diagram)
! create a static route to R6's loopback address (choose a target router based on the destination of
the tunnel interface created earlier)
router static
address-family ipv4 unicast
[Link]/32 tunnel-te0
exit
Please wait for all routers in your group to be configured before you issue the following
verification commands.
ping [Link]
! verify the static route
10
APNIC SDN Workshop Lab
Workshop templates for reference purpose only:
R1
config t
mpls traffic-eng
router ospf 1
segment-routing global-block 16000 23999
segment-routing mpls
mpls traffic-eng router-id loopback0
area [Link]
mpls traffic-eng
interface loopback 0
prefix-sid absolute 16001
end
Verification Commands:
Verification Commands:
11 ©APNIC
Created: 24 June 2014
Updated: 24 June 2014
Monday, September 04, 2017
Verification Commands:
show mpls traffic-eng tunnels 0 detail
ping [Link]
12
APNIC SDN Workshop Lab
R2
config t
mpls traffic-eng
router ospf 1
segment-routing global-block 16000 23999
segment-routing mpls
mpls traffic-eng router-id loopback0
area [Link]
mpls traffic-eng
interface loopback 0
prefix-sid absolute 16002
end
Verification Commands:
Verification Commands:
13 ©APNIC
Created: 24 June 2014
Updated: 24 June 2014
Monday, September 04, 2017
Verification Commands:
show mpls traffic-eng tunnels 0 detail
ping [Link]
14
APNIC SDN Workshop Lab
R3
config t
mpls traffic-eng
router ospf 1
segment-routing global-block 16000 23999
segment-routing mpls
mpls traffic-eng router-id loopback0
area [Link]
mpls traffic-eng
interface loopback 0
prefix-sid absolute 16003
end
Verification Commands:
Verification Commands:
15 ©APNIC
Created: 24 June 2014
Updated: 24 June 2014
Monday, September 04, 2017
Verification Commands:
show mpls traffic-eng tunnels 0 detail
ping [Link]
16
APNIC SDN Workshop Lab
R4
config t
mpls traffic-eng
router ospf 1
segment-routing global-block 16000 23999
segment-routing mpls
mpls traffic-eng router-id loopback0
area [Link]
mpls traffic-eng
interface loopback 0
prefix-sid absolute 16004
end
Verification Commands:
Verification Commands:
17 ©APNIC
Created: 24 June 2014
Updated: 24 June 2014
Monday, September 04, 2017
Verification Commands:
show mpls traffic-eng tunnels 0 detail
ping [Link]
18
APNIC SDN Workshop Lab
R5
config t
mpls traffic-eng
router ospf 1
segment-routing global-block 16000 23999
segment-routing mpls
mpls traffic-eng router-id loopback0
area [Link]
mpls traffic-eng
interface loopback 0
prefix-sid absolute 16005
end
Verification Commands:
Verification Commands:
19 ©APNIC
Created: 24 June 2014
Updated: 24 June 2014
Monday, September 04, 2017
Verification Commands:
show mpls traffic-eng tunnels 0 detail
ping [Link]
20
APNIC SDN Workshop Lab
R6
config t
mpls traffic-eng
router ospf 1
segment-routing global-block 16000 23999
segment-routing mpls
mpls traffic-eng router-id loopback0
area [Link]
mpls traffic-eng
interface loopback 0
prefix-sid absolute 16006
end
Verification Commands:
Verification Commands:
21 ©APNIC
Created: 24 June 2014
Updated: 24 June 2014
Monday, September 04, 2017
Verification Commands:
show mpls traffic-eng tunnels 0 detail
ping [Link]
22