Displaying LDP information and statistics

The show mpls ldp command and options allows you to display LDP information and statistics.

Displaying the LDP version

To display the LDP version number, the LSR ID and loopback number, and the LDP hello interval and hold time, enter the show mpls ldp command.

device# show mpls ldp
Label Distribution Protocol version 1
  LSR ID: 1.2.3.4 , using Loopback 1 (deleting it will stop LDP)
  Hello interval: Link 5 sec, Targeted 15 sec
  Hold time value sent in Hellos: Link 15 sec, Targeted 45 sec
  Keepalive interval: 6 sec, Hold time multiple: 6 intervals
  Keepalive timeout: 36 sec
  Load sharing: 8
  Advertise FECs for prefix-list: "ldp-route-injection"
  Tunnel metric: 0
  FEC used for auto discovered peers: current 129, configured 129
  End of LIB: Disabled, Notification time: 60000 ms, tx label silence time: 1000 ms
  Rx label silence time: 1000 ms
  Graceful restart: enabled as helper-only
    Reconnect time: 0 seconds, Max peer reconnect time: 120 seconds
    Recovery time: 0 seconds, Max peer recovery time: 120 seconds
    Forwarding state holding timer: not running
  Label Withdrawal delay: 60 seconds (Default)

Displaying LDP-created LSPs information

To display information about active LDP-created LSPs for which this device is an ingress, transit, or egress LSR, use the show mpls ldp path command. The command shows information about an LSP created through LDP including the incoming and outgoing labels applied to packets in each LSP.

device# show mpls ldp path
Destination route   Upstr-session(label)       Downstr-session(label, intf)	
10.2.2.2/32         10.3.3.3:0(1024)           10.2.2.2:0(3,Eth 2/10)	         
                    10.2.2.2:0(1024)           10.2.2.2:0(3,Eth 2/10)	         
10.3.3.3/32         10.3.3.3:0(1026)           10.3.3.3:0(3,Eth 2/20)	         
                    10.2.2.2:0(1026)           10.3.3.3:0(3,Eth 2/20)	         

Displaying LDP tunnel LSP information

To display information about LDP-created LSPs for which this device is the ingress LER including the total number of tunnels, use the show mpls ldp tunnel command.

device# show mpls ldp tunnel
Total number of LDP tunnels : 3
                   Oper     Tunnel     Outbound
To                 State    Intf       Intf
10.22.22.22/32     UP       tnl2       Eth 2/3
10.33.33.33/32     UP       tnl3       Eth 2/3
10.44.44.44/32     UP       tnl4       Ve 55

If you include the tunnel destination IP prefix with the command, it displays a single tunnel entry for a specified prefix.

device# show mpls ldp tunnel 10.22.22.22
LDP tunnel tnl2, to 10.22.22.22/32
  Tunnel index: 2, metric: 0, status: UP
  Outgoing interface: Eth 2/3, Next-hop ip: 10.55.55.55/32

If you include the detail option with the command, it displays a single tunnel entry for a specified prefix.

device# show mpls ldp tunnel detail
Total number of LDP tunnels : 3
LDP tunnel tnl2, to 10.22.22.22/32
  Tunnel index: 2, metric: 0, status: UP
  Outgoing interface: Eth 2/3, Next-hop ip: 10.55.55.55/32
LDP tunnel tnl3, to 10.33.33.33/32
  Tunnel index: 3, metric: 0, status: UP
  Outgoing interface: Eth 2/3, Next-hop ip: 10.55.55.55/32
LDP tunnel tnl4, to 10.44.44.44/32
  Tunnel index: 4, metric: 0, status: UP 
  Outgoing interface: Ve 55, Next-hop ip: 10.55.55.55/32

Displaying the LDP tunnel state with counter profile

To display the state for LDP tunnels with counter profiles, use the show mpls ldp tunnel detail command. The counter profile may or may not support MPLS statistics encapsulation.
Note

Note

If you boot up the system with a counter profile that supports MPLS statistics encapsulation and the ingress-tunnel-accounting command is configured, output similar to the following is displayed when you enter the show mpls ldp tunnel detail command:
device(config-router-mpls-policy)# ingress-tunnel-accounting
device#
device# show mpls ldp tunnel detail
LDP tunnel tnl2, to 45.45.45.45/32
  Tunnel index: 2, metric: 0, status: UP
  Tunnel interface index: 2092957698
  Outgoing interface: Ve 20, Next-hop ip: 44.45.20.45
device# 
If you boot up the system with a counter profile that does not support MPLS statistics encapsulation and the ingress-tunnel-accounting command is configured, then "No statistics available, forwarding may be affected" is displayed with the output when you enter the show mpls ldp tunnel detail command. For example:
device(config-router-mpls-policy)# ingress-tunnel-accounting
device#
device# show mpls ldp tunnel detail
LDP tunnel tnl2, to 45.45.45.45/32
  Tunnel index: 2, metric: 0, status: UP (No statistics available, forwarding may be affected)
  Tunnel interface index: 2092957698
  Outgoing interface: Ve 20, Next-hop ip: 44.45.20.45
device# 

To display the counter profile that supports MPLS statistics or not, enter the show hardware profile counters <counter_profile> command and look for “OutLIF - HitCount:” in the output. If the OutLIF - HitCount: count is zero, then the counter profile does not support MPLS statistics, otherwise it supports MPLS statistics.

Displaying the contents of the LDP database

To display the contents of the LSRs LDP Label Information Base, use the show mpls ldp database command. This database contains all labels that it learned from each of its LSR peers and that it sent to its LDP peers.

device# show mpls ldp database
Session 10.210.210.21:0 - 10.2.2.2:0
 Downstream label database:
   Label	 Prefix	         State
 Upstream label database: 
  Label	  Prefix
  1024	   10.125.125.25/32(Stale)
  3	      10.210.210.21/32(Stale)
  1025	   10.220.220.22/32(Stale) 
Session 10.210.210.21:0 - 10.220.220.22:0
 Downstream label database:
   Label	 Prefix	          State
   3	     10.220.220.22/32	Installed
   1024	  10.125.125.25/32	Installed
   983097	VC-FEC	          Retained
 Upstream label database: 
   Label	 Prefix
   3	     10.210.210.21/32
   983040	VC-FEC

Displaying LDP session information

To display information about the LDP session between this LSR and its LDP peers, enter the show mpls ldp session command. The following examples show Graceful Restart related information received from the neighbor.

When Graceful Restart starts, it also shows the current state.

device# show mpls ldp session
 Number of link LDP sessions: 2
 Number of Operational link LDP sessions: 2
 Number of targeted LDP sessions: 1
 Number of Operational targeted LDP sessions: 1

Peer LDP ID	   State	       Adj Used	 My Role	 Max	Hold	Time Left
10.22.22.22:0	 Operational	 Link	     Passive	 36		     33
10.33.33.33:0	 Operational	 Targeted	 Passive	 36		     34
10.44.44.44:0	 Operational	 Link	     Passive	 36		     34

The following example shows the reconnect timer running.

device# show mpls ldp session 10.2.2.2:0
Peer LDP ID: 10.2.2.2:0, Local LDP ID: 10.210.210.21:0, State: Restarting
   Graceful restart: enabled
     Peer reconnect time(msec): 120000, peer recovery time(msec): 120000
     Reconnect time in use(msec): 120000, remaining time(msec): 32300
     State: reconnecting

The following example shows the recovery timer running.

device# show mpls ldp session 10.11.11.1
Peer LDP ID: 10.11.11.1:0, Local LDP ID: 10.22.22.2:0, State: Operational 
  Adj: Link, Role: Active, Next keepalive: 0 sec, Hold time left: 30 sec 
  Keepalive interval: 6 sec, Max hold time: 36 sec
  Up time: 56 sec
  TCP connection: 10.22.22.2:9001--10.11.11.1:646, State: ESTABLISHED 
  Neighboring interfaces: (targeted), Eth 1/1
  Next-hop addresses received from the peer:4
  10.9.1.1	10.10.1.1	10.11.11.1	10.11.11.12
  Graceful restart: enabled
  Peer reconnect time(msec): 120000, peer recovery time(msec): 120000
  Recovery time in use(msec): 120000, remaining time(msec): 103000
  State: recovering

The following example displays information about the configured and peer proposed keepalive timeout, and FEC label information including the count of installed, received, and filtered FEC labels.

device# show mpls ldp session 10.0.0.13
Peer LDP ID: 10.0.0.13:0, Local LDP ID: 10.0.0.1:0, State: Operational
  Adj: Link, Role: Passive, Next keepalive: 3 sec, Hold time left: 33 sec
  Keepalive interval: 6 sec, Max hold time: 36 sec
  Configured keepalive timeout: 36 sec 
  Peer proposed keepalive timeout: 36 sec 
  Up time: 4 min 56 sec
  TCP connection: 10.0.0.1:646--10.0.0.13:9098, State: ESTABLISHED 
  Neighboring interfaces: Eth 2/1	
  Next-hop addresses received from the peer:11
  10.0.0.13 192.168.3.2 192.168.6.2 192.168.9.2 192.168.12.2
  192.168.16.2 192.168.19.1 192.168.20.1 192.168.28.2 192.168.40.2
  192.168.45.2
  IGP Sync:
    Unrecognized Notification Capability: Local: Off, Remote: Off
    Local State: In-sync, RemoteState: -
    Rx label silence time: 1000 ms, Timer not running
  Graceful restart: disabled
  Number of FECs Received from peer: 4013
  Number of FECs installed from peer: 4005
  Number of FECs filtered from peer(in/out): 0/0

Displaying LDP neighbor connection information

To display information about the connection between this LSR and its LDP-enabled neighbors, use the show mpls ldp neighbor command.

device# show mpls ldp neighbor	
Number of link neighbors: 2
Number of targeted neighbors: 1

Nbr Transport   Interface   Nbr LDP ID   Max Hold    Time Left
10.1.1.1        Eth 4/1     10.1.1.1:0   15          14
10.5.5.5        Eth 3/2     10.5.5.5:0   15          11
10.4.4.4        (targeted)  10.4.4.4:0   15          13

To display the adjacency uptime since the LDP adjacency is established, use the show mpls ldp neighbor detail command.

device# show mpls ldp neighbor detail
Nbr Transport Addr: 10.22.22.1, Interface: e1/1, Nbr LDP ID: 10.22.22.1:0
 MaxHold: 15 sec, Time Left: 13 sec, Up Time: 14 hr 13 min 6 sec
 Configured Hold time: 15 sec, Neighbor Proposed Hold Time: 15 sec

Nbr Transport Addr: 10.22.22.1, Interface: e1/2, Nbr LDP ID: 10.22.22.1:0
 MaxHold: 15 sec, Time Left: 12 sec, Up Time: 14 hr 13 min 1 sec
 Configured Hold time: 15 sec, Neighbor Proposed Hold Time: 15 sec

Nbr Transport Addr: 10.33.33.1, Interface: e1/3, Nbr LDP ID: 10.33.33.1:0
 MaxHold: 15 sec, Time Left: 13 sec, Up Time: 14 hr 13 min 5 sec
 Configured Hold time: 15 sec, Neighbor Proposed Hold Time: 15 sec

Nbr Transport Addr: 10.33.33.1, Interface: targeted, Nbr LDP ID: 10.33.33.1:0
 MaxHold: 15 sec, Time Left: 10 sec, Up Time: 14 hr 13 min 3 sec
 Configured Hold time: 15 sec, Neighbor Proposed Hold Time: 15 sec

Displaying the LDP packet statistics

To display a packet statistics for packet types and packet errors, use the show mpls ldp statistics command.

device# show mpls ldp statistics
                   Total	                 Since last clear
MessageType        Sent          Received      Sent          Received
  Notify           3             0             3             0
  Link Hello       112254        112253        112254        112253
  Targeted Hello   6824          6775          6824          6775
  Initialize       7             8             7             8
  Keepalive        42470         43875         42470         43875
  Addr             42            11            42            11
  AddrWdrw         25            13            25            13
  LabelMap         26851         1654          26851         1654
  LabelReq         0             0             0             0
  LabelWdrw        9228          18            9228          18
  LabelRel         18            32            18            32
  LabelAbReq       0             0             0             0
  Unknown          0             0             0             0

Errors                         Total                 Since last clear
  Rcv pkt bad pdu length       0                     0
  Rcv pkt bad msg length       0                     0
  Rcv pkt bad tlv length       0                     0
  Rcv pkt notify unkn tlv      0                     0
  Rcv pkt notify unkn addrfam  0                     0
  Rcv pkt missing tlv          0                     0
  Rcv pkt incorrect tlv        0                     0
  Rcv pkt malformed tlv        0                     0
  Rcv pkt bad traffic parm     0                     0
  Rcv pkt partial pdu          0                     0
  Rcv pkt internal error       0                     0
  TCP get send pkt error       0                     0
  TCP send error               0                     0
  TCP memory fail              0                     0