RSVP – Link Coloring
1. Intro
Administrative groups provide the ability to mark the interfaces with similar characteristics in a common group. Based on these groups you can restrict the LSPs to use a certain path in the network.
Marking the interfaces is known as coloring but is actually based on setting the affinity bits on interfaces. Up to 32 administrative groups are supported, ranging from 0 to 31. You must define a name for the group and assign an affinity bit to it, usually colors are used for names of the groups.
One or multiple different groups can be assigned to interfaces. The administrative groups / affinity bits are used by the CSPF algorithm for traffic engineering purposes.
To configure a given LSP to be restricted based on link colors you can use the following three options:
- include-any – performs logical OR to the configured colors. Any links matching one or many of the configured colors are included in CSPF calculations.
- include-all – performs logical AND. Only links matching all configured colors are taken in account for calculations.
- exclude – links with colors specified with exclude are automatically excluded from the calculations. If more than one color is specified logical OR is performed
2. Interface coloring
We will use the following topology to test RSVP link coloring. We will prepare the interfaces with the colors presented in the below diagram:

Note:
- Based on the address being used you will be able to identify the link.
- For example, 17.6.7.7 is a link beween router 6 and 7, and this is Router 7.
- Example 2, 17.1.2.1 is a link beween router 1 and 2, and this is Router 1.
The configuration is as follows:
### First we need to define the colors:
set protocols mpls admin-groups BLUE 0
set protocols mpls admin-groups GREEN 1
set protocols mpls admin-groups RED 2
### Then we need to apply the colors to the interfaces:
set protocols mpls interface ge-0/0/2.0 admin-group BLUE
set protocols mpls interface ge-0/0/1.0 admin-group RED
set protocols mpls interface ge-0/0/1.0 admin-group GREEN
### Repeat this step for all routers/interfaces in the network.
### At this stage all interfaces have colors, but are not yet used.
At this stage all interfaces have admin-group configuration, but colors are not being used at the moment. In the next session we will configure LSPs to used certain paths in the network, based on colors.
3. admin-group include-any
We want our main path to the R7 router to use the BLUE links:
### Configure the LSP to R7 and select only BLUE links:
set protocols mpls label-switched-path TO-R7 to 17.0.0.7
set protocols mpls label-switched-path TO-R7 admin-group include-any BLUE
commit
### The LSP to R7 is installed to the inet.3 table:
root@R1# run show route table inet.3
inet.3: 1 destinations, 1 routes (1 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
17.0.0.7/32 *[RSVP/7/1] 01:02:34, metric 3000
> to 17.1.3.3 via ge-0/0/2.0, label-switched-path TO-R7
### Path to R7:
root@R1# run show rsvp session
Ingress RSVP: 1 sessions
To From State Rt Style Labelin Labelout LSPname
17.0.0.7 17.0.0.1 Up 0 1 FF - 299920 TO-R7
Total 1 displayed, Up 1, Down 0
Egress RSVP: 1 sessions
To From State Rt Style Labelin Labelout LSPname
17.0.0.1 17.0.0.7 Up 0 1 FF 3 - TO-R1
Total 1 displayed, Up 1, Down 0
Transit RSVP: 0 sessions
Total 0 displayed, Up 0, Down 0
### Similar output with a different command:
root@R1# run show mpls lsp
Ingress LSP: 1 sessions
To From State Rt P ActivePath LSPname
17.0.0.7 17.0.0.1 Up 0 * TO-R7
Total 1 displayed, Up 1, Down 0
Egress LSP: 1 sessions
To From State Rt Style Labelin Labelout LSPname
17.0.0.1 17.0.0.7 Up 0 1 FF 3 - TO-R1
Total 1 displayed, Up 1, Down 0
Transit LSP: 0 sessions
Total 0 displayed, Up 0, Down 0
### Using extensive we can see the path is R1 -> R3 -> R6 -> R7 :
root@R1# run show mpls lsp name TO-R7 extensive
Ingress LSP: 1 sessions
17.0.0.7
From: 17.0.0.1, State: Up, ActiveRoute: 0, LSPname: TO-R7, LSPid: 2
ActivePath: (primary)
LSPtype: Static Configured, Penultimate hop popping
LoadBalance: Random
Follow destination IGP metric
Encoding type: Packet, Switching type: Packet, GPID: IPv4
LSP Self-ping Status : Enabled
*Primary State: Up
Priorities: 7 0
SmartOptimizeTimer: 180
Include Any: BLUE
Flap Count: 5
MBB Count: 0
Computed ERO (S [L] denotes strict [loose] hops): (CSPF metric: 3000)
17.1.3.3 S 17.3.6.6 S 17.6.7.7 S
Received RRO (ProtectionFlag 1=Available 2=InUse 4=B/W 8=Node 10=SoftPreempt 20=Node-ID):
17.1.3.3(Label=299920) 17.3.6.6(Label=299920) 17.6.7.7(Label=3)
88 Jul 23 03:08:01.147 Selected as active path
87 Jul 23 03:08:01.146 Self-ping ended successfully
86 Jul 23 03:08:00.183 Up
85 Jul 23 03:08:00.183 Self-ping started
84 Jul 23 03:08:00.183 Self-ping enqueued
83 Jul 23 03:08:00.183 Record Route: 17.1.3.3(Label=299920) 17.3.6.6(Label=299920) 17.6.7.7(Label=3)
82 Jul 23 03:08:00.121 LSP-ID: 6 created
81 Jul 23 03:08:00.121 Originate Call
80 Jul 23 03:08:00.121 CSPF: computation result accepted 17.1.3.3 17.3.6.6 17.6.7.7
[...]
Created: Wed Jul 22 07:54:38 2026
Total 1 displayed, Up 1, Down 0
Egress LSP: 1 sessions
Total 0 displayed, Up 0, Down 0
Transit LSP: 0 sessions
Total 0 displayed, Up 0, Down 0
4. admin-group exclude
We want our backup path to use the RED links.
We can configure this with ‘admin-group include-any RED‘, but we will use ‘admin-group exclude BLUE‘ instead. Same result, different approach:
### Configure a new LSP for the backup path:
root@R1# show | compare
[edit protocols mpls]
label-switched-path TO-R7 { ... }
+ label-switched-path TO-R7-backup {
+ to 17.0.0.7;
+ admin-group exclude BLUE;
+ }
[edit]
root@R1# commit
commit complete
### The backup LSP is up:
root@R1# run show mpls lsp
Ingress LSP: 2 sessions
To From State Rt P ActivePath LSPname
17.0.0.7 17.0.0.1 Up 0 * TO-R7
17.0.0.7 17.0.0.1 Up 0 * TO-R7-backup
Total 2 displayed, Up 2, Down 0
Egress LSP: 1 sessions
To From State Rt Style Labelin Labelout LSPname
17.0.0.1 17.0.0.7 Up 0 1 FF 3 - TO-R1
Total 1 displayed, Up 1, Down 0
Transit LSP: 0 sessions
Total 0 displayed, Up 0, Down 0
### The LSP path is R1 -> R2 -> R4 -> R5 -> R8 -> R7 :
root@R1# run show mpls lsp name TO-R7-backup extensive
Ingress LSP: 2 sessions
17.0.0.7
From: 17.0.0.1, State: Up, ActiveRoute: 0, LSPname: TO-R7-backup, LSPid: 3
ActivePath: (primary)
LSPtype: Static Configured, Penultimate hop popping
LoadBalance: Random
Follow destination IGP metric
Encoding type: Packet, Switching type: Packet, GPID: IPv4
LSP Self-ping Status : Enabled
*Primary State: Up
Priorities: 7 0
SmartOptimizeTimer: 180
Exclude: BLUE
Flap Count: 0
MBB Count: 0
Computed ERO (S [L] denotes strict [loose] hops): (CSPF metric: 5000)
17.1.2.2 S 17.2.4.4 S 17.4.5.5 S 17.5.8.8 S 17.7.8.7 S
Received RRO (ProtectionFlag 1=Available 2=InUse 4=B/W 8=Node 10=SoftPreempt 20=Node-ID):
17.1.2.2(Label=299824) 17.2.4.4(Label=299824) 17.4.5.5(Label=299824) 17.5.8.8(Label=299824) 17.7.8.7(Label=3)
10 Jul 23 04:29:06.167 Selected as active path
9 Jul 23 04:29:06.166 Self-ping ended successfully
8 Jul 23 04:29:05.220 Up
7 Jul 23 04:29:05.220 Self-ping started
6 Jul 23 04:29:05.220 Self-ping enqueued
5 Jul 23 04:29:05.219 Record Route: 17.1.2.2(Label=299824) 17.2.4.4(Label=299824) 17.4.5.5(Label=299824) 17.5.8.8(Label=299824) 17.7.8.7(Label=3)
4 Jul 23 04:29:05.162 LSP-ID: 1 created
3 Jul 23 04:29:05.162 Originate Call
2 Jul 23 04:29:05.162 CSPF: computation result accepted 17.1.2.2 17.2.4.4 17.4.5.5 17.5.8.8 17.7.8.7
1 Jul 23 04:28:35.174 CSPF failed: no route toward 17.0.0.7[2 times, first Jul 23 04:25:39.065]
Created: Thu Jul 23 04:25:39 2026
Total 1 displayed, Up 1, Down 0
Egress LSP: 1 sessions
Total 0 displayed, Up 0, Down 0
Transit LSP: 0 sessions
Total 0 displayed, Up 0, Down 0
### We can see the backup LSP in the inet.3 table:
root@R1# run show route table inet.3
inet.3: 1 destinations, 1 routes (1 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
17.0.0.7/32 *[RSVP/7/1] 00:04:41, metric 3000
> to 17.1.3.3 via ge-0/0/2.0, label-switched-path TO-R7
to 17.1.2.2 via ge-0/0/1.0, label-switched-path TO-R7-backup
Buy, why have 2 x LSP to the same destination, this might not be ideal. We can use one single LSP with a Primary and Secondary path, as described in the next post.
5. admin-group include-all
Not the most realistic scenario, but for testing purposes let’s assume we want the path that both RED and GREEN colors:
- R1 – R2 R3 – R4 – R5 – R6 – R8 – R7
### You may be tempted to try this config:
set protocols mpls label-switched-path TO-R7-test to 17.0.0.7
set protocols mpls label-switched-path TO-R7-test admin-group include-any GREEN
set protocols mpls label-switched-path TO-R7-test admin-group include-any RED
### But, this is not correct.
### 'include-any' is using a logical OR, so use links which have RED or GREEN color.
### The Path is R1 - R2 - R4 - R5 - R8 - R7 :
root@R1# run show mpls lsp name TO-R7-test extensive
Ingress LSP: 2 sessions
17.0.0.7
From: 17.0.0.1, State: Up, ActiveRoute: 0, LSPname: TO-R7-test, LSPid: 4
ActivePath: (primary)
LSPtype: Static Configured, Penultimate hop popping
LoadBalance: Random
Follow destination IGP metric
Encoding type: Packet, Switching type: Packet, GPID: IPv4
LSP Self-ping Status : Enabled
*Primary State: Up
Priorities: 7 0
SmartOptimizeTimer: 180
Include Any: RED GREEN
Flap Count: 0
MBB Count: 0
Computed ERO (S [L] denotes strict [loose] hops): (CSPF metric: 5000)
17.1.2.2 S 17.2.4.4 S 17.4.5.5 S 17.5.8.8 S 17.7.8.7 S
Received RRO (ProtectionFlag 1=Available 2=InUse 4=B/W 8=Node 10=SoftPreempt 20=Node-ID):
17.1.2.2(Label=299904) 17.2.4.4(Label=299904) 17.4.5.5(Label=299904) 17.5.8.8(Label=299920) 17.7.8.7(Label=3)
9 Jul 23 05:22:41.535 Selected as active path
8 Jul 23 05:22:41.533 Self-ping ended successfully
7 Jul 23 05:22:41.305 Up
6 Jul 23 05:22:41.305 Self-ping started
5 Jul 23 05:22:41.305 Self-ping enqueued
4 Jul 23 05:22:41.305 Record Route: 17.1.2.2(Label=299904) 17.2.4.4(Label=299904) 17.4.5.5(Label=299904) 17.5.8.8(Label=299920) 17.7.8.7(Label=3)
3 Jul 23 05:22:41.252 LSP-ID: 1 created
2 Jul 23 05:22:41.252 Originate Call
1 Jul 23 05:22:41.251 CSPF: computation result accepted 17.1.2.2 17.2.4.4 17.4.5.5 17.5.8.8 17.7.8.7
Created: Thu Jul 23 05:22:41 2026
For this requirement we must use ‘include-all‘:
### Rollback and use include-all:
delete protocols mpls label-switched-path TO-R7-test
set protocols mpls label-switched-path TO-R7-test to 17.0.0.7
set protocols mpls label-switched-path TO-R7-test admin-group include-all GREEN
set protocols mpls label-switched-path TO-R7-test admin-group include-all RED
root@R1# show | compare
[edit protocols mpls label-switched-path TO-R7-test admin-group]
- include-any [ GREEN RED ];
+ include-all [ GREEN RED ];
[edit]
root@R1# commit
commit complete
### This time we have a logical AND, so use links which have both RED and GREEN color simultaneously.
### Now we have our long crazy path:
root@R1# run show mpls lsp name TO-R7-test extensive
Ingress LSP: 2 sessions
17.0.0.7
From: 17.0.0.1, State: Up, ActiveRoute: 0, LSPname: TO-R7-test, LSPid: 4
ActivePath: (primary)
LSPtype: Static Configured, Penultimate hop popping
LoadBalance: Random
Follow destination IGP metric
Encoding type: Packet, Switching type: Packet, GPID: IPv4
LSP Self-ping Status : Enabled
*Primary State: Up
Priorities: 7 0
SmartOptimizeTimer: 180
Include All: RED GREEN
Flap Count: 1
MBB Count: 0
Computed ERO (S [L] denotes strict [loose] hops): (CSPF metric: 7000)
17.1.2.2 S 17.2.3.3 S 17.3.4.4 S 17.4.5.5 S 17.5.6.6 S 17.6.8.8 S 17.7.8.7 S
Received RRO (ProtectionFlag 1=Available 2=InUse 4=B/W 8=Node 10=SoftPreempt 20=Node-ID):
17.1.2.2(Label=299920) 17.2.3.3(Label=300016) 17.3.4.4(Label=299920) 17.4.5.5(Label=299920) 17.5.6.6(Label=300016) 17.6.8.8(Label=299936) 17.7.8.7(Label=3)
20 Jul 23 05:30:29.795 Selected as active path
19 Jul 23 05:30:29.793 Self-ping ended successfully
18 Jul 23 05:30:29.405 Up
17 Jul 23 05:30:29.405 Self-ping started
16 Jul 23 05:30:29.405 Self-ping enqueued
15 Jul 23 05:30:29.405 Record Route: 17.1.2.2(Label=299920) 17.2.3.3(Label=300016) 17.3.4.4(Label=299920) 17.4.5.5(Label=299920) 17.5.6.6(Label=300016) 17.6.8.8(Label=299936) 17.7.8.7(Label=3)
14 Jul 23 05:30:29.313 LSP-ID: 2 created
13 Jul 23 05:30:29.313 Originate Call
12 Jul 23 05:30:29.313 CSPF: computation result accepted 17.1.2.2 17.2.3.3 17.3.4.4 17.4.5.5 17.5.6.6 17.6.8.8 17.7.8.7
[...]
Created: Thu Jul 23 05:22:41 2026
Total 1 displayed, Up 1, Down 0
Egress LSP: 1 sessions
Total 0 displayed, Up 0, Down 0
Transit LSP: 0 sessions
Total 0 displayed, Up 0, Down 0
External Resources: