Table Of Contents
MPLS Label Distribution Protocol Commands on Cisco IOS XR Software
clear mpls ldp msg-counters neighbor
discovery instance-tlv disable
show mpls ldp graceful-restart
show mpls ldp statistics msg-counters
MPLS Label Distribution Protocol Commands on Cisco IOS XR Software
This chapter describes the commands used to configure Label Distribution Protocol (LDP) in a Multiprotocol Label Switching (MPLS) network.
LDP provides a standard methodology for hop-by-hop (or dynamic label) distribution in an MPLS network by assigning labels to routes that have been chosen by the underlying Interior Gateway Protocol (IGP) routing protocols. The resulting labeled paths, called label switch paths (LSPs), forward labeled traffic across an MPLS backbone.
LDP also provides the means for label switching routers (LSRs) to request, distribute, and release label prefix binding information to peer routers in a network. LDP enables LSRs to discover potential peers and establish LDP sessions with those peers to exchange label binding information.
For detailed information about MPLS concepts, configuration tasks, and examples, refer to the
Cisco IOS XR MPLS Configuration Guide.backoff
To configure the parameters for the LDP backoff mechanism, use the backoff command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
backoff initial maximum
no backoff
Syntax Description
initial
Initial backoff delay in seconds. Range is 5 to 2147483 seconds.
maximum
Maximum backoff delay in seconds. Range is 5 to 2147483 seconds.
Defaults
initial: 15 seconds
maximum: 120 seconds
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The LDP backoff mechanism prevents two incompatibly-configured label switch routers from engaging in an unthrottled sequence of session setup failures. If a session setup attempt fails (due to incompatibility), each LSR delays the next attempt increasing the delay exponentially with each successive failure (until the maximum backoff delay is reached).
Task ID
Examples
The following example shows how to configure the initial backoff delay to 30 seconds and the maximum backoff delay to 240 seconds:
RP/0/RP0/CPU0:router# config
RP/0/RP0/CPU0:router(config)# mpls ldp
RP/0/RP0/CPU0:router(config-ldp)# backoff 30 240
Related Commands
Command DescriptionDisplays information about the configured session setup backoff parameters and LDP peers.
Displays current LDP parameter settings.
clear mpls ldp msg-counters neighbor
To clear the LDP message counters, use the clear mpls ldp msg-counters command in EXEC mode.
clear mpls ldp msg-counters neighbor {A.B.C.D. | all}
Syntax Description
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Use the clear mpls ldp msg-counters neighbor command to clear the statistics on message counters for a specific neighbor (IP address) or for all neighbors. These message counters count the number of LDP protocol messages sent to and received from LDP neighbors.
Task ID
Examples
The following example shows how to clear message counters for neighbor 10.20.20.20:
RP/0/RP0/CPU0:router# clear mpls ldp msg-counters neighbor 10.20.20.20
Related Commands
Command DescriptionDisplays statistics about the type and count of the messages sent and received from neighbors.
clear mpls ldp neighbor
To force LDP session restart, use the clear mpls ldp neighbor command in EXEC mode.
clear mpls ldp neighbor [A.B.C.D.]
Syntax Description
Defaults
No default behavior or values
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Use the clear mpls ldp neighbor command to restart a single LDP session or all LDP sessions (without restarting the LDP process itself).
Task ID
Examples
The following example shows how to force an unconditional LDP session restart:
RP/0/RP0/CPU0:router# clear mpls ldp neighbor 10.20.20.20
Related Commands
default-route
To enable MPLS switching for IP default route by allocating and advertising non-null label, use the default-route command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
default-route
no default-route
Syntax Description
This command has no arguments or keywords.
Defaults
Allocates null (implicit or explicit) local label for IP default route prefix 0.0.0.0/0.
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
When the IP default route 0.0.0.0/0 is configured on an egress router, it is advertised through IGP to other routers to enable default IP forwarding. When MPLS LDP is configured and establishing LSPs for other prefixes, you can emulate default forwarding and switching for MPLS in the same way as IP forwarding. To do so, allocate a non-null local label and advertise this label to its peers.
Task ID
Examples
The following example shows how to enable default MPLS switching for default prefix:
RP/0/RP0/CPU0:router(config-ldp)# default-route
Related Commands
discovery hello
To configure the interval between transmission of consecutive LDP discovery hello messages and the holdtime for a discovered LDP neighbor, use the discovery hello command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
discovery hello {holdtime seconds | interval seconds}
no discovery hello {holdtime | interval}
Syntax Description
Defaults
holdtime: 15 seconds
interval: 5 seconds
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to configure the link hello holdtime to 30 seconds:
RP/0/RP0/CPU0:router(config-ldp)# discovery hello holdtime 30
The following example shows how to configure the link hello interval to 10 seconds:
RP/0/RP0/CPU0:router(config-ldp)# discovery hello interval 10
Related Commands
discovery instance-tlv disable
To disable transmit and receive processing for TLV, use the discovery instance-tlv disable command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
discovery instance-tlv disable
no discovery instance-tlv disable
Syntax Description
This command has no arguments or keywords.
Defaults
No default behavior or values
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to disable transmit and receive processing for TLV:
RP/0/RP0/CPU0:router# configureRP/0/RP0/CPU0:router(config)# mpls ldp
RP/0/RP0/CPU0:router(config-ldp)# discovery hello holdtime 30
Related Commands
discovery targeted-hello
To configure the interval between transmission of consecutive LDP discovery targeted-hello messages, the hold time for a discovered targeted LDP neighbor, and to accept targeted hello from peers, use the discovery targeted-hello command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
discovery targeted-hello {accept [from acl] | holdtime seconds | interval seconds}
no discovery targeted-hello {accept | holdtime | interval}
Syntax Description
Defaults
accept: Targeted hello messages are not accepted from any source (neighbor).
holdtime: 90 seconds
interval: 10 seconds
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
LDP supports IPv4 standard access lists only.
Task ID
Examples
The following example shows how to configure the targeted-hello holdtime to 45 seconds:
RP/0/RP0/CPU0:router(config-ldp)# discovery targeted-hello holdtime 45
The following example shows how to configure the targeted-hello interval to 5 seconds:
RP/0/RP0/CPU0:router(config-ldp)# discovery targeted-hello interval 5
The following example shows how to configure acceptance of targeted hellos from all peers:
RP/0/RP0/CPU0:router(config-ldp)# discovery targeted-hello acceptThe following example shows how to configure acceptance of targeted hello from peers 10.1.1.1 and 10.2.2.2 only:
RP/0/RP0/CPU0:router(config)# ipv4 access-list peer_acl_10
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 10.1.1.1
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 10.2.2.2
RP/0/RP0/CPU0:router(config-ldp)# discovery targeted-hello accept from peer_acl_10
Related Commands
discovery transport-address
To provide an alternative address for a Transmission Control Protocol (TCP) connection, use the discovery transport-address command in MPLS LDP interface configuration mode. To return to the default behavior, use the no form of this command.
discovery transport-address {A.B.C.D. | interface}
no discovery transport-address {A.B.C.D. | interface}
Syntax Description
A.B.C.D.
IP address to be advertised as the transport address in discovery hello messages.
interface
Advertises the IP address of the interface as the transport address in discovery hello messages.
Defaults
LDP advertises its LDP router ID as the transport address in LDP discovery hello messages.
Command Modes
MPLS LDP interface configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Establishing an LDP session between two routers requires a session TCP connection. To establish the session TCP connection each router must know the transport address (IP address) of the other router.
The LDP discovery mechanism provides the means for a router to advertise transport addresses. Transport address is implicit or explicit. Implicit addresses do not appear as part of the contents of the discovery hello messages sent to the peer. If explicit, the advertisement appears as part of the contents of discovery hello messages sent to the peer.
The discovery transport-address command modifies the default behavior described above. Using the interface keyword, LDP advertises the IP address of the interface in LDP discovery hello messages sent from the interface. Using the ip-address argument value, LDP advertises the IP address in LDP discovery hello messages sent from the interface.
Note When a router has multiple links connecting it to its peer device, the router must advertise the same transport address in the LDP discovery hello messages it sends on all such interfaces.
Task ID
Examples
The following example shows how to specify an exiting address (10.10.3.1) as the transport address on POS interface 0/1/0/0:
RP/0/RP0/CPU0:router(config-ldp)# interface POS 0/1/0/0RP/0/RP0/CPU0:router(config-ldp-if)# discovery transport-address 10.10.3.1RP/0/RP0/CPU0:router# show mpls ldp neighborPeer LDP Identifier: 10.44.44.44:0TCP connection: 10.44.44.44:65520 - 10.10.3.1:646Graceful Restart: Yes (Reconnect Timeout: 15 sec, Recovery: 180 sec)State: Oper; Msgs sent/rcvd: 13/9Up time: 00:00:11LDP Discovery Sources:POS 0/1/0/0Addresses bound to this peer:10.10.3.2 10.44.44.44Related Commands
Command DescriptionDisplays the status of the LDP discovery process.
Displays information about LDP neighbors.
explicit-null
To configure a router to advertise explicit null labels instead of implicit null labels, use the explicit-null command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
explicit-null {to peer-acl | for prefix-acl [to peer-acl]}
no explicit-null
Syntax Description
Defaults
Implicit null is advertised as default null label for routes such as directly connected routes.
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Normally, LDP advertises an implicit null label for directly-connected routes. The implicit null label causes the previous hop router to perform next to last router hop popping.
Run the explicit-null command to advertise explicit-null labels in place of implicit null labels for directly connected prefixes. Use mpls ldp explicit-null command when running in global configuration mode.
LDP supports IPv4 standard access lists only.
Task ID
Examples
The following command shows how to advertise explicit null for all directly connected routes to all LDP peers:
RP/0/RP0/CPU0:router(config-ldp)# explicit-null
The following command sequence shows how to advertise explicit-null for directly connected route192.168.0.0 to all LDP peers and implicit-null for all other directly connected routes:
RP/0/RP0/CPU0:router(config)# ipv4 access-list pfx_acl_192_168
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 192.168.0.0
RP/0/RP0/CPU0:router(config-ldp)# explicit-null for pfx_acl_192_168
The following command sequence shows how to send explicit-null for all directly connected routes to peers 10.1.1.1 and 10.2.2.2 and implicit-null to all other peers:
RP/0/RP0/CPU0:router(config)# ipv4 access-list peer_acl_10
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 10.1.1.1
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 10.2.2.2
RP/0/RP0/CPU0:router(config-ldp)# explicit-null to peer_acl_10
The following command shows how to advertise explicit-null for prefix 192.168.0.0 to peers 10.1.1.1 and 10.2.2.2 and advertise implicit-null for all other applicable routes to all other peers:
RP/0/RP0/CPU0:router(config-ldp)# explicit-null for pfx_acl_192_168 to peer_acl_10
Related Commands
Command DescriptionDisplays the contents of LDP label information base (LIB).
Displays the contents of the LDP forwarding database.
Displays current LDP parameter settings.
graceful-restart (MPLS LDP)
To configure graceful restart, use the graceful-restart command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
graceful-restart [reconnect-timeout seconds | forwarding-state-holdtime seconds]
no graceful-restart [reconnect-timeout | forwarding-state-holdtime]
Syntax Description
Defaults
By default, graceful restart is disabled.
reconnect-timeout: 120 seconds
forwarding-state-holdtime: 180 seconds
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Use the LDP graceful restart capability to achieve nonstop forwarding (NSF) during an LDP control plane communication failure or restart. To configure graceful restart between two peers, enable LDP graceful restart on both label switching routers (LSRs).
When an LDP graceful restart session is established and there is control plane failure, the peer LSR starts graceful restart procedures, initially keeps the forwarding state information pertaining to the restarting peer, and marks this state as stale. If the restarting peer does not reconnect within the reconnect timeout, the stale forwarding state is removed. If the restarting peer reconnects within the reconnect time period, it is provided recovery time to resynchronize with its peer. After this time, any unsynchronized state is removed.
The value of the forwarding state hold time keeps the forwarding plane state associated with the LDP control-plane in case of a control-plane restart or failure. If the control plane fails, the forwarding plane retains the LDP forwarding state for twice the forwarding state hold time. The value of the forwarding state hold time is also used to start the local LDP forwarding state hold timer after the LDP control plane restarts. When the LDP graceful restart sessions are renegotiated with its peers, the restarting LSR sends the remaining value of this timer as the recovery time to its peers. Upon local LDP restart with graceful restart enabled, LDP does not replay forwarding updates to MPLS forwarding until the forwarding state hold timer expires.
Note In the presence of a peer relationship, any change to the LDP graceful restart configuration will restart LDP sessions. If LDP configuration changes from non graceful restart to graceful restart, all the sessions are restarted. Only graceful restart sessions are restarted upon graceful restart to non graceful restart configuration changes.
Task ID
Examples
The following example shows how to configure an existing session for graceful restart:
RP/0/RP0/CPU0:router(config-ldp)# graceful-restart
The following example shows how to configure an existing session for graceful restart:
RP/0/RP0/CPU0:router(config-ldp)# graceful-restart
RP/0/RP0/CPU0:Apr 3 10:56:05.392 : mpls_ldp[336]: %ROUTING-LDP-5-NBR_CHANGE : Nbr 2.2.2.2:0, DOWNRP/0/RP0/CPU0:Apr 3 10:56:05.392 : mpls_ldp[336]: %ROUTING-LDP-5-NBR_CHANGE : Nbr 3.3.3.3:0, DOWNRP/0/RP0/CPU0:Apr 3 10:56:09.525 : mpls_ldp[336]: %ROUTING-LDP-5-NBR_CHANGE : Nbr 3.3.3.3:0, UPRP/0/RP0/CPU0:Apr 3 10:56:11.114 : mpls_ldp[336]: %ROUTING-LDP-5-NBR_CHANGE : Nbr 2.2.2.2:0, UPRP/0/RP0/CPU0:router# show mpls ldp neighbor brief
vPeer GR Up Time Discovery Address----------------- -- --------------- --------- -------3.3.3.3:0 Y 00:01:04 3 82.2.2.2:0 N 00:01:02 2 5RP/0/RP0/CPU0:router# show mpls ldp graceful-restart
Forwarding State Hold timer : Not RunningGR Neighbors : 1Neighbor ID Up Connect Count Liveness Timer Recovery Timer--------------- -- ------------- ------------------ ------------------3.3.3.3 Y 1 - -Related Commands
holdtime (MPLS LDP)
To change the time for which an LDP session is maintained in the absence of LDP messages from the session peer, use the holdtime command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
holdtime seconds
no holdtime
Syntax Description
seconds
Time that an LDP session is maintained in the absence of LDP messages from the session peer. Range is 15 to 65535 seconds.
Defaults
seconds: 180
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to change the hold time of LDP sessions to 30 seconds:
RP/0/RP0/CPU0:router(config-ldp)# holdtime 30
Related Commands
igp auto-config disable
To disable LDP auto-configuration, use the igp auto-config disable command in MPLS LDP interface configuration mode. To return to the default behavior, use the no form of this command.
igp auto-config disable
Syntax Description
This command has no arguments or keywords.
Defaults
No default behavior or values
Command Modes
MPLS LDP interface configuration
Command History
Release ModificationRelease 3.5.0
This command was introduced on the Cisco CRS-1 and Cisco XR 12000 Series Router.
Release 3.6.0
No modification.
Release 3.7.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
IGP auto-configuration can be enabled on ISIS and OSPF. Configuration details are described in
Cisco IOS XR Routing Configuration Guide, Release 3.5.Task ID
Examples
The following example shows how to disable LDP auto-configuration on POS 0/1/0/3:
RP/0/RP0/CPU0:router(config)# mpls ldp
RP/0/RP0/CPU0:router(config-ldp)# interface pos 0/1/0/3RP/0/RP0/CPU0:router(config-ldp-if)# igp auto-config disableRelated Commands
igp sync delay
To enable LDP IGP sync delay timer feature, use the igp sync delay command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
igp sync delay seconds
no igp sync delay
Syntax Description
seconds
Time that declaration of LDP sync state being up is delayed after session establishment upon link coming up. Range is 5 to 60 seconds.
Defaults
LDP does not delay declaration of sync up and notifies IGP as soon sync up conditions are met for a link.
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
By default, LDP declares LDP sync up as soon as all the requisite conditions are met; namely:
•an LDP session is up
•LDP has sent all its label bindings to at least one peer
•LDP has received at least one label binding from a peer
This minimizes traffic loss on link up but can still lead to substantial traffic loss under certain circumstances (for example, when interoperating with an LSR with ordered mode operation). It may be necessary to delay declaration of sync up after the session comes up by configuring a timeout period.
Task ID
Examples
The following example shows how to configure LDP to delay declaration of sync-up to 30 seconds:
RP/0/RP0/CPU0:router# configure
RP/0/RP0/CPU0:router(config)# mpls ldp
RP/0/RP0/CPU0:router(config-ldp)# igp sync delay 30
Related Commands
interface (MPLS LDP)
To configure or enable MPLS LDP on an interface, use the interface command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
interface type interface-id
no interface type interface-id
Syntax Description
Defaults
No default behavior or values
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
When you configure LDP on an interface, the LDP process begins neighbor discovery, sending link hello messages on the interface. This can result in a session setup with discovered neighbors. When LDP is enabled on tunnel-te interfaces, targeted discovery procedures apply.
LDP interface configuration supports forward reference; accordingly, it is possible to configure a nonexisting interface under LDP.
Note You cannot enable LDP on loopback interfaces.
Task ID
Examples
The following example shows how to configure LDP on POS interface 0/1/0/0:
RP/0/RP0/CPU0:router(config-ldp)# interface POS 0/1/0/0
RP/0/RP0/CPU0:router(config-ldp-if)#The following example shows how to configure LDP on an MPLS TE tunnel:
RP/0/RP0/CPU0:router(config-ldp)# interface tunnel-te 123
RP/0/RP0/CPU0:router(config-ldp-if)#Related Commands
Command DescriptionDisplays current LDP parameter settings.
Displays LDP neighbor session parameters
label accept
To control the receipt of labels (remote bindings) for a set of prefixes from a peer, use the label accept command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
label accept for prefix-acl from A.B.C.D
no label accept for prefix-acl from A.B.C.D
Syntax Description
for prefix-acl
Accept and retain remote bindings for prefixes which are permitted by the prefix access list prefix-acl.
from A.B.C.D
Peer IP address.
Defaults
LDP accepts and retains label bindings for all prefixes from all peers.
Command Modes
MPLS LDP configuration
Command History
Release ModificationRelease 3.3.0
This command was introduced.
Release 3.4.0
No modification.
Release 3.5.0
No modification.
Release 3.6.0
No modification.
Release 3.7.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
By default, LDP accepts labels (as remote bindings) for all prefixes from all its peers. To save resources (such as memory) configure the access list to specify label and binding acceptance for a set of prefixes from a peer.
If the inbound label filtering policy changes such that it now allows previously-denied prefixes from a peer, you must reset the LDP session with the peer using the clear mpls ldp neighbor command.
LDP supports IPv4 standard access lists only.
Note Label acceptance control is also referred to as LDP inbound label filtering.
Task ID
Examples
Following example shows how to configure inbound label filtering policy. In this example, an LSR is configured to accept and retain label bindings for prefixes 192.168.1.1 (pfx_acl_1) from peer 1.1.1.1, prefix 192.168.2.2 (pfx_acl_2) from peer 2.2.2.2, and prefixes 192.168.1.1, 192.168.2.2, 192.168.3.3 (pfx_acl_3) from peer 3.3.3.3:
RP/0/RP0/CPU0:router(config-ldp)# label acceptRP/0/RP0/CPU0:router(config-ldp-lbl-acpt)# for pfx_acl_1 from 1.1.1.1RP/0/RP0/CPU0:router(config-ldp-lbl-acpt)# for pfx_acl_2 from 2.2.2.2RP/0/RP0/CPU0:router(config-ldp-lbl-acpt)# for pfx_acl_3 from 3.3.3.3Related Commands
Command DescriptionControls advertisement of LDP local label bindings (Outbound label filtering)
Resets LDP neighbor sessions.
Displays LDP binding information
label advertise
To control the advertisement of local labels, use the label advertise command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
label advertise {disable | for prefix-acl [to peer-acl] | interface interface}
no label advertise {disable | for prefix-acl [to peer-acl] | interface interface}
Syntax Description
Defaults
LDP advertises labels for all known prefixes to all peers. LDP does not advertise labels for local interfaces addresses other than Loopback interfaces.
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The label advertise command determines how the LSR advertises local labels. The following rules describe the effects of running multiple commands:
•Every command has a prefix- or peer-acl pair associated with it, as follows:
–In the absence of the for or to keywords, the access list pair is (none, none).
–When using the for keyword without the to keyword, the access list is (prefix-acl, none).
•A prefix can have a maximum of one (prefix-acl, peer-acl) pair, as described below:
–A (prefix-acl, peer-acl) pair applies to a prefix only if the prefix-acl matches the prefix. A match occurs if the prefix acl permits the prefix.
–If more than one (prefix acl, peer acl) pair from multiple label advertise commands matches a prefix, the (prefix-acl, peer-acl) pair in the first command applies to the prefix.
•When an LSR is ready to advertise a label for a prefix, the LSR determines whether a (prefix-acl, peer-acl) pair applies to the prefix.
–If none applies, and if the disable form of the command has been configured, the label for the prefix is not advertised to any peer; otherwise, the label is advertised to all peers.
–If a (prefix-acl, peer-acl) pair applies to the prefix, and if the prefix-acl denies the prefix, the label is not advertised to any peer.
–If the prefix-acl permits the prefix and the peer-acl is none (that is, the command that applies to the prefix is an label advertise for prefix-acl command without the to keyword), the label is advertised to all peers.
–If the prefix-acl permits the prefix and there is a peer-acl, the label is advertised to all peers permitted by the peer-acl.
Normally, LDP advertises labels for non-BGP routes present in the routing table. Additionally, LDP advertises labels from /32 IP addresses on Loopback interfaces and does not advertise /32 addresses for other non-Loopback interfaces. To control advertisement of labels for /32 IP addresses on these interfaces, use the label advertise interface command.
LDP supports IPv4 standard access lists only.
Note Label advertisement control is also referred to as LDP outbound label filtering.
Task ID
Examples
The following example shows how to disable advertisement of all locally assigned labels to all peers:
RP/0/RP0/CPU0:router(config-ldp)# label advertise
RP/0/RP0/CPU0:router(config-ldp-lbl-advt)# disable
The following example shows how to send labels only for prefixes 10.1.1.0 and 20.1.1.0 to all peers:
RP/0/RP0/CPU0:router(config)# ipv4 access-list pfx_acl_1
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 10.1.1.0
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 20.1.1.0
RP/0/RP0/CPU0:router(config-ldp)# label advertise
RP/0/RP0/CPU0:router(config-ldp-lbl-advt)# disable
RP/0/RP0/CPU0:router(config-ldp-lbl-advt)# for pfx_acl_1
The following example shows how to send labels for prefix 10.0.0.0 to peers 10.1.1.1 and 10.2.2.2, labels for prefix 20.0.0.0 to peer 20.1.1.1, and labels for all other prefixes to all other peers:
RP/0/RP0/CPU0:router(config)# ipv4 access-list pfx_acl_10
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 10.0.0.0
RP/0/RP0/CPU0:router(config)# ipv4 access-list pfx_acl_20
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 20.0.0.0
RP/0/RP0/CPU0:router(config)# ipv4 access-list peer_acl_10
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 10.1.1.1
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 10.2.2.2
RP/0/RP0/CPU0:router(config)# ipv4 access-list peer_acl_20
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 20.1.1.1
RP/0/RP0/CPU0:router(config-ldp)# label advertise
RP/0/RP0/CPU0:router(config-ldp-lbl-advt)# for pfx_acl_10 to peer_acl_10
RP/0/RP0/CPU0:router(config-ldp-lbl-advt)# for pfx_acl_20 to peer_acl_20
Note To advertise pfx_acl_10 to peer_acl_10 and pfx_acl_20 to peer_acl_20 and disable all other advertisements to all other peers, include the disable keyword with label advertise.
The following example shows how to use the interface keyword to advertise /32 IP address for POS 0/1/0/0:
RP/0/RP0/CPU0:router(config-ldp)# label advertise
RP/0/RP0/CPU0:router(config-ldp-lbl-advt)# interface POS 0/1/0/0
Related Commands
Command DescriptionDisplays information about LDP neighbors.
Displays information about LDP label bindings.
label allocate
To control allocation of local label only for a set of prefixes, use the label allocate command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
label allocate for prefix-acl
no label allocate
Syntax Description
Defaults
LDP allocates local label for all learnt routes (prefixes).
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Local label allocation control lets you override the default label allocation policy and provides many benefits, including reduced memory usage and fewer forwarding and network updates.
By default, LDP allocates local labels for all learned routes. There are times when you may want to limit label allocation for a given set of prefixes; for example, when using LDP in the core network to provide MPLS transport from one edge to another edge. In such cases, it is necessary to set up LSPs for Loopback /32 addresses for PE routers (rendering it unnecessary to allocate and advertise local labels for other IGP prefixes).
LDP supports IPv4 standard access lists only.
Task ID
Examples
Following example shows how to configure LDP to limit allocation of local labels to prefixes 192.168.1.1, 192.168.2.2, and 192.168.3.3 only
RP/0/RP0/CPU0:router(config)# ipv4 access-list pfx_acl_1
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 192.168.1.1
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 192.168.2.2
RP/0/RP0/CPU0:router(config-ipv4-acl)# permit 192.168.3.3
RP/0/RP0/CPU0:router(config-ldp)# label allocate for pfx_acl_1
Related Commands
Command DescriptionDisplays information about LDP label bindings.
Displays the contents of the LDP forwarding database.
log graceful-restart
To set up notification describing graceful-restart (GR) session events, use the log graceful-restart command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
log graceful-restart
no log graceful-restart
Syntax Description
This command has no arguments or keywords.
Defaults
No default behavior or values
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Use the log graceful-restart command to receive a syslog/console message when a graceful restart-related session event occurs, including LDP graceful restart session disconnection, reconnection, and timeout.
Note A logging message is issued upon graceful restart session events.
Task ID
Examples
The following example shows how to enable logging messages for graceful restart session events:
RP/0/RP0/CPU0:router(config-ldp)# log graceful-restart
The following shows sample output of logging events that can be displayed on the console:
RP/0/RP0/CPU0:router: mpls_ldp[340]: %ROUTING-LDP-5-GR : GR session 4.4.4.4:0 (instance 1) disconnectedRP/0/RP0/CPU0:router: mpls_ldp[340]: %ROUTING-LDP-5-GR : GR session 4.4.4.4:0 (instance 2) reconnectedRP/0/RP0/CPU0:router: mpls_ldp[340]: %ROUTING-LDP-5-GR : GR session 5.5.5.5:0 (instance 3) timed outRP/0/RP0/CPU0:router: mpls_ldp[336]: %ROUTING-LDP-5-GR_RESTART_COMPLETE : GR forwarding state hold timer has expiredRelated Commands
Command DescriptionDisplays information about LDP neighbors.
Displays information about LDP GR sessions.
log neighbor
To enable logging of notices describing session changes, use the log neighbor command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
log neighbor
no log neighbor
Syntax Description
This command has no arguments or keywords.
Defaults
No default behavior or values
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Use the log neighbor command to receive a syslog/console message when a neighbor goes up or down.
Task ID
Examples
The following example shows how to enable logging messages for neighbor session up and down events:
RP/0/RP0/CPU0:router(config-ldp)# log neighbor
Note A logging message is issued when an LDP session state changes from up to down (and down to up).
The following shows sample output of logging events that can be displayed on the console:
RP/0/RP0/CPU0:10 21:11:32.111:mpls_ldp[113]:%LDP-5-NBR_CHANGE: Nbr 10.44.44.44:0, DOWNRelated Commands
log nsr
To enable logging of nonstop routing (NSR) synchronization events, use the log nsr command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
log nsr
no log nsr
Syntax Description
This command has no arguments or keywords.
Defaults
No default behavior or values
Command Modes
MPLS LDP configuration
Command History
Release ModificationRelease 3.6.0
This command was introduced on the Cisco XR 12000 Series Router Cisco CRS-1 router.
Release 3.7.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to enable logging of NSR synchronization events:
RP/0/RP0/CPU0:router(config-ldp)# log nsr
log session-protection
To enable logging of notices describing LDP session protection events, use the log session-protection command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
log session-protection
no log session-protection
Syntax Description
This command has no arguments or keywords.
Defaults
No default behavior or values
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Use the log session-protection command to receive a syslog/console message when LDP session protection event occurs. These events include LDP session protection initiation, recovery, and timeout.
Task ID
Examples
The following example shows how to enable logging messages for session protection events:
RP/0/RP0/CPU0:router(config-ldp)# log session-protection
Note Logging messages are issued when session protection events occur.
The following shows sample output of logging events that can be displayed on the console:
RP/0/RP0/CPU0:Apr 21 12:15:01.742: mpls_ldp[315]:%ROUTING-LDP-5-SESSION_PROTECTION: Session hold up initiated for peer 4.4.4.4:0RP/0/RP0/CPU0:Apr 21 12:18:04.987: mpls_ldp[315]:%ROUTING-LDP-5-SESSION_PROTECTION: Session recovery succeeded for peer 4.4.4.4:0Related Commands
maximum interfaces (MPLS LDP)
To configure upper limit on maximum number of LDP configured interfaces, use the maximum interfaces command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
maximum interfaces number
no maximum interfaces
Syntax Description
Defaults
By default, you can enable LDP on up to 100 interfaces.
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to set an upper limit of 150 as maximum number of LDP interfaces which can be enabled on the box:
RP/0/RP0/CPU0:router(config-ldp)# maximum interfaces 150Related Commands
mpls ldp nsr
To configure nonstop routing for LDP protocols in the event of a disruption in service, use the mpls ldp nsr command in global configuration mode. To return to the default behavior, use the no form of this command.
mpls ldp nsr
no mpls ldp nsr
Syntax Description
This command has no arguments or keywords.
Defaults
By default, MPLS LDP NSR is disabled.
Command Modes
Global configuration
Command History
Release ModificationRelease 3.6.0
This command was introduced on the Cisco CRS-1 and the Cisco XR 12000 Series Router.
Release 3.7.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
A disruption in service may include any of the following events:
•Route processor (RP) or distributed route processor (DRP) failover
•LDP process restart
•In-service system upgrade (ISSU)
•Minimum disruption restart (MDR)
Enabling NSR causes events such as these to be invisible to the routing peers and provide minimal service disruption.
Task ID
Examples
The following example shows how to enable MPLS LDP NSR:
RP/0/RP0/CPU0:router# configureRP/0/RP0/CPU0:router(config)# mpls ldpRP/0/RP0/CPU0:router(config-ldp)# nsrRelated Commands
neighbor password
To configure password authentication using the TCP Message Digest 5 (MD5) option for a neighbor, use the neighbor password command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
neighbor A.B.C.D. password {clear | encrypted} password
no neighbor A.B.C.D. password
Syntax Description
Defaults
LDP sessions are negotiated without any password (and MD5).
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
This security feature is enabled per neighbor, so that a session establishment attempt is allowed only when a password match has been configured. This option must be configured so that both peer passwords match.
Task ID
Examples
The following example shows how to configure the password "cisco" for neighbor 10.20.20.20:
RP/0/RP0/CPU0:router(config-ldp)# neighbor 10.20.20.20 password clear cisco
Related Commands
neighbor targeted
To configure transmission of targeted hellos towards a neighbor for setting up LDP session, use the neighbor ip-address targeted command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
neighbor A.B.C.D. targeted
no neighbor A.B.C.D. targeted
Syntax Description
Defaults
No default behavior or values
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to set up a targeted discovery session for neighbor 200.1.1.1:
RP/0/RP0/CPU0:router(config-ldp)# neighbor 200.1.1.1 targetedRelated Commands
Command DescriptionConfigures password authentication using MD5.
Displays information about LDP neighbors.
Displays information about LDP discovery sources.
router-id (MPLS LDP)
To specify the IP address of a preferred interface or a specific IP address as the LDP router ID, use the router-id command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
router-id A.B.C.D.
no router-id
Syntax Description
Defaults
LDP uses router ID as determined by global router ID agent, IP Address Repository Manager (IP ARM).
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The router-id command lets you specify an interface with an IP address to be used as the LDP router ID (which is necessary when an IP address selected as the LDP router ID might not be advertisable by the routing protocol to a neighboring router). In such cases, use the router-id command to select the IP address of the specified loopback interface (if the interface is operational) or a specific IP address.
LDP uses the router ID from different sources in the following order:
1. Configured LDP router ID.
2. Global router ID (if configured).
3. Calculated (computed) using the primary IPv4 address of the highest numbered configured loopback address. We recommend configuring at least one loopback address.
Note We recommend that you configure the LDP router-id with an ip-address to avoid unnecessary session flaps.
Task ID
Examples
The following example shows how to specify loopback interface 1 as the preferred interface used to determine the LDP router ID:
RP/0/RP0/CPU0:router(config-ldp)# router-id loopback 1Related Commands
Command DescriptionDisplays the status of the LDP discovery process.
Displays information about LDP neighbors.
Displays current LDP parameter settings.
session protection
To enable LDP session protection feature for keeping LDP peer session up by means of targeted discovery following the loss of link discovery with a peer, use the session protection command in MPLS LDP configuration mode. To return to the default behavior, use the no form of this command.
session protection [duration seconds | infinite] [for peer-acl]
no session protection
Syntax Description
Defaults
By default, session protection is disabled. When enabled without peer-acl and duration, session protection is provided for all LDP peers and continues for 24 hours after a link discovery loss.
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
LDP session protection feature allows you to enable the automatic setup of targeted hello adjacencies with all or a set of peers and specify the duration for which session needs to be maintained using targeted hellos after loss of link discovery.
LDP supports only IPv4 standard access lists.
Task ID
Examples
The following example shows how to enable session protection for all discovered peers with unlimited duration to maintain the session after link discovery loss.
RP/0/RP0/CPU0:router(config-ldp)# session protectionThe following example shows how to enable session protection for a set of peers (as permitted by a peer ACL) with duration of 30 seconds to maintain the session after link discovery loss.
RP/0/RP0/CPU0:router(config-ldp)# session protection for peer_acl duration 30Related Commands
show mpls ldp backoff
To display information about the configured session setup backoff parameters and any potential LDP peers with which session setup attempts are being throttled, use the show mpls ldp backoff command in EXEC mode.
show mpls ldp backoff
Syntax Description
This command has no arguments or keywords.
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
You must enable the MPLS LDP application to use the show mpls ldp backoff command.
Task ID
Examples
The following is sample output from the show mpls ldp backoff command.
RP/0/RP0/CPU0:router# show mpls ldp backoff
Backoff Time:Initial:15 sec, Maximum:120 secBackoff Table: (2 entries)LDP Id Backoff (sec) Waiting (sec)-------------------- -------------- ----------------33.33.33.33:0 15 1511.11.11.11:0 30 30Table 1 describes the significant fields shown in the display.
Related Commands
Command DescriptionConfigure LDP backoff parameters.
Displays the contents of MPLS forwarding table.
Displays the contents of LDP label information base (LIB).
show mpls ldp bindings
To display the contents of the Label Information Base (LIB), use the show mpls ldp bindings command in EXEC command.
show mpls ldp bindings [prefix {mask | length}] [advertisement-acls] [detail] [local] [local-label label [to label]] [neighbor address] [remote-label label [to label]] [summary]
Syntax Description
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The show mpls ldp bindings command displays local and remote label bindings learned from neighbors for non-BGP routes (such as IGP prefixes and static routes).
You can choose to view the entire database or a subset of entries according to the following criteria:
•Prefix.
•Input or output label values or ranges.
•Neighbor advertising the label.
Note The show mpls ldp bindings summary command displays summarized information from the LIB and is used when testing scalability or when deployed in a large scale network.
Task ID
Examples
The following is sample output from the show mpls ldp bindings command. This form of this command displays the contents of the LIB for the default routing domain:
RP/0/RP0/CPU0:router# show mpls ldp bindings
5.41.0.0/16 , rev 4local binding: label:IMP-NULLNo remote bindings5.43.9.98/32 , rev 6local binding: label:IMP-NULLNo remote bindings10.10.2.0/24 , rev 12local binding: label:IMP-NULLremote bindings :lsr:10.255.255.255:0, label:16lsr:10.256.256.256:0, label:IMP-NULL10.10.3.0/24 , rev 10local binding: label:IMP-NULLremote bindings :lsr:10.255.255.255:0, label:IMP-NULLlsr:10.256.256.256:0, label:2222.22.22.22/32 , rev 14local binding: label:16remote bindings :lsr:10.255.255.255:0, label:17lsr:10.256.256.256:0, label:IMP-NULL33.33.33.33/32 , rev 2local binding: label:IMP-NULLremote bindings :lsr:10.255.255.255:0, label:18lsr:10.256.256.256:0, label:23The following sample output from the show mpls ldp bindings command specifies a network number and displays labels learned from label switched router (LSR) 10.255.255.255 for all networks.
Use the neighbor option to suppress the output of remote labels learned from other neighbors:
RP/0/RP0/CPU0:router# show mpls ldp bindings neighbor 10.255.255.255
10.10.2.0/24 , rev 12local binding: label:IMP-NULLremote bindings :lsr:10.255.255.255, label:1610.10.3.0/24 , rev 10local binding: label:IMP-NULLremote bindings :lsr:10.255.255.255:0, label:IMP-NULL22.22.22.22/32 , rev 14local binding: label:16remote bindings :lsr:10.255.255.255:0, label:1733.33.33.33/32 , rev 2local binding: label:IMP-NULLremote bindings :lsr:10.255.255.255:0, label:1844.44.44.44/32 , rev 16local binding: label:17remote bindings :lsr:10.255.255.255:0, label:IMP-NULLTable 2 describes the significant fields shown in the display.
Table 2 show mpls ldp bindings and show mpls ldp bindings neighbor Field Descriptions
Field Descriptiona.b.c.d/n
IP prefix and mask for a particular destination (network/mask).
rev
Revision number (rev) that is used internally to manage label distribution for this destination.
local binding
Locally assigned label for a prefix.
remote bindings
Outgoing labels for this destination learned from other LSRs.1 Each item in this list identifies the LSR from which the outgoing label was learned and reflects the label associated with that LSR. Each LSR in the transmission path is identified by its LDP identifier.
(rewrite)
Binding has been written into MPLS forwarding and is in use.
(no route)
Route is not valid. LDP times it out before the local binding is deleted.
1 Label switched routers
The following is sample output from the show mpls ldp bindings command using the summary keyword:
RP/0/RP0/CPU0:router# show mpls ldp bindings summary
LIB Summary:Total Prefix : 20Revision No : Current:34, Advertised:34Local Bindings : 14NULL : 10 (implicit:10, explicit:0)Non-NULL: 4 (lowest:48, highest:51)Remote Bindings: 24Table 3 describes the significant fields shown in the display.
The following is sample output from the show mpls ldp advertisement-acls command:
RP/0/RP0/CPU0:router# show mpls ldp bindings advertisement-acls
Advertisement Spec:Prefix ACL = 'pfx_11'Prefix ACL = 'pfx_22'Prefix ACL = 'pfx_40_1'; Peer ACL = 'peer_11'5.41.0.0/16 , rev 8211.11.11.11/32 , rev 69Advert ACL(s): Prefix ACL 'pfx_11'20.20.20.20/32 , rev 8322.22.22.22/32 , rev 78Advert ACL(s): Prefix ACL 'pfx_22'40.1.1.0/24 , rev 79Advert ACL(s): Prefix ACL 'pfx_40_1'; Peer ACL 'peer_11'Table 4 describes the significant fields shown in the display.
Related Commands
Command DescriptionConfigure LDP local label advertisement control
Configure LDP remote label acceptance
Displays information on LDP neighbors.
Displays the contents of the LDP forwarding database.
show mpls ldp discovery
To display the status of the LDP discovery process, use the show mpls ldp discovery command in EXEC mode.
show mpls ldp discovery [type interface-id | summary]
Syntax Description
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The show mpls ldp discovery command shows both link discovery and targeted discovery. When no interface filter is specified, this command generates a list of interfaces running the LDP discovery process. This command also displays neighbor discovery information for the default routing domain.
Task ID
Examples
The following is sample output from the show mpls ldp discovery command:
RP/0/RP0/CPU0:router# show mpls ldp discovery
Local LDP Identifier: 10.44.44.44:0Discovery Sources:Interfaces:POS 0/1/0/0 : xmit/recvLDP Id: 10.33.33.33:0, Transport address: 10.33.33.33Hold time: 15 sec (local:15 sec, peer:15 sec)Table 5 describes the significant fields shown in the display.
The following is sample output from the show mpls ldp discovery command using the summary keyword:
RP/0/RP0/CPU0:router# show mpls ldp discovery summaryLDP Identifier: 139.0.0.1:0Interfaces:Configured: 2Enabled : 1Discovery:Hello xmit: 1 (1 link)Hello recv: 1 (1 link)Table 6 describes the significant fields shown in the display.
Related Commands
show mpls ldp forwarding
To display the LDP forwarding state installed in MPLS forwarding, use the show mpls ldp forwarding command in EXEC mode.
show mpls ldp forwarding [A.B.C.D/prefix {mask | length}]
Syntax Description
A.B.C.D/prefix
(Optional) IP address, specified in four-part, dotted-decimal notation.
mask
Network mask.
length
Mask length. Range is 0 to 32 bits.
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The show mpls ldp forwarding command displays the LDP forwarding entries and provides LDP view of its installed forwarding entries.
Task ID
Examples
The following is sample output from the show mpls ldp forwarding command:
RP/0/RP0/CPU0:router# show mpls ldp forwardingPrefix Label Label Outgoing Next Hop GR StaleIn Out Interface------------------ ----- ---------- ------------ --------------- -- -----2.2.2.2/32 22 ImpNull PO0/2/0/1 12.0.0.2 N N3.0.0.1/32 24 20 PO0/2/0/1 12.0.0.2 N N3.0.0.2/32 25 21 PO0/2/0/1 12.0.0.2 N N3.0.0.3/32 26 22 PO0/2/0/1 12.0.0.2 N N4.4.4.4/32 20 ExpNullv4 tt10 4.4.4.4 N N4.4.4.5/32 21 ExpNullv4 tt10 4.4.4.4 N N123.0.0.0/24 23 ImpNull PO0/2/0/1 12.0.0.2 N NTable 7 describes the significant fields shown in the display.
Related Commands
Command DescriptionConfigure LDP Graceful restart feature.
Displays the contents of LDP label information base (LIB).
show mpls ldp graceful-restart
To display the status of the LDP graceful restart, use the show mpls ldp graceful-restart command in EXEC mode.
show mpls ldp graceful-restart
Syntax Description
This command has no arguments or keywords.
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The show mpls ldp graceful-restart command displays LDP graceful-restart-related information when the graceful-restart command is enabled.
Task ID
Examples
The following is sample output from the show mpls ldp graceful-restart command:
RP/0/RP0/CPU0:router# show mpls ldp graceful-restart
Forwarding State Hold timer : Not RunningGR Neighbors : 1Neighbor ID Up Connect Count Liveness Timer Recovery Timer--------------- -- ------------- ------------------ ------------------139.0.0.2 Y 1 - -Table 8 describes the significant fields shown in the display.
Related Commands
Command DescriptionConfigures the LDP graceful restart feature.
Displays information about LDP neighbors.
show mpls ldp igp sync
To display Interior Gateway Protocol (IGP) IGP synchronization information on interface(s), use the show mpls ldp igp sync command in EXEC mode.
show mpls ldp igp sync [interface type interface-id]
Syntax Description
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
LDP IGP synchronization addresses traffic loss issues as a result of synchronization between MPLS LDP and IP (IGP). For instance, upon a link up, IGP can advertise a link before MPLS converges on the link. Also, the IGP link is still used even when MPLS session goes down and MPLS Label Switched Path (LSP) is broken on this link. The use of IGP link is determined based on MPLS LDP convergence synchronization status on the link.
Use the show mpls ldp igp sync command to display MPLS convergence status. The configuration for LDP IGP synchronization resides in IGPs (OSPF, IS-IS); accordingly, LDP displays and advertises this information for all LDP-enabled interfaces (regardless of whether or not the interface is configured for LDP IGP).
Task ID
Examples
The following is sample output from the show mpls ldp igp sync command:
RP/0/RP0/CPU0:router1# show mpls ldp igp syncGigabitEthernet0/3/0/0:Sync status: ReadyPeers:2.2.2.2:03.3.3.3:0 (GR)GR-only Reachability:4.4.4.4:0 (Chkpt-created)POS0/2/0/0:Sync status: Not ready(Deferred; 24 sec remaining)POS0/2/0/1:Sync status: Not readyTable 9 describes the significant fields shown in the display.
Related Commands
show mpls ldp interface
To display information about LDP-enabled interfaces, use the show mpls ldp interfaces command in EXEC mode.
show mpls ldp interface type interface-id [summary | brief]
Syntax Description
Command Modes
EXEC
Command History
Release ModificationRelease 3.5.0
This command was introduced on the Cisco CRS-1 and the Cisco XR 12000 Series Router.
Release 3.6.0
No modification.
Release 3.7.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following is sample output from the show mpls ldp interface command:
RP/0/RP0/CPU0:router# show mpls ldp interfaceInterface GigabitEthernet0/3/0/3No LDP configInterface POS0/2/0/0No LDP configAuto-config items:ospf/100/0Interface POS0/2/0/1No LDP configAuto-config items:ospf/100/0Interface POS0/2/0/2No LDP configAuto-config items:ospf/100/0Interface POS0/2/0/3No LDP configAuto-config items:ospf/100/0Table 10 describes the significant fields shown in the display.
Related Commands
show mpls ldp neighbor
To display the status of LDP sessions, use the show mpls ldp neighbor command in EXEC mode.
show mpls ldp neighbor [A.B.C.D. | type interface-id | gr | non-gr | sp | | standby | brief] [detail]
Syntax Description
Defaults
No default behavior or values
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The show mpls ldp neighbor command provides information about all LDP neighbors in the entire routing domain—conversely, the show output is filtered to display:
•LDP neighbors with specific IP addresses
•LDP neighbors on a specific interface
•LDP neighbors that are graceful restartable
•LDP neighbors that are non-graceful restartable
•LDP neighbors enabled with session protection
Task ID
Examples
The following is sample output from the show mpls ldp neighbor command using an IP address:
RP/0/RP0/CPU0:router# show mpls ldp neighbor 10.22.22.22
Peer LDP Identifier: 10.22.22.22:0TCP connection: 10.22.22.22:646 - 10.33.33.33:65530Graceful Restart: NoState: Oper; Msgs sent/rcvd: 46/43Up time: 00:31:21LDP Discovery Sources:POS 0/2/0/0Addresses bound to this peer:10.22.22.22 10.10.2.1The following is sample output from the show mpls ldp neighbor command using the non-gr keyword:
RP/0/RP0/CPU0:router# show mpls ldp neighbor non-gr
Peer LDP Identifier: 10.44.44.44:0TCP connection: 10.44.44.44:65535 - 10.33.33.33:646Graceful Restart: NoState: Oper; Msgs sent/rcvd: 49/46Up time: 00:33:33LDP Discovery Sources:POS 0/1/0/0Addresses bound to this peer:10.44.44.44 10.10.3.2Peer LDP Identifier: 10.22.22.22:0TCP connection: 10.22.22.22:646 - 10.33.33.33:65530Graceful Restart: NoState: Oper; Msgs sent/rcvd: 48/45Up time: 00:33:11LDP Discovery Sources:POS 0/2/0/0Addresses bound to this peer:10.22.22.22 10.10.2.1Table 11 describes the significant fields shown in the display.
Table 11 show mpls ldp neighbor Field Descriptions
Field DescriptionPeer LDP Identifier
LDP identifier of the neighbor (peer) for this session.
Graceful Restart
Graceful-restart status (Y or N).
TCP connection
TCP1 connection used to support the LDP session, shown in the following format:
•neighbor IP address: peer port
•local IP address: local port
State
State of the LDP session. Generally this is Oper (operational), but transient is another possible state.
Msgs sent/rcvd
Number of LDP messages sent to and received from the session peer. The count includes the transmission and receipt of periodic keepalive messages, which are required for maintenance of the LDP session.
Up time
The length of time that this session has been up for (in hh:mm:ss format).
LDP Discovery Sources
The source(s) of LDP discovery activity leading to the establishment of the LDP session.
Addresses bound to this peer
The known interface addresses of the LDP session peer. These are addresses that might appear as "next hop" addresses in the local routing table. They are used to maintain the LFIB.2
1 Transmission Control Protocol
2 Label Forwarding Information Base
The following is sample output from the show mpls ldp neighbor command using the brief keyword:
RP/0/RP0/CPU0:router# show mpls ldp neighbor brief
Peer GR Up Time Discovery Address----------------- -- --------------- --------- -------139.0.0.2:0 Y 00:31:36 1 3Table 12 describes the significant fields shown in the display.
The following is sample output from the show mpls ldp neighbor command using detail keyword:
RP/0/RP0/CPU0:router# show mpls ldp neighbor detailPeer LDP Identifier: 2.2.2.2:0TCP connection: 2.2.2.2:11707 - 1.1.1.1:646Graceful Restart: NoSession Holdtime: 180 secState: Oper; Msgs sent/rcvd: 33/29Up time: 00:13:37LDP Discovery Sources:POS0/2/0/1Targeted Hello (1.1.1.1 -> 2.2.2.2, active)Addresses bound to this peer:23.0.0.2 12.0.0.2 123.0.0.2 5.42.37.1192.2.2.2Peer holdtime: 180 sec; KA interval: 60 sec; Peer state: EstabClients: Dir Adj ClientInbound label filtering: accept acl 'pfx_acl2'Session Protection:Enabled, state: ReadyDuration: 30 secondsTable 13 describes the significant fields shown in the display.
Table 13 show mpls ldp neighbor detail Field Descriptions
Field DescriptionPeer LDP Identifier
LDP identifier of the neighbor (peer) for this session.
TCP connection
TCP1 connection used to support the LDP session, shown in the following format:
•neighbor IP address: peer port
•local IP address: local port
Graceful Restart
Graceful-restart status (Y or N).
Session Holdtime
Session holdtime in seconds
State
State of the LDP session (operational or transient).
Msgs sent/rcvd
Number of LDP messages sent to and received from the session peer. The count includes the transmission and receipt of periodic keepalive messages, which are required for maintenance of the LDP session.
Up time
Time the session has been up for (in hh:mm:ss format).
Peer holdtime
Time to keep LDP peer session up without receipt of LDP protocol message from a peer.
Peer state
Peer session state
Peer holdtime
Time to keep LDP peer session up without receipt of LDP protocol message from a peer.
Clients
LDP (internal) clients requesting session with a neighbor.
Inbound label filtering
LDP neighbor inbound filtering policy.
Session Protection
State of the session protection:
•Incomplete: Targeted discovery requested but not yet up.
•Ready: Targeted discovery and at least one link hello adjacency to the peer are up.
•Protecting: Targeted discovery is up and there is no link hello adjacency to the peer. Targeted discovery is protecting and backing up link discoveries.
Duration
Maximum time to maintain session through targeted discovery upon loss of primary link discovery.
Holdtimer
When in "protecting" state, time to keep LDP peer session up without receipt of LDP protocol message from a peer.
1 Transmission Control Protocol
Related Commands
show mpls ldp parameters
To display current LDP parameters, use the show mpls ldp parameters command in EXEC mode.
show mpls ldp parameters
Syntax Description
This command has no arguments or keywords.
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The show mpls ldp parameters command displays all LDP operational and configuration parameters.
Task ID
Examples
The following is sample output from the show mpls ldp parameters command:
RP/0/RP0/CPU0:router# show mpls ldp parameters
LDP Parameters:Protocol Version: 1Router ID: 11.11.11.11Null Label: ImplicitSession:Hold time: 180 secKeepalive interval: 60 secBackoff: Initial:15 sec, Maximum:120 secDiscovery:Link Hellos: Holdtime:15 sec, Interval:5 secTargeted Hellos: Holdtime:90 sec, Interval:10 sec(Accepting peer ACL 'peer_acl_10')Graceful Restart:Enabled (Configured)Reconnect Timeout:120 sec, Forwarding State Holdtime:180 secTimeouts:Binding with no-route: 300 secLDP application recovery (with LSD): 360 secOOR stateMemory: NormalTable 14 describes the significant fields shown in the display.
Related Commands
show mpls ldp statistics msg-counters
To display statistics of the messages exchanged between neighbors, use the show mpls ldp statistics msg-counters command in EXEC mode.
show mpls ldp statistics msg-counters [A.B.C.D.]
Syntax Description
Command Modes
EXEC
Command History
Release ModificationRelease 2.0
This command was introduced on the Cisco CRS-1.
Release 3.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The show mpls ldp statistics msg-counters command can provide counter information about different types of messages sent and received between neighbors.
Task ID
Examples
The following is sample output from the show mpls ldp statistics msg-counters command:
RP/0/RP0/CPU0:router# show mpls ldp statistics msg-counters
Peer LDP Identifier: 10.33.33.33:0Msg Sent: (80)Init : 1Address : 1Address_Withdraw : 0Label_Mapping : 5Label_Withdraw : 0Label_Release : 0Notification : 0KeepAlive : 73Msg Rcvd: (81)Init : 1Address : 1Address_Withdraw : 0Label_Mapping : 8Label_Withdraw : 0Label_Release : 0Notification : 0KeepAlive : 71Table 15 describes the significant fields shown in the display.
Related Commands
Command DescriptionClears MPLS LDP message counter values.
Displays the contents of LDP label information base (LIB).
Displays LDP neighbor information.
show mpls ldp summary
To display a summary of LDP information, use the show mpls ldp summary command in EXEC mode.
show mpls ldp summary
Syntax Description
This command has no keywords or arguments.
Command Modes
EXEC
Command History
Release ModificationRelease 2.0
This command was introduced on the Cisco CRS-1.
Release 3.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The show mpls ldp summary command can provide information about the number of LDP neighbors, interfaces, forwarding state (rewrites), servers connection/registration, and graceful-restart information.
Task ID
Examples
The following is sample output from the show mpls ldp summary command:
RP/0/RP0/CPU0:router# show mpls ldp summary
Routes : 4Neighbors : 1 (1 GR)Hello Adj : 1Interfaces: 4 (1 forward reference, 2 LDP configured)Addresses : 3Clients : 0Servers :Connected Registered--------- ----------SysDB Y YIM Y YIPv4 ARM Y -LSD Y YRIBv4 Y YTable 16 describes the significant fields shown in the display.
Related Commands
signalling dscp (LDP)
To assign LDP signaling packets a Differentiated Service Code Point (DSCP) to assign higher priority to the control packets while traversing the network, use the signalling dscp command in MPLS LDP configuration submode. To return to the default behavior, use the no form of this command.
signalling dscp dscp
no signalling dscp
Syntax Description
Defaults
LDP control packets are sent with precedence 6 (dscp: 48)
Command Modes
MPLS LDP configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
DSCP marking improves signaling setup and teardown times.
Ordinarily, when LDP sends hello discovery or protocol control messages, these are marked using the default control packet precedence value (6, or dscp 48). You can use the signalling dscp command to override that DSCP value to ensure that all control messages sent are marked with a specified DSCP.
Note While the signalling dscp command controls LDP signaling packets (Discovery hellos and protocol messages), it has no effect on ordinary IP or MPLS data packets.
Task ID
Examples
The following example shows how to assign LDP packets a DSCP value of 56:
RP/0/RP0/CPU0:router(config-ldp)# signalling dscp 56snmp-server traps mpls ldp
To inform a network management system of session and threshold cross changes, use the snmp-server traps mpls ldp command in router configuration mode.
snmp-server traps mpls ldp {up | down | threshold}
Syntax Description
up
Session up notification
down
Session down notification
threshold
Session backoff threshold crossed notification
Defaults
LDP does not send SNMP traps.
Command Modes
Router configuration
Command History
Release ModificationRelease 2.0
This command was introduced on the Cisco CRS-1.
Release 3.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The snmp-server traps mpls ldp command sends notifications to the SNMP server. There are three types of traps sent by LDP:
•Session up—Generated when sessions go up.
•Session down—Generated when sessions go down.
•Threshold—Generated when attempts to establish a session fails. The predefined value is 8.
Task ID
Examples
The following example shows how to enable LDP SNMP trap notifications for Session up:
RP/0/RP0/CPU0:router(config)# snmp-server traps mpls ldp up