Enabling Segment Routing for OSPF Protocol
Segment routing on the OSPF control plane supports the following:
-
OSPFv2 control plane
-
Multi-area
-
IPv4 prefix SIDs for host prefixes on loopback interfaces
-
Adjacency SIDs for adjacencies
-
MPLS penultimate hop popping (PHP) and explicit-null signaling
This section describes how to enable segment routing MPLS and MPLS forwarding in OSPF. Segment routing can be configured at the instance, area, or interface level.
Before you begin
Your network must support the MPLS Cisco IOS XR software feature before you enable segment routing for OSPF on your router.
![]() Note |
You must enter the commands in the following task list on every OSPF router in the traffic-engineered portion of your network. |
SUMMARY STEPS
- configure
- router ospf process-name
- mpls traffic-eng router-id interface
- segment-routing mpls
- area area
- mpls traffic-eng
- segment-routing mpls
- exit
- mpls traffic-eng
- Use the commit or end command.
DETAILED STEPS
Command or Action | Purpose | |
---|---|---|
Step 1 |
configure Example:
|
Enters XR Config mode. |
Step 2 |
router ospf process-name Example:
|
Enables OSPF routing for the specified routing process and places the router in router configuration mode. |
Step 3 |
mpls traffic-eng router-id interface Example:
|
Sets the traffic engineering loopback interface. |
Step 4 |
segment-routing mpls Example:
|
Enables segment routing using the MPLS data plane on the routing process and all areas and interfaces in the routing process. Enables segment routing fowarding on all interfaces in the routing process and installs the SIDs received by OSPF in the forwarding table. |
Step 5 |
area area Example:
|
Enters area configuration mode. |
Step 6 |
mpls traffic-eng Example:
|
Enables IGP traffic engineering funtionality. |
Step 7 |
segment-routing mpls Example:
|
(Optional) Enables segment routing using the MPLS data plane on the area and all interfaces in the area. Enables segment routing fowarding on all interfaces in the area and installs the SIDs received by OSPF in the forwarding table. |
Step 8 |
exit Example:
|
|
Step 9 |
mpls traffic-eng Example:
|
Enables traffic engineering funtionality on the node. The node advertises the traffic engineering link attributes in IGP which populates the traffic engineering database (TED) on the head-end. The SR-TE head-end requires the TED to calculate and validate the path of the SR-TE policy. |
Step 10 |
Use the commit or end command. |
commit —Saves the configuration changes and remains within the configuration session.
|
What to do next
Configure the prefix SID.