LDP label advertisement control (filtering)
By default LDP allocates and advertises a label for every prefix the IGP knows. What is actually needed is only the /32 loopbacks that BGP uses as next hops. This article explains the three points where you can stop a label, and which router moves to recover a binding once a filter is relaxed, then verifies both on an IOS XR (XRd) lab. For the basics, see What is LDP.
What should be filtered
When MPLS carries a packet, the transport label the ingress PE pushes belongs to the LSP towards the BGP next hop, that is the remote PE’s loopback. The core link subnets are traversed but never become a next hop, so they do not need a label.
LDP still advertises all of them because the specification does not define what to advertise. Section 2.6.3 of RFC 5036 only defines Downstream Unsolicited and Downstream on Demand, that is when to advertise: there is no filtering mechanism in the protocol. What to advertise is local policy, decided per implementation.
There are three reasons to filter: a smaller label table, fewer LDP messages, and no unintended LSPs.
The three control points
A label flows in this order: allocate it in your own LIB, advertise it to the peer, and the peer accepts it. IOS XR can stop it at each of those three points.
| Control point | Where it stops | Effect |
|---|---|---|
label allocate | Before allocation | No local label is created. The LIB itself shrinks |
label advertise | At advertisement | The label exists but is not sent. Can differ per peer |
label remote accept | At reception | Received bindings are discarded. Decided by the receiver alone |
Use label allocate to shrink your own label table, label advertise to hide labels from a particular peer, and label remote accept when you cannot rely on the other end being configured.
All three live under label inside address-family ipv4 of mpls ldp, split into local (what you allocate and advertise) and remote (what you accept). The filter takes an IP access list, not a route policy, and the peer is given as an LDP identifier that includes the label space number, such as 3.3.3.3:0.
mpls ldp
address-family ipv4
label
local
allocate for <access-list> <- stop before allocation
advertise
to <LDP-Id> for <access-list> <- choose what to send per peer
remote
accept
from <LDP-Id> for <access-list> <- discard on receptionallocate for also takes the keyword host-routes, which means “/32 only” without writing an access list.
When a filter is relaxed, the router that moves is not the one that filtered
Tightening a filter takes effect immediately at any of the three points. Filtering on the sending side sends Label Withdrawals; filtering on the receiving side discards what is already held, on the spot.
Relaxing it also takes effect, but a different router moves. LDP is Downstream Unsolicited: it advertises once when something changes and never re-sends periodically. Waiting therefore brings nothing back.
| Relaxed control point | Who moves | Messages on the wire |
|---|---|---|
label advertise (sending side) | The sender re-evaluates what it advertises | Label Mapping |
label remote accept (receiving side) | The receiver asks the peer to send them again | Label Request, then Label Mapping |
The receiver cannot restore a binding it has discarded. It therefore sends a Label Request message (section 3.5.8 of RFC 5036) carrying a Typed Wildcard FEC element (section 3 of RFC 5918), which means “please send every binding of this FEC type again”. Section 4 of RFC 5918 states that receiving such a Label Request is interpreted as a request to send Label Mappings for all FECs of that type.
Whether this request is available at all is decided when the session comes up. Unless both ends exchange the Typed Wildcard FEC Capability (0x050B, section 5 of RFC 5918) in the Initialization message, the request cannot be used, and against a peer that does not support it you have to re-establish the session with clear mpls ldp neighbor to get the bindings back.
Lab topology
A chain with no redundancy. The core (PE1 - P1 - P2 - PE2) runs OSPF and LDP, and CE1 and CE2 attach to the PEs in VRF CUST-A and reach each other over VPNv4.
CE1 ------ PE1 ------ P1 ------ P2 ------ PE2 ------ CE2
(AS 65101) | | (AS 65102)
vrf CUST-A vrf CUST-A
+------ iBGP vpnv4 (Lo0) ------+| Router | Lo0 | Role | Link | Subnet |
|---|---|---|---|---|
| CE1 | 1.1.1.1 | AS 65101, 192.168.1.0/24 | CE1 - PE1 | 10.1.2.0/24 (VRF) |
| PE1 | 2.2.2.2 | Ingress/egress LSR, vrf CUST-A | PE1 - P1 | 10.2.3.0/24 |
| P1 | 3.3.3.3 | Transit LSR | P1 - P2 | 10.3.4.0/24 |
| P2 | 4.4.4.4 | Transit LSR | P2 - PE2 | 10.4.5.0/24 |
| PE2 | 5.5.5.5 | Ingress/egress LSR, vrf CUST-A | PE2 - CE2 | 10.5.6.0/24 (VRF) |
| CE2 | 6.6.6.6 | AS 65102, 192.168.2.0/24 |
The global OSPF knows seven prefixes: four /32 loopbacks and three /24 core links. The PE - CE links live in the VRF, never enter the global OSPF, and so never get a label.
Overview of the verification
| STEP | Operation | What it checks |
|---|---|---|
| 0 | Initial state | All seven prefixes have a label; reachability and the label stack |
| 1 | label allocate filters to /32 only (four core routers) | The LIB shrinks from 7 to 4. Reachability does not change |
| 2 | label advertise filters what P1 sends to PE1 | PE1 holds one label while P2, which is not filtered, still holds four |
| 3 | Remove the filter on the sending side (no clear) | P1 re-advertises on its own and the count returns to four |
| 4 | Re-establish the session with clear mpls ldp neighbor | Nothing changes, because it already recovered |
| 5 | label remote accept filters what PE1 accepts | PE1 holds one label, while four are still on the wire |
| 6 | Remove everything | The count returns to seven |
| 7 | Re-apply label allocate (four core routers) | The LIB is back to four |
| 8 | Re-apply label remote accept (PE1) | PE1 holds one label |
| 9 | Remove the filter on the receiving side (no clear) | PE1 sends a Label Request and the count returns to four |
| 10 | Re-establish the session with clear mpls ldp neighbor | Nothing changes, because it already recovered |
| 11 | Remove everything (final state) | Identical to STEP 0 |
Every STEP clears the counters first, then runs ping 192.168.2.1 source 192.168.1.1 count 50 timeout 1 and traceroute from CE1, and collects the show output afterwards.
STEP 0: by default every prefix gets a label
The local bindings on P1. Four /32 loopbacks and three /24 links, all seven with a label.
RP/0/RP0/CPU0:P1#show mpls ldp bindings local
Sun Oct 11 15:59:38.563 UTC
2.2.2.2/32, rev 11
Local binding: label: 24000
3.3.3.3/32, rev 7
Local binding: label: ImpNull
4.4.4.4/32, rev 12
Local binding: label: 24001
5.5.5.5/32, rev 14
Local binding: label: 24003
10.2.3.0/24, rev 8
Local binding: label: ImpNull
10.3.4.0/24, rev 9
Local binding: label: ImpNull
10.4.5.0/24, rev 13
Local binding: label: 24002The forwarding table puts a number on the unused /24 label. The counters were cleared before the ping, so these are this STEP’s own values: the label for 10.4.5.0/24 has switched 0 bytes.
RP/0/RP0/CPU0:P1#show mpls forwarding
Sun Oct 11 15:59:39.027 UTC
Local Outgoing Prefix Outgoing Next Hop Bytes
Label Label or ID Interface Switched
------ ----------- ------------------ ------------ --------------- ------------
24000 Pop 2.2.2.2/32 Gi0/0/0/0 10.2.3.2 29883
24001 Pop 4.4.4.4/32 Gi0/0/0/1 10.3.4.4 5750
24002 Pop 10.4.5.0/24 Gi0/0/0/1 10.3.4.4 0
24003 24003 5.5.5.5/32 Gi0/0/0/1 10.3.4.4 29817STEP 1: stop before allocation (label allocate)
The four core routers get an access list that permits only the /32 loopbacks, plus allocate for.
ipv4 access-list LDP-LOOPBACKS
10 permit ipv4 host 2.2.2.2 any
20 permit ipv4 host 3.3.3.3 any
30 permit ipv4 host 4.4.4.4 any
40 permit ipv4 host 5.5.5.5 any
!
mpls ldp
address-family ipv4
label
local
allocate for LDP-LOOPBACKS
!
!
!
!The LIB drops from seven prefixes to four. Only the label is gone; the route is not.
RP/0/RP0/CPU0:P1#show mpls ldp bindings summary
Sun Oct 11 16:06:11.105 UTC
LIB Summary:
Total Prefix : 4
Revision No : Current:17, Advertised:17
Local Bindings : 4
NULL : 1 (implicit:1, explicit:0)
Non-NULL: 3 (lowest:24000, highest:24003)
Remote Bindings: 810.4.5.0/24 is still in the OSPF routing table. Packets towards a prefix without a label are simply forwarded as plain IP, with no label pushed.
RP/0/RP0/CPU0:P1#show route ospf
Sun Oct 11 16:05:56.993 UTC
O 2.2.2.2/32 [110/2] via 10.2.3.2, 00:17:45, GigabitEthernet0/0/0/0
O 4.4.4.4/32 [110/2] via 10.3.4.4, 00:17:42, GigabitEthernet0/0/0/1
O 5.5.5.5/32 [110/3] via 10.3.4.4, 00:17:31, GigabitEthernet0/0/0/1
O 10.4.5.0/24 [110/2] via 10.3.4.4, 00:17:42, GigabitEthernet0/0/0/1Filtering does not change the forwarding
This is the core of the article. The traceroute from CE1 to CE2 goes through exactly the same label stack as in STEP 0.
RP/0/RP0/CPU0:CE1#traceroute 192.168.2.1 source 192.168.1.1 timeout 1 probe 2 maxttl 6
Sun Oct 11 15:57:23.406 UTC
Type escape sequence to abort.
Tracing the route to 192.168.2.1
1 10.1.2.2 9 msec 5 msec
2 10.2.3.3 [MPLS: Labels 24003/24005 Exp 0] 23 msec 46 msec
3 10.3.4.4 [MPLS: Labels 24003/24005 Exp 0] 21 msec 17 msec
4 10.4.5.5 [MPLS: Label 24005 Exp 0] 20 msec 38 msec
5 10.5.6.6 25 msec *RP/0/RP0/CPU0:CE1#traceroute 192.168.2.1 source 192.168.1.1 timeout 1 probe 2 maxttl 6
Sun Oct 11 16:03:53.034 UTC
Type escape sequence to abort.
Tracing the route to 192.168.2.1
1 10.1.2.2 8 msec 6 msec
2 10.2.3.3 [MPLS: Labels 24003/24005 Exp 0] 20 msec 16 msec
3 10.3.4.4 [MPLS: Labels 24003/24005 Exp 0] 16 msec 16 msec
4 10.4.5.5 [MPLS: Label 24005 Exp 0] 15 msec 27 msec
5 10.5.6.6 19 msec *The two-level stack of transport label 24003 (towards 5.5.5.5/32) and VPN label 24005 is unchanged, and P2 still performs PHP on the transport label.
| STEP | Prefixes in the LIB (P1) | Labels PE1 received from P1 | CE1 to CE2 ping |
|---|---|---|---|
| 0 | 7 | 7 | 100% (50/50) |
| 1 | 4 | 4 | 100% (50/50) |
| 2 | 4 | 1 | 100% (50/50) |
| 3 | 4 | 4 | 100% (50/50) |
| 4 | 4 | 4 | 100% (50/50) |
| 5 | 4 | 1 | 100% (50/50) |
| 6 | 7 | 7 | 100% (50/50) |
| 7 | 4 | 4 | 100% (50/50) |
| 8 | 4 | 1 | 100% (50/50) |
| 9 | 4 | 4 | 100% (50/50) |
| 10 | 4 | 4 | 100% (50/50) |
| 11 | 7 | 7 | 100% (50/50) |
Cutting the labels by 40% does not drop a single packet.
STEP 2: stop at advertisement (label advertise)
P1 narrows what it sends to PE1 only down to 5.5.5.5/32. Nothing changes towards P2.
ipv4 access-list LDP-PE2-ONLY
10 permit ipv4 host 5.5.5.5 any
!
mpls ldp
address-family ipv4
label
local
advertise
to 2.2.2.2:0 for LDP-PE2-ONLY
!
!
!
!
!Although both peer with the same P1, PE1 receives one label while P2 still receives four. The Labels column shows it.
RP/0/RP0/CPU0:PE1#show mpls ldp neighbor brief
Sun Oct 11 16:10:54.641 UTC
Peer GR NSR Up Time Discovery Addresses Labels
ipv4 ipv6 ipv4 ipv6 ipv4 ipv6
----------------- -- --- ---------- ---------- ---------- ------------
3.3.3.3:0 N N 00:22:36 1 0 3 0 1 0RP/0/RP0/CPU0:P2#show mpls ldp neighbor brief
Sun Oct 11 16:12:56.915 UTC
Peer GR NSR Up Time Discovery Addresses Labels
ipv4 ipv6 ipv4 ipv6 ipv4 ipv6
----------------- -- --- ---------- ---------- ---------- ------------
3.3.3.3:0 N N 00:24:40 1 0 3 0 4 0
5.5.5.5:0 N N 00:24:28 1 0 2 0 4 0The moment the configuration is committed, P1 sends three Label Withdrawals to PE1. It is the only label message P1 sends in this STEP’s capture.
$ tshark -r - -Y 'frame.number==8' -T fields -E header=y \
-e ip.src -e ldp.msg.type -e ldp.msg.tlv.fec.pfval -e ldp.msg.tlv.generic.label \
< mpls-ldp-filtering-step2-pe1p1.pcap
ip.src ldp.msg.type ldp.msg.tlv.fec.pfval ldp.msg.tlv.generic.label
3.3.3.3 0x0402,0x0402,0x0402 3.3.3.3,2.2.2.2,4.4.4.4 3,24000,24001PE1 no longer holds them because P1 stopped sending them.
STEP 5: stop at reception (label remote accept)
This time PE1 narrows what it accepts. P1 has no advertisement filter: the one from STEP 2 was removed in STEP 3.
ipv4 access-list LDP-PE2-ONLY
10 permit ipv4 host 5.5.5.5 any
!
mpls ldp
address-family ipv4
label
remote
accept
from 3.3.3.3:0 for LDP-PE2-ONLY
!
!
!
!
!Seen from PE1, the result is indistinguishable from STEP 2. The three prefixes that the access list does not permit show No remote bindings.
RP/0/RP0/CPU0:PE1#show mpls ldp bindings
Sun Oct 11 16:30:12.897 UTC
2.2.2.2/32, rev 2
Local binding: label: ImpNull
No remote bindings
3.3.3.3/32, rev 7
Local binding: label: 24000
No remote bindings
4.4.4.4/32, rev 11
Local binding: label: 24002
No remote bindings
5.5.5.5/32, rev 14
Local binding: label: 24004
Remote bindings: (1 peers)
Peer Label
----------------- ---------
3.3.3.3:0 24003The difference is on the wire. Right after the filter is committed, PE1 discards what it held and asks for everything to be sent again (the request itself is examined in a later section); P1 answers with all four Label Mappings, and PE1 discards three of them after receiving them.
$ tshark -r - -Y 'frame.number==50' -T fields -E header=y \
-e ip.src -e ldp.msg.type -e ldp.msg.tlv.fec.pfval -e ldp.msg.tlv.generic.label \
< mpls-ldp-filtering-step5-pe1p1.pcap
ip.src ldp.msg.type ldp.msg.tlv.fec.pfval ldp.msg.tlv.generic.label
3.3.3.3 0x0400,0x0400,0x0400,0x0400 3.3.3.3,2.2.2.2,4.4.4.4,5.5.5.5 3,24000,24001,24003The numbers in show are the same, but no bandwidth and no message processing has been saved. If you can change the other end’s configuration, stopping at advertise is the better choice.
| Where to stop | LDP messages | When to use it |
|---|---|---|
advertise (sending side) | Not sent | When you control the advertising side |
remote accept (receiving side) | Sent, then discarded | When you cannot rely on the peer, or want the receiver to decide alone |
Which side moves when a filter is relaxed
As described above, the router that moves depends on the control point. In both cases the prerequisite is that the Typed Wildcard FEC Capability was exchanged when the session came up. The Initialization message carries the 0x050B TLV, and the same message fixes the advertisement discipline as Downstream Unsolicited.
Common Session Parameters
00.. .... = TLV Unknown bits: Known TLV, do not Forward (0x0)
TLV Type: Common Session Parameters (0x500)
TLV Length: 14
Parameters
Session Protocol Version: 1
Session KeepAlive Time: 180
0... .... = Session Label Advertisement Discipline: Downstream Unsolicited proposed
.0.. .... = Session Loop Detection: Loop Detection Disabled
Session Path Vector Limit: 0
Session Max PDU Length: 0
Session Receiver LSR Identifier: 3.3.3.3
Session Receiver Label Space Identifier: 0
P2MP Capability Parameter
10.. .... = TLV Unknown bits: Unknown TLV, do not Forward (0x2)
TLV Type: P2MP Capability Parameter (0x508)
TLV Length: 1
TLV Value: 80
MP2MP Capability Parameter
10.. .... = TLV Unknown bits: Unknown TLV, do not Forward (0x2)
TLV Type: MP2MP Capability Parameter (0x509)
TLV Length: 1
TLV Value: 80
Typed Wildcard FEC Capability
10.. .... = TLV Unknown bits: Unknown TLV, do not Forward (0x2)
TLV Type: Typed Wildcard FEC Capability (0x50B)Relax the sending side and the sender re-advertises by itself
The advertise filter added in STEP 2 is removed. The session is not re-established.
mpls ldp
address-family ipv4
label
local
advertise
no to 2.2.2.2:0 for LDP-PE2-ONLY
!
!
!
!
!Right afterwards P1 sends a Label Mapping again for each of the three prefixes it had withdrawn, on its own initiative. PE1 asked for nothing.
$ tshark -r - -Y 'frame.number==8' -T fields -E header=y \
-e ip.src -e ldp.msg.type -e ldp.msg.tlv.fec.pfval -e ldp.msg.tlv.generic.label \
< mpls-ldp-filtering-step3-pe1p1.pcap
ip.src ldp.msg.type ldp.msg.tlv.fec.pfval ldp.msg.tlv.generic.label
3.3.3.3 0x0400,0x0400,0x0400 3.3.3.3,2.2.2.2,4.4.4.4 3,24000,24001Relax the receiving side and the receiver asks the peer
The remote accept filter re-applied in STEP 8 is removed, again without re-establishing the session.
mpls ldp
address-family ipv4
label
remote
accept
no from 3.3.3.3:0 for LDP-PE2-ONLY
!
!
!
!
!PE1 sends a Label Request. tshark cannot dissect this FEC element and prints Error in FEC Element 1, but the message type is Label Request Message (0x401).
Label Request Message
0... .... = U bit: Unknown bit not set
Message Type: Label Request Message (0x401)
Message Length: 13
Message ID: 0x00000075
FEC
00.. .... = TLV Unknown bits: Known TLV, do not Forward (0x0)
TLV Type: FEC (0x100)
TLV Length: 5
FEC Elements
Error in FEC Element 1
[Expert Info (Error/Protocol): Error in FEC Element 1]
[Error in FEC Element 1]
[Severity level: Error]
[Group: Protocol]The bytes of the FEC TLV match the format in sections 3 and 6 of RFC 5918: 05 is Typed Wildcard, 02 is Prefix FEC and 02 is the length of the information that follows (one byte each), and 00 01 is the IPv4 address family.
0000 52 54 00 23 17 21 52 54 00 94 4c 69 08 00 45 c0 RT.#.!RT..Li..E.
0010 00 4b bd 7e 00 00 ff 06 f3 64 02 02 02 02 03 03 .K.~.....d......
0020 03 03 02 86 f0 b1 66 ac 48 84 a5 de 10 2b 50 18 ......f.H....+P.
0030 3e ae 81 cf 00 00 00 01 00 1f 02 02 02 02 00 00 >...............
0040 04 01 00 0d 00 00 00 75 01 00 00 05 05 02 02 00 .......u........
0050 01 02 01 00 04 00 00 00 76 ........vP1 answers by sending all four Label Mappings again.
$ tshark -r - -Y 'frame.number==49' -T fields -E header=y \
-e ip.src -e ldp.msg.type -e ldp.msg.tlv.fec.pfval -e ldp.msg.tlv.generic.label \
< mpls-ldp-filtering-step9-pe1p1.pcap
ip.src ldp.msg.type ldp.msg.tlv.fec.pfval ldp.msg.tlv.generic.label
3.3.3.3 0x0400,0x0400,0x0400,0x0400 3.3.3.3,2.2.2.2,4.4.4.4,5.5.5.5 3,24000,24001,24003The clear was not needed
STEP 4 and STEP 10 do issue clear mpls ldp neighbor, but in both the labels were already back before the command ran. The STEP 10 record shows Labels ipv4 at four immediately before the clear, with an Up Time of over 41 minutes: the session had never gone down.
RP/0/RP0/CPU0:PE1#show clock
Sun Oct 11 17:01:38.670 UTC
17:01:38.713 UTC Sun Oct 11 2026
RP/0/RP0/CPU0:PE1#show mpls ldp neighbor brief
Sun Oct 11 17:01:38.811 UTC
Peer GR NSR Up Time Discovery Addresses Labels
ipv4 ipv6 ipv4 ipv6 ipv4 ipv6
----------------- -- --- ---------- ---------- ---------- ------------
3.3.3.3:0 N N 00:41:22 1 0 3 0 4 0
RP/0/RP0/CPU0:PE1#clear mpls ldp neighbor 3.3.3.3
Sun Oct 11 17:01:38.950 UTC
RP/0/RP0/CPU0:PE1#show clock
Sun Oct 11 17:01:39.064 UTC
17:01:39.162 UTC Sun Oct 11 2026STEP 11: remove everything and return to the start
With every access list and filter removed, the LIB is back to seven prefixes.
RP/0/RP0/CPU0:P1#show mpls ldp bindings summary
Sun Oct 11 17:14:00.432 UTC
LIB Summary:
Total Prefix : 7
Revision No : Current:32, Advertised:32
Local Bindings : 7
NULL : 3 (implicit:3, explicit:0)
Non-NULL: 4 (lowest:24000, highest:24003)
Remote Bindings: 14The running-config of the final STEP is identical to STEP 0 on all six routers, compared down to the number of occurrences of each line in the collected data.
Design notes
- Filter by the BGP next hops. Besides the PE loopbacks, include any address other PEs refer to, for a route reflector or an inter-AS link. Miss one and only the LSP towards that PE fails to come up, leaving the VPN broken in one direction
allocatereally does shrink the LIB.Total Prefixinshow mpls ldp bindings summarygoes down as well. Only the label is gone; the route is not. Packets towards a filtered prefix are forwarded as plain IP with no label pushed- Filtering on the receiving side leaves the LDP messages on the wire. To save bandwidth and message processing, stop at
advertiseon the sending side - Check the peer’s implementation before relaxing a filter. Against a device that does not support the Typed Wildcard FEC (RFC 5918), the receiving side cannot request what it discarded, and you have to re-establish the session with
clear mpls ldp neighbor
Verification configs and show output
For every STEP, the following kinds of output were collected from all six routers, one file per router. The verification config is the ..._run.txt (the final state is the one from the last STEP).
| File | Content |
|---|---|
..._clear.txt | The record of the counters cleared in that STEP (clear counters interface and clear mpls forwarding counters) |
..._ping.txt | The ping (50 packets, 1-second timeout) and traceroute of that STEP |
..._show.txt | show version, show interface description, the OSPF, LDP and MPLS forwarding set, show running-config mpls ldp and so on |
..._log.txt | show logging narrowed to that STEP. A marker is written with logmsg at the start of each STEP and its timestamp is passed to show logging start |
..._run.txt | show running-config at that point in time, that is the verification config of that STEP |
..._trace.txt | show mpls ldp trace binding and peer, and show mpls lsd trace (four core routers only) |
..._commit.cfg | Only the configuration actually committed in that STEP, for the routers that were changed |
..._reset.txt | The record of clear mpls ldp neighbor (STEP 4 and 10 only) |
STEP 0: Initial state
| Router | clear | ping | show | syslog | running-config | trace |
|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — |
| PE1 | clear | ping | show | log | run | trace |
| P1 | clear | ping | show | log | run | trace |
| P2 | clear | ping | show | log | run | trace |
| PE2 | clear | ping | show | log | run | trace |
| CE2 | clear | ping | show | log | run | — |
STEP 1: label allocate filters to /32 only (four core routers)
| Router | clear | ping | show | syslog | running-config | trace | config committed |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | commit |
| P1 | clear | ping | show | log | run | trace | commit |
| P2 | clear | ping | show | log | run | trace | commit |
| PE2 | clear | ping | show | log | run | trace | commit |
| CE2 | clear | ping | show | log | run | — | — |
STEP 2: label advertise filters what P1 sends to PE1
| Router | clear | ping | show | syslog | running-config | trace | config committed |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | — |
| P1 | clear | ping | show | log | run | trace | commit |
| P2 | clear | ping | show | log | run | trace | — |
| PE2 | clear | ping | show | log | run | trace | — |
| CE2 | clear | ping | show | log | run | — | — |
STEP 3: Remove the filter on the sending side (no clear)
| Router | clear | ping | show | syslog | running-config | trace | config committed |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | — |
| P1 | clear | ping | show | log | run | trace | commit |
| P2 | clear | ping | show | log | run | trace | — |
| PE2 | clear | ping | show | log | run | trace | — |
| CE2 | clear | ping | show | log | run | — | — |
STEP 4: Re-establish the session with clear mpls ldp neighbor
| Router | clear | ping | show | syslog | running-config | trace | clear record |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | — |
| P1 | clear | ping | show | log | run | trace | reset |
| P2 | clear | ping | show | log | run | trace | — |
| PE2 | clear | ping | show | log | run | trace | — |
| CE2 | clear | ping | show | log | run | — | — |
STEP 5: label remote accept filters what PE1 accepts
| Router | clear | ping | show | syslog | running-config | trace | config committed |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | commit |
| P1 | clear | ping | show | log | run | trace | — |
| P2 | clear | ping | show | log | run | trace | — |
| PE2 | clear | ping | show | log | run | trace | — |
| CE2 | clear | ping | show | log | run | — | — |
STEP 6: Remove everything
| Router | clear | ping | show | syslog | running-config | trace | config committed |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | commit |
| P1 | clear | ping | show | log | run | trace | commit |
| P2 | clear | ping | show | log | run | trace | commit |
| PE2 | clear | ping | show | log | run | trace | commit |
| CE2 | clear | ping | show | log | run | — | — |
STEP 7: Re-apply label allocate (four core routers)
| Router | clear | ping | show | syslog | running-config | trace | config committed |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | commit |
| P1 | clear | ping | show | log | run | trace | commit |
| P2 | clear | ping | show | log | run | trace | commit |
| PE2 | clear | ping | show | log | run | trace | commit |
| CE2 | clear | ping | show | log | run | — | — |
STEP 8: Re-apply label remote accept (PE1)
| Router | clear | ping | show | syslog | running-config | trace | config committed |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | commit |
| P1 | clear | ping | show | log | run | trace | — |
| P2 | clear | ping | show | log | run | trace | — |
| PE2 | clear | ping | show | log | run | trace | — |
| CE2 | clear | ping | show | log | run | — | — |
STEP 9: Remove the filter on the receiving side (no clear)
| Router | clear | ping | show | syslog | running-config | trace | config committed |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | commit |
| P1 | clear | ping | show | log | run | trace | — |
| P2 | clear | ping | show | log | run | trace | — |
| PE2 | clear | ping | show | log | run | trace | — |
| CE2 | clear | ping | show | log | run | — | — |
STEP 10: Re-establish the session with clear mpls ldp neighbor
| Router | clear | ping | show | syslog | running-config | trace | clear record |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | reset |
| P1 | clear | ping | show | log | run | trace | — |
| P2 | clear | ping | show | log | run | trace | — |
| PE2 | clear | ping | show | log | run | trace | — |
| CE2 | clear | ping | show | log | run | — | — |
STEP 11: Remove everything (final state)
| Router | clear | ping | show | syslog | running-config | trace | config committed |
|---|---|---|---|---|---|---|---|
| CE1 | clear | ping | show | log | run | — | — |
| PE1 | clear | ping | show | log | run | trace | commit |
| P1 | clear | ping | show | log | run | trace | commit |
| P2 | clear | ping | show | log | run | trace | commit |
| PE2 | clear | ping | show | log | run | trace | commit |
| CE2 | clear | ping | show | log | run | — | — |
Packet captures were taken per STEP on two links.
| STEP | PE1 - P1 | P1 - P2 |
|---|---|---|
| 0 | pcap | pcap |
| 1 | pcap | pcap |
| 2 | pcap | pcap |
| 3 | pcap | pcap |
| 4 | pcap | pcap |
| 5 | pcap | pcap |
| 6 | pcap | pcap |
| 7 | pcap | pcap |
| 8 | pcap | pcap |
| 9 | pcap | pcap |
| 10 | pcap | pcap |
| 11 | pcap | pcap |
References
| Source | What was referenced |
|---|---|
| RFC 5036 LDP Specification | Section 2.6.3 (Downstream Unsolicited / on Demand) and 3.5.8 (Label Request Message); confirmation that the RFC defines no filtering of label advertisement |
| RFC 5918 LDP ‘Typed Wildcard’ FEC | Section 3 (format of the Typed Wildcard FEC element), 4 (how a Label Request carrying it is interpreted), 5 (the 0x050B capability TLV), 6 (the format for the Prefix FEC) |
| IOS XR MPLS Configuration Guide | Syntax of label allocate, label advertise and label remote accept |
The verification was carried out on XRd 26.1.1 (Cisco Modeling Labs).
- What Is MPLS
- MPLS Labels and the Label Stack
- MPLS Label Operations (push / swap / pop) and PHP
- MPLS TTL Processing and MTU
- What Is LDP
- LDP Label Distribution Modes and Label Spaces
- LDP-IGP Synchronization and LDP Session Protection
- LDP label advertisement control (filtering)
- LDP session authentication (TCP MD5)
- MPLS OAM (LSP ping and LSP traceroute)
- What Is MPLS TE (RSVP-TE)
- MPLS TE CSPF and Path Constraints (Bandwidth, Affinity, TE Metric)
- Steering Traffic into MPLS TE Tunnels
- MPLS TE Fast Reroute (Link and Node Protection)
- MPLS TE Fast Reroute (Auto-Tunnel Backup and SRLG)
- MPLS QoS (EXP and Uniform / Pipe / Short-Pipe)
- MPLS QoS Rate Control and Queuing (policer / shaper / priority)