H3C S9500 Command Manual-Release1648[v1.24]-05 MPL VPN Volume

HomeSupportSwitchesH3C S9500 Series SwitchesReference GuidesCommand ReferencesH3C S9500 Command Manual-Release1648[v1.24]-05 MPL VPN Volume
01-MPLS Commands
Title Size Download
01-MPLS Commands 122.43 KB

Chapter 1  MPLS Basic Configuration Commands

1.1  MPLS Basic Configuration Commands

1.1.1  debugging mpls lspm

Syntax

debugging mpls lspm { agent | all | event | ftn | interface | packet | policy | process | vpn }

undo debugging mpls lspm { agent | all | event | ftn | interface | packet | policy | process | vpn }

View

User view

Parameters

agent: Enables all MPLS Agent debugging.

all: Enables all MPLS-related debugging.

event: Enables debugging for various MPLS events.

ftn: Enables MPLS FTN debugging.

interface: Enables the MPLS debugging on the message sending/receiving interface.

packet: Enables MPLS packet debugging.

policy: Enables MPLS policy debugging.

process: Enables debugging of MPLS internal processing.

vpn: Enables all MPLS VPN debugging.

Description

Use the debugging mpls lspm command to enable various LSPM debugging.

Use the undo debugging mpls lspm command to disable the corresponding debugging.

By default, all debugging is disabled.

This command is used to the debug MPLS LSPM. As running the debugging will affect the performance of the H3C S9500 Series Routing Switches, you are recommended to use the command with caution.

Examples

# Enable all MPLS VPN debugging.

<H3C> debugging mpls lspm vpn

1.1.2  display mpls interface

Syntax

display mpls interface

View

Any view

Parameters

None

Description

Use the display mpls interface command to view the information of all MPLS-enabled interfaces.

Related commands: display mpls lsp, display mpls statistics, display static-lsp.

Examples

# Display the information of all MPLS-enabled interfaces.

<H3C> display mpls interface

MPLS interface information:

  Interface Vlan-interface12 ( Label Range : 0-44800 )

  Interface Vlan-interface23 ( Label Range : 0-44800 )

  Interface Vlan-interface21 ( Label Range : 0-44800 )

  Interface Vlan-interface20 ( Label Range : 0-44800 )

  Interface Vlan-interface194 ( Label Range : 0-44800 )

  Interface Vlan-interface104 ( Label Range : 0-44800 )

  Interface Vlan-interface76 ( Label Range : 0-44800 )

  Interface Vlan-interface22 ( Label Range : 0-44800 )

  Interface Vlan-interface193 ( Label Range : 0-44800 )

  Interface Vlan-interface27 ( Label Range : 0-44800 )

1.1.3  display mpls lsp

Syntax

display mpls lsp [ include text | verbose ]

View

Any view

Parameters

include text: Displays the matching string including the specified information.

verbose: Displays detailed information.

Description

Use the display mpls lsp command to display LSP information.

By default, the display mpls lsp command displays all LSP information.

Related commands: display mpls interface, display mpls statistics, display static-lsp.

Examples

# Display all the LSPs including “-----------”.

<H3C> display mpls lsp include -----

--------------------------------------------------------------------                 LSP Information: Ldp                Lsp              

NO        FEC               NEXTHOP         I/O-LABEL    OUT-INTERFACE      

1     10.110.1.0/24       10.110.1.1      3/-----         -------           

2     10.10.10.0/24       10.10.10.1      3/-----         -------           

3     10.100.20.20/32     127.0.0.1       3/-----         -------           

4     5.5.5.5/32           127.0.0.1       3/-----         -------          

5     10.100.20.0/24      10.100.20.20    3/-----        -------    

6     80.80.80.80/32      127.0.0.1        3/-----        -------       

7     70.70.70.70/32      200.5.5.4       -----/3        Vlan2000       

TOTAL:  7 Record(s) Found.                  

1.1.4  display mpls static-lsp

Syntax

display mpls static-lsp [ include text | verbose ]

View

Any view

Parameters

include text: Displays the matching string including the specified information .

verbose: Displays detailed information.

Description

Use the display mpls static-lsp command to view the information of one static LSP or all.

Related commands: display mpls interface, display mpls lsp, display mpls statistics.

Examples

# Display the static LSP information.

<H3C> display mpls static-lsp

--------------------------------------------------------------------

                 LSP Information: Static Lsp            

--------------------------------------------------------------------

NO        FEC               NEXTHOP         I/O-LABEL    OUT-INTERFACE      

1     1.1.1.1/32          200.5.5.4       -----/1000   Vlan2000     

TOTAL:  1 Record(s) Found.              

1.1.5  display mpls statistics

Syntax

display mpls statistics { interface { Vlan-interface | all } | lsp { lsp-Index | all | lsp-name }}

View

Any view

Parameters

interface { Vlan-interface | all }: Specifies one interface or all interfaces.

lsp { lsp-Index | all | lsp-name }: Specifies one label switching path or all label switching paths. Where lsp-Index is an LSP index, lsp-name is an LSP name, and all represents all LSPs.

Description

Use the display mpls statistics command to view the MPLS statistics about one specific VLAN interface/LSP or all interfaces/LSPs.

Related commands: display mpls interface, display mpls lsp.

Examples

# Display MPLS statistics about all LSPs

<H3C> display mpls statistics lsp all

Building the information...

  LSP Index/LSP Name :  10240/dynamic-lsp

  There is no information of LSP incoming segment!

  The statistics of lsp Out :

    OutSegment octets of LSP is: 162876

    OutSegment packets of LSP is: 2943

    OutSegment errors of LSP is: 0

    OutSegment discard packets of LSP is: 0                             

1.1.6  lsp-trigger

Syntax

lsp-trigger { all | ip-prefix ip-prefix }

undo lsp-trigger { all | ip-prefix ip-prefix }

View

MPLS view

Parameters

all: Triggers LSPs at any route.

ip-prefix: Triggers LSPs only at the routes matching the specified IP prefix list.

ip-prefix: IP prefix list, ranging from 1 to 19.

Description

Use the lsp-trigger command to configure topology-triggered LSP creation policy.

Use the undo lsp-trigger command to remove the filtering conditions specified by parameters and disable LSP trigger creation at any route.

By default, all kinds of routing protocols are filtered out.

 

&  Note:

l      If no route-triggered policy is configured, LSPs can be triggered at all host routes with 32-bit masks.

l      If you import an IP-prefix rule without contents, LSPs can be triggered at all routes.

l      After you change a route-triggered policy, you need to reset the session on the interface to make the policy take effect.

 

Related commands: ip ip-prefix.

Examples

# Triggers LSPs at all routes.

<H3C> system-view

[H3C] mpls

[H3C-mpls] lsp-trigger all

1.1.7  mpls

Syntax

mpls

undo mpls

View

System view, VLAN interface view

Parameters

None

Description

In system view, input the mpls command for an initial use to enable MPLS function globally and enter MPLS view. Later you can go straight to the MPLS view with this command.

Use the mpls command in VLAN interface view to enable MPLS on the VLAN interface.

Use the undo mpls command to disable MPLS function in the system view or on the VLAN interface.

By default, you cannot enter this view.

After executing the command, you are in MPLS view. You can configure other MPLS commands only when you are in MPLS view.

You must configure the mpls lsr-id command before you can enter MPLS view.

Examples

# Enter MPLS view from system view.

<H3C> system-view

[H3C] mpls

[H3C-mpls]

# Execute the mpls command in interface view.

[H3C] vlan 201

[H3C-Vlan201] port gigabitethernet 2/1/1

[H3C-Vlan201] quit

[H3C] interface vlan-interface 201

[H3C-vlan-interface201] mpls

% Info: MPLS in the interface is starting, please wait...OK

1.1.8  mpls lsr-id

Syntax

mpls lsr-id ip-address

undo mpls lsr-id

View

System view

Parameters

ip-address: LSR ID, in the format of IP address, used to identify an LSR.

Description

Use the mpls lsr-id command to configure an LSR ID.

Use the undo mpls lsr-id command to delete an LSR ID.

By default, no LSR has an ID.

You must configure the mpls lsr-id command first and then you can use the other MPLS-related commands.

An LSR ID is in the format of IP address, thus a loopback address is recommended.

Related commands: display mpls interface.

Examples

# Set the LSR ID to 202.17.41.246.

<H3C> system-view

[H3C] mpls lsr-id 202.17.41.246

% Info: Mpls lsr-id changed. 

1.1.9  mpls settrap bad_ttl

Syntax

mpls settrap bad_ttl priority type

View

System view

Parameters

priority: Priority of a packet to de dropped, in the range of 0 to 7. The default is 0.

type: Type of operation: 0 to drop the packet and 1 to trap the packet to the CPU. The default is 0.

Description

Use the mpls settrap bad_ttl command to configure how the device should handle an MPLS data packet with a bad TTL.

By default, the device drops MPLS data packets with an outer label TTL of 0. You can use the mpls settrap bad_ttl command to have such packets trapped to the CPU.

Parameters

# Configure the device to send MPLS packet with a bad outer label TTL to the CPU.

<H3C> system-view

[H3C] mpls settrap bad_ttl 0 1

1.1.10  snmp-agent trap enable ldp

Syntax

snmp-agent trap enable ldp

undo snmp-agent trap enable ldp

View

System view

Parameters

None

Description

Use the snmp-agent trap enable ldp command to enable Trap function in MPLS LDP creation.

Use the undo snmp-agent trap enable ldp command to disable Trap function in MPLS LDP creation.

By default, Trap function is not enabled during MPLS LDP creation.

Examples

# Enable the Trap function during MPLS LDP creation.

<H3C> system-view

[H3C] snmp-agent trap enable ldp

1.1.11  snmp-agent trap enable lsp

Syntax

snmp-agent trap enable lsp

undo snmp-agent trap enable lsp

View

System view

Parameters

None

Description

Use the snmp-agent trap enable lsp command to enable Trap function in MPLS LSP creation.

Use the undo snmp-agent trap enable lsp command to disable Trap function in MPLS LSP creation.

By default, Trap function is disabled during MPLS LSP creation.

Examples

# Enable the Trap function during MPLS LSP creation.

<H3C> system-view

[H3C] snmp-agent trap enable lsp

1.1.12  static-lsp egress

Syntax

static-lsp egress lsp-name [ l2vpn ] incoming-interface interface-type interface-number in-label in-label-value

undo static-lsp egress lsp-name

View

MPLS view

Parameters

lsp-name: LSP name

interface-type Interface-number: Interface type, interface number.

in-label-value: Value of inbound label, ranging 3 (implicit empty label) and from 16 to 1023.

Description

Use the static-lsp egress command to configure a static LSP for an egress LSR.

Use the undo static-lsp egress command to delete an LSP for an egress LSR.

Related commands: static-lsp ingress, static-lsp transit, debugging mpls.

Examples

# Configure a static LSP named bj-sh on the egress LSR.

<H3C> system-view

[H3C-mpls] static-lsp egress bj-sh incoming-interface vlan-interface 201 in-label 233

1.1.13  static-lsp ingress

Syntax

static-lsp ingress lsp-name { destination dest-addr { addr-mask | mask-length } | l2vpn } nexthop next-hop-addr } } out-label out-label-value

undo static-lsp ingress lsp-name

View

MPLS view

Parameters

lsp-name: LSP name

dest-addr: Destination IP address.

addr-mask: Destination IP address mask.

mask-length: Mask length of destination IP address

next-hop-addr: Next-hop address.

out-label-value: Value of outbound label, ranging 3 (implicit empty label) and from 16 to 1023.

Description

Use the static-lsp ingress command to configure a static LSP for an ingress LSR.

Use the undo static-lsp ingress command to delete an LSP for an ingress LSR.

Related commands: static-lsp egress, static-lsp transit, debugging mpls.

Examples

# Configure a static LSP for the ingress LSR heading for the destination address 202.25.38.1.

<H3C> system-view

[H3C] mpls

[H3C-mpls] static-lsp ingress bj-sh destination 202.25.38.1 24 nexthop 202.55.25.33 out-label 237

1.1.14  static-lsp transit

Syntax

static-lsp transit lsp-name [ l2vpn ] incoming-interface interface-type interface-number in-label in-label-value nexthop next-hop-addr out-label out-label-value

undo static-lsp transit lsp-name

View

MPLS view

Parameters

lsp-name: LSP name

interface-type Interface-number: Interface type, interface number.

next-hop-addr: Next-hop address.

in-label-value: Value of inbound label, ranging from 16 to 1023.

out-label-value: Value of outbound label, ranging 3 (implicit empty label) and from 16 to 1023.

Description

Use the static-lsp transit command to configure a static LSP for a transit LSR.

Use the undo static-lsp transit command to delete an LSP for a transit LSR.

Related commands: static-lsp egress, static-lsp ingress.

Examples

# Configure a static LSP for the VLAN201 interface on a transit LSR, with an inbound label of 123 and an outbound label of 253.

<H3C> system-view

[H3C] mpls

[H3C-mpls] static-lsp transit bj-sh incoming-interface vlan-interface 201 in-label 123 nexthop 202.34.114.7 out-label 253

1.2  LDP Configuration Commands

1.2.1  debugging mpls ldp

Syntax

debugging mpls ldp { all | main | advertisement | session | pdu | notification | remote | filter } [ interface interface-type interface-number ]

undo debugging mpls ldp { all | main | advertisement | session | pdu | notification | remote | filter } [ interface interface-type interface-number ]

View

User view

Parameters

all: Displays all debugging information related to LDP.

main: Displays the debugging information of LDP main tasks.

advertisement: Displays the debugging information during LDP advertising.

session: Displays debugging information during LDP session processing.

pdu: Displays the debugging information during PDU packet processing.

notification: Displays the debugging information during notification.

remote: Displays debugging information of all Remote Peers.

filter: Displays debugging information of all filters.

interface-type interface-number: Interface type, interface number.

Description

Use the debugging ldp command to enable the debugging of various LDP messages. Use the undo debugging ldp command to disable the debugging of various LDP messages.

You are advised to use the debugging command cautiously.

Examples

# Enable LDP debugging.

<H3C> debugging mpls ldp all

1.2.2  display mpls ldp

Syntax

display mpls ldp

View

Any view

Parameters

None

Description

Use the display mpls ldp command to display LDP and LSR information.

By default, it displays information of LDP and LSR.

Related commands: mpls ldp, mpls ldp hops-count, mpls ldp loop-detect, mpls ldp path-vectors.

Examples

# Display LDP and LSR information.

<H3C> display mpls ldp

Label Distribution Protocol: V1

LSR ID: 10.10.10.10      LSR Status: Active

Loop Detection: Disabled.

Path Vector Limit: 32              Hop Count Limit: 32

DU Readvertisement: On             Request   Retry: Off

Label Retention Mode: Liberal      DU Explicit Request: Off

Label Distribution Control Mode: Ordered.

1.2.3  display mpls ldp buffer-info

Syntax

display mpls ldp buffer-info

View

Any view

Parameters

None

Description

Use the display mpls ldp buffer-info command to view the LDP buffer information.

Examples

# Display the LDP buffer information.

<H3C> display mpls ldp buffer-info

---------------------------------------------------------------

Buffer-Name     Buffer-ID    Buffer-Size  Total-Count  Free-Count

ENTITY          0            292          199          195

LOCAL-IF        1            36           200          196

PEER-IF         2            40           201          195

PDU                  3            204          249          249

ADJACENCY        4            56           201          198

PEER-INF             5            116          201          198

SESSION              6            176          201          198

US-BLK               7            264          1052         1028

DS-BLK               8            240          1052         1042

FEC                  9            40           1042         1032

US-LIST         10           16           1052         1028

TRIG-BLK        11           56           2076         2071

LABEL-RANGE     12           20           198          198

CR-TUNNEL       13           124          128          128

ER-HOP          14           40           4096         4096

IF-MSG          15           24           9999         9999

-----------------------------------------------------------------

Buffer no error.                                                      

1.2.4  display mpls ldp interface

Syntax

display mpls ldp interface [ | begin text | exclude text | include text ]

View

Any view

Parameters

|: Displays matched outputs.

begin: Displays the outputs matching the regular expression from the first line.

exclude: Displays the outputs excluding those lines matching the regular expression.

include: Displays only those outputs matching the regular expression.

text: Contents of the regular expression.

Description

Use the display mpls ldp interface command to display information of the interface with LDP enabled and in the Up state.

Related commands: mpls ldp enable, display mpls ldp session.

Examples

# Display the information of the interface with LDP enabled and in the UP state.

<H3C-Ethernet3/1/0> display mpls ldp interface

Displaying information about all Ldp interface:

     Interface Vlan-interface12(address=12.12.12.2):

     Label distributing enabled,bound to entity:2.2.2.2:0

     Generic label range configured:16 -  44800

     Label Advertisement Mode: Downstream-Unsolicited

     Configured KeepAlive hold time:60, Configured Hello hold time:15

     Negotiated Hello hold time:15

     Hello packets sent/rcv:21158/21136

 

     Interface Vlan-interface21(address=21.21.21.2):

     Label distributing enabled,bound to entity:2.2.2.2:0

     Generic label range configured:16 -  44800

     Label Advertisement Mode: Downstream-Unsolicited

     Configured KeepAlive hold time:60, Configured Hello hold time:15

     Negotiated Hello hold time:0

     Hello packets sent/rcv:16929/0

 

     Interface Vlan-interface22(address=22.22.22.2):

     Label distributing enabled,bound to entity:2.2.2.2:0

     Generic label range configured:16 -  44800

     Label Advertisement Mode: Downstream-Unsolicited

     Configured KeepAlive hold time:60, Configured Hello hold time:15

     Negotiated Hello hold time:15

     Hello packets sent/rcv:21175/21159

 

     Interface Vlan-interface23(address=23.23.23.2):

     Label distributing enabled,bound to entity:2.2.2.2:0

     Generic label range configured:16 -  44800

     Label Advertisement Mode: Downstream-Unsolicited

     Configured KeepAlive hold time:60, Configured Hello hold time:15

     Negotiated Hello hold time:15

     Hello packets sent/rcv:20970/20949

     Interface Vlan-interface194(address=192.4.1.1):

     Label distributing enabled,bound to entity:2.2.2.2:0

     Generic label range configured:16 -  44800

     Label Advertisement Mode: Downstream-Unsolicited

     Configured KeepAlive hold time:60, Configured Hello hold time:15

     Negotiated Hello hold time:0

     Hello packets sent/rcv:15296/0

1.2.5  display mpls ldp lsp

Syntax

display mpls ldp lsp [ | begin text | exclude text | include text ]

View

Any view

Parameters

|: Displays matched outputs.

begin: Displays the outputs matching the regular expression from the first line.

exclude: Displays the outputs excluding those lines matching the regular expression.

include: Displays only those outputs matching the regular expression.

text: Contents of the regular expression.

Description

Use the display mpls ldp lsp command to view relevant LSP information created via LDP.

Related commands: display mpls lsp.

Examples

# Display LSP.

<H3C-Ethernet3/1/0> display mpls ldp lsp

--------------------------------------------------------------------------------

                              LDP LSP Information

--------------------------------------------------------------------------------

No.  FECType  DestAddress        InLab OLab  UHC DHC Next-Hop       OutInterface

1    PREFIX   2.2.2.2            3     ----  0   1   127.0.0.1      InLoop0

2    PREFIX   2.2.2.2            3     ----  0   1   127.0.0.1      InLoop0

3    PREFIX   192.4.1.0/24       3     ----  0   1   192.4.1.1      Vlan194

4    PREFIX   192.4.1.0/24       3     ----  0   1   192.4.1.1      Vlan194

     Liberal  12.12.12.0/24      ----  3     --- 1   --------       Vlan22

5    PREFIX   12.12.12.0/24      3     ----  0   1   12.12.12.2     Vlan12

6    PREFIX   12.12.12.0/24      3     ----  0   1   12.12.12.2     Vlan12

     Liberal  16.16.16.0/24      ----  1026  --- 2   --------       Vlan23

     Liberal  16.16.16.0/24      ----  3     --- 1   --------       Vlan22

7    PREFIX   16.16.16.0/24      3     ----  0   1   16.16.16.16    Vlan16

8    PREFIX   16.16.16.0/24      3     ----  0   1   16.16.16.16    Vlan16

9    PREFIX   22.22.22.0/24      3     ----  0   1   22.22.22.2     Vlan22

     Liberal  1.1.0.5/32         ----  1024  --- 2   --------        ------

10   PREFIX   1.1.0.5            1024  3     0   1   23.23.23.3     Vlan23

11   PREFIX   1.1.0.5            ----  3     1   1   23.23.23.3     Vlan23

     Liberal  85.12.0.1/32       ----  1025  --- 2   --------        ------

12   PREFIX   85.12.0.1          1025  3     0   1   23.23.23.3     Vlan23

13   PREFIX   85.12.0.1          ----  3     1   1   23.23.23.3     Vlan23

1.2.6  display mpls ldp peer

Syntax

display mpls ldp peer [ | begin text | exclude text | include text ]

View

Any view

Parameters

|: Displays matched outputs.

begin: Displays the outputs matching the regular expression from the first line.

exclude: Displays the outputs excluding those lines matching the regular expression.

include: Displays only those outputs matching the regular expression.

text: Contents of the regular expression.

Description

Use the display mpls ldp peer command to view peer information.

By default, it displays all the peer information.

Examples

# Display peer information.

<H3C> display mpls ldp peer

Displaying information about all peers:

 

   Local LDP ID: 2.2.2.2:0

   Peer LDP ID: 1.1.1.1:0

   Internetwork Address Type: IPv4

   Internetwork Address: 1.1.1.1

   Maximum Peer PDU length: 4096

   Peer KeepAlive hold time: 60

   Peer Distribution Method: Downstream Unsolicited

   Peer Type: Remote

   Peer RowStatus: Active

 

   Local LDP ID: 2.2.2.2:0

   Peer LDP ID: 3.3.3.3:0

   Internetwork Address Type: IPv4

   Internetwork Address: 3.3.3.3

   Maximum Peer PDU length: 4096

   Peer KeepAlive hold time: 60

   Peer Distribution Method: Downstream Unsolicited

   Peer Type: Remote

   Peer RowStatus: Active

 

   Local LDP ID: 2.2.2.2:0

   Peer LDP ID: 1.1.1.1:0

   Internetwork Address Type: IPv4

   Internetwork Address: 1.1.1.1

   Maximum Peer PDU length: 4096

   Peer KeepAlive hold time: 60

   Peer Distribution Method: Downstream Unsolicited

   Peer Type: Local

   Peer RowStatus: Active

 

   Local LDP ID: 2.2.2.2:0

   Peer LDP ID: 1.1.1.1:0

   Internetwork Address Type: IPv4

   Internetwork Address: 1.1.1.1

   Maximum Peer PDU length: 4096

   Peer KeepAlive hold time: 60

   Peer Distribution Method: Downstream Unsolicited

   Peer Type: Local

   Peer RowStatus: Active

 

   Local LDP ID: 2.2.2.2:0

   Peer LDP ID: 3.3.3.3:0

   Internetwork Address Type: IPv4

   Internetwork Address: 3.3.3.3

   Maximum Peer PDU length: 4096

   Peer KeepAlive hold time: 60

   Peer Distribution Method: Downstream Unsolicited

   Peer Type: Local

   Peer RowStatus: Active

1.2.7  display mpls ldp remote

Syntax

display mpls ldp remote [ | begin text | exclude text | include text ]

View

Any view

Parameters

|: Displays matched outputs.

begin: Displays the outputs matching the regular expression from the first line.

exclude: Displays the outputs excluding those lines matching the regular expression.

include: Displays only those outputs matching the regular expression.

text: Contents of the regular expression.

Description

Use the display mpls ldp remote command to view the configured Remote-peer information.

By default, you can view all the Remote-peer configurations.

Related commands: mpls ldp remote-peer, remote-ip.

Examples

# Display the Remote-peer configuration.

<H3C> display mpls ldp remote

Displaying information about all Ldp Remote Peers:

     Remote Index: 1

     Peer Address: 1.1.1.1  Transport Address: 2.2.2.2

     Configured KeepAlive hold time:60, Configured Hello hold time:45

     Negotiated Hello hold time:45

     Hello packets sent/rcv:6515/6509

 

     Remote Index: 3

     Peer Address: 3.3.3.3  Transport Address: 2.2.2.2

     Configured KeepAlive hold time:60, Configured Hello hold time:45

     Negotiated Hello hold time:45

     Hello packets sent/rcv:6457/6453

 

     Remote Index: 4

     Peer Address: 1.1.0.3  Transport Address: 2.2.2.2

     Configured KeepAlive hold time:60, Configured Hello hold time:45

     Negotiated Hello hold time:0

     Hello packets sent/rcv:0/0

 

     Remote Index: 7

     Peer Address: 1.1.1.7  Transport Address: 2.2.2.2

     Configured KeepAlive hold time:60, Configured Hello hold time:45

     Negotiated Hello hold time:0

     Hello packets sent/rcv:0/0

1.2.8  display mpls ldp session

Syntax

display mpls ldp session [ | begin text | exclude text | include text ]

View

Any view

Parameters

|: Displays matched outputs.

begin: Displays the outputs matching the regular expression from the first line.

exclude: Displays the outputs excluding those lines matching the regular expression.

include: Displays only those outputs matching the regular expression.

text: Contents of the regular expression.

Description

Use the display mpls ldp session command to know the session between peer entities.

By default, it displays the session between peer entities.

Related commands: mpls ldp enable.

Examples

# Display the session between peer entities.

<H3C> display mpls ldp session

Displaying information about all sessions

 

Local LDP ID: 1.1.1.9:5;   Peer LDP ID: 4.4.4.9:0

   TCP Connection: 1.1.1.9 <- 4.4.4.9

   Session State: Operational

   Session Role: Passive

   Session existed time:

   Basic Hello Packets Sent/Received: 85/67

   KeepAlive Packets Sent/Received: 1/1

   Negotiated Keepalive hold time: 60   Peer PV Limit: 0

   LDP Basic Discovery Source((A) means active):

   Inter vlan113(A)            Inter vlan112

   Inter vlan111

1.2.9  mpls ldp

Syntax

mpls ldp

undo mpls ldp

View

System view

Parameters

None

Description

Use the mpls ldp command to enable LDP.

Use the undo mpls ldp command to disable LDP.

By default, LDP is disabled.

Before enabling LDP, you must enable MPLS and configure LSR ID first.

Related commands: mpls lsr-id.

Examples

# Enable LDP.

<H3C> system-view

[H3C] mpls ldp

1.2.10  mpls ldp enable

Syntax

mpls ldp enable

mpls ldp disable

View

VLAN interface view

Parameters

None

Description

Use the mpls ldp enable command to enable LDP on a VLAN interface.

Use the mpls ldp disable command to disable LDP on a VLAN interface.

By default, LDP is disabled on an interface.

To enable an interface, you must enable LDP first. After LDP is enabled on an interface, peer discovery and session creation proceed.

Examples

# Enable LDP on a VLAN interface.

<H3C> system-view

[H3C] vlan 201

[H3C-Vlan201] port gigabitethernet 2/1/1

[H3C-Vlan201] quit

[H3C] interface vlan-interface 201

[H3C-Vlan-interface201] mpls

[H3C-vlan-interface201] mpls ldp enable

1.2.11  mpls ldp hops-count

Syntax

mpls ldp hops-count hop-number

undo mpls ldp hops-count

View

System view

Parameters

hop-number: Maximum hop count of loop detection, ranging from 1 to 32.

Description

Use the mpls ldp hops-count command to set the maximum hop count of loop detection.

Use the undo mpls ldp hops-count command to restore the default value of the maximum hop count of loop detection.

By default, the maximum hop count of loop detection is 32.

If you need to enable loop detection, configure this command before LDP is enabled on all interfaces. Its value, which depends on actual networking, determines the loop detection speed during LSP creation

Related commands: mpls ldp loop-detect, mpls ldp path-vector.

Examples

# Set the maximum hop count of loop detection to 22.

<H3C> system-view

[H3C] mpls ldp hops-count 22

# Set the maximum hop count of loop detection to its default value 32.

[H3C] undo mpls ldp hops-count

1.2.12  mpls ldp loop-detect

Syntax

mpls ldp loop-detect

undo mpls ldp loop-detect

View

System view

Parameters

None

Description

Use the mpls ldp loop-detect command to enable loop detection.

Use the undo mpls ldp loop-detect command to disable loop detection.

By default, loop detection is not enabled in the system.

If you need to enable loop detection, configure this command before LDP is enabled on any interface.

Related commands: mpls ldp hops-count, mpls ldp path-vectors.

 

&  Note:

To make the loop detection take effect, you need to perform the same loop detection configurations on all devices in the same MPLS domain. If not, two neighboring sides with different loop detection configurations cannot establish the LDP session. This is because before the LDP initiates a session establishment, it checks whether the two sides have the same loop detection configurations.

 

Examples

# Enable loop detection.

<H3C> system-view

[H3C] mpls ldp loop-detect

# Disable loop detection.

[H3C] undo mpls ldp loop-detect

1.2.13  mpls ldp label-accept

Syntax

mpls ldp label-accept ip-prefix-name

undo mpls ldp label-accept ip-prefix-name

View

System view

Parameters

label-accept: Specifies an ingress label filtering policy.

ip-prefix-name: Name of IP address prefix list.

 Description

Use the mpls ldp label-accept command to control the acceptance of label binding through the IP address prefix filtering policy when a Label Mapping event is received.

Use the undo mpls ldp label-accept command to cancel the configuration.

Examples

# Configure to deny the Label Mapping information of 1.1.1.1 through 1.1.1.3. First, configure the corresponding IP Prefix.

<H3C> system-view

[H3C] ip ip-prefix fec index 1 deny 1.1.1.1 32

[H3C] ip ip-prefix fec index 2 deny 1.1.1.2 32

[H3C] ip ip-prefix fec index 3 deny 1.1.1.3 32

[H3C] ip ip-prefix fec index 100 permit 0.0.0.0 0 greater-equal 0 less-equal 32  

# Then, configure a specific IP Prefix that will be used in the policy for filtering ingress label mapping.

[H3C] mpls ldp label-accept fec

1.2.14  mpls ldp label-advertise

Syntax

mpls ldp label-advertise fec-ip-prefix [ lsr-ip-prefix ] [ swap-only ]

undo mpls ldp label-advertise { fec-ip-prefix | all }

View

System view

Parameters

label-advertise: Specifies a filtering policy for label mapping advertisement

fec-ip-prefix: FEC address prefix list

lsr-ip-prefix: LSR IP address prefix list

swap-only: Creates no Ingress LSP but Swap entries (only when the advertisement control policy is passed).

all: Deletes all filtering policies for label mapping advertisement.

Description

Use the mpls ldp label-advertise command to control the advertisement of locally distributed labels; that is, control which label mapping is advertised to which LDP peer.

Use the undo mpls ldp label-advertise command to cancel the configuration. By default, the labels of all destination addresses are advertised to all LDP peers.

Examples

# First, configure the IP Prefix corresponding to the FEC address prefix.

<H3C> system-view

[H3C]ip ip-prefix fec1 index 1 permit 1.1.1.1 32

[H3C]ip ip-prefix fec1 index 2 permit 1.1.1.2 32

# Then, configure the IP Prefix for the peer address used for advertisement.

<H3C> system-view

[H3C]ip ip-prefix peer1 index 1 permit  2.1.1.1 32

[H3C]ip ip-prefix peer1 index 2 permit  2.1.1.2 32

[H3C]ip ip-prefix fec2 index 1 permit 2.2.2.1 32

[H3C]ip ip-prefix fec2 index 2 permit 2.2.2.2 32

[H3C]ip ip-prefix peer2 index 1 permit  4.1.1.1 32

[H3C]ip ip-prefix peer2 index 2 permit  4.1.1.2 32

# Apply the configured IP Prefix of FEC address and the configured IP Prefix of the peer address in the filtering policy for outgoing label mapping advertisement.

<H3C> system-view

[H3C] mpls ldp label-advertise fec1 to peer1

# Configure to advertise the FEC message corresponding to FEC2 but not to create Ingress LSP.

[H3C] mpls ldp label-advertise fec2 to peer2 swap-only

1.2.15  mpls ldp password

Syntax

mpls ldp password [ cipher | simple ] password

undo mpls ldp password

View

VLAN interface view, remote-peer view

Parameters

cipher: Specifies that the password in configuration file will be displayed in cipher-text.

simple: Specifies that the password in configuration file will be displayed in plain-text.

password: User password.

Description

Use the mpls ldp password command to configure MD5 authentication password for the LDP. After this configuration, the MD5 authentication is adopted for LDP on the interface.

Use the undo mpls ldp password command to delete the configuration.

Examples

# Configure the LDP authentication mode as MD5, plain-text password 123.

<H3C> system-view

[H3C] interface vlan-interface 201

[H3C-vlan-interface201] mpls ldp password simple 123

1.2.16  mpls ldp path-vectors

Syntax

mpls ldp path-vectors pv-number

undo mpls ldp path-vectors

View

System view

Parameters

pv-number: Maximum value of path vector, ranging from 1 to 32.

Description

Use the mpls ldp path-vectors command to set the maximum value of path vector.

Use the undo mpls ldp path-vectors command to restore the default maximum value of path vector.

By default, pv-number is 32.

If you need to enable loop detection, configure this command before LDP is enabled on all interfaces. Its value, which depends on actual networking situation, determines the loop detection speed during LSP creation.

Related commands: mpls ldp loop-detect, mps ldp hops-count.

Examples

# Set the maximum value of path vector to 23.

<H3C> system-view

[H3C] mpls ldp path-vectors 23

# Restore the default maximum value of path vector.

[H3C] undo mpls ldp path-vectors

1.2.17  mpls ldp remote-peer

Syntax

mpls ldp remote-peer index

undo mpls ldp remote-peer index

View

System view or remote-peer view

Parameters

index: Index that identifies a remote peer entity, ranging from 0 to 99.

Description

Use the mpls ldp remote-peer command to create a Remote-peer entity and enter remote-peer view.

Use the undo mpls ldp remote-peer command to delete a Remote-peer entity.

You can use this command to create a Remote-peer and accordingly create a Remote-session.

Related commands: remote-ip.

Examples

# Create a Remote-peer.

<H3C> system-view

[H3C] mpls ldp remote-peer 22

[H3C-mpls-remote22]

# Delete a Remote-peer.

[H3C-mpls-remote22] undo mpls ldp remote-peer 22

[H3C]

1.2.18  mpls ldp reset-session

Syntax

mpls ldp reset-session peer-address

View

VLAN interface view

Parameters

peer-address: Corresponding remote LDP Peer address (in IP address format).

Description

Use the mpls ldp reset-session command to reset a specified session on an interface.

After LDP is configured on an interface and LDP session is created, this command can be used to reset a specific session on the interface. You only need to specify the address of the peer corresponding to the session to be reset.

Related commands: mpls ldp, mpls ldp enable.

Examples

# Reset a specified session on the VLAN201 interface.

<H3C> system-view

[H3C] interface vlan-interface 201

[H3C-Vlan-interface201] mpls ldp reset-session 10.1.1.1

1.2.19  mpls ldp timer

Syntax

In VLAN interface view:

mpls ldp timer { session-hold session-holdtime | hello hello-holdtime }

undo mpls ldp timer { session-hold | hello }

In remote-peer view:

mpls ldp timer { targeted-session-hold | targeted-hello } { holdtime holdtime | interval interval }

undo mpls ldp timer { targeted-session-hold | targeted-hello } { holdtime | interval }

View

VLAN interface view, remote-peer view

Parameters

hello hello-holdtime: Specifies the hold time (i.e. timeout time) of the Hello hold timer, in the range of 6 to 65535 (seconds). By default it is 15 seconds.

session-hold session-holdtime: Specifies the time interval for Session hold timer to send a session packet, in the range of 1 to 65535 (seconds). By default it is 60 seconds.

targeted-hello: Specifies the hold time (i.e. timeout time) of the Targeted-hello hold timer, in the range of 1 to 65535 (seconds). By default holdtime is 45 seconds and interval is 13 seconds.

targeted-session-hold: Specifies the time interval for Targeted-session hold timer to send a session packet, in the range of 1 to 65535 (seconds). By default holdtime is 60 seconds and interval is 24 seconds.

holdtime: Time interval for the hold timer.

interval: Time interval to send a Keepalive packet.

Description

Use the mpls ldp timer command to set the hold time for the Hello hold timer and Session hold timer.

Use the undo mpls ldp timer command to restore the default values.

The timeout of the Hello hold timer means that the adjacency with the peer goes down; the timeout of the Session hold timer means the session with the peer goes down.

targeted-hello interval refers to the time interval to send a targeted-hello packet. It cannot be greater than (targeted-hello holdtime) ´ 0.3, so the maximum value is 65535 ´ 0.3 = 19660.5.

targeted-session-hold interval refers to the time interval to send a Keepalive packet. It cannot be greater than (targeted-session-hold holdtime) ´ 0.4.

In general, the time interval to send a hello/keepalive packet is one third of the hold time of Hello/Session hold timer.

You can usually use the default values if not in special cases, Note that you must reset the session to validate new values if you do modify these timer parameters.

Related commands: mpls ldp, mpls ldp enable.

Examples

# Modify the hold time of the Hello timer to 30 seconds.

<H3C> system-view

[H3C] interface vlan-interface 201

[H3C-Vlan-interface201] mpls ldp timer hello 30

1.2.20  mpls ldp transport-ip

Syntax

mpls ldp transport-ip { interface | ip-address }

undo mpls ldp transport-ip

View

VLAN interface

Parameters

interface: Sets the IP address of the current interface as the transport address.

ip-address: Sets the IP address as the transport address.

Description

Use the mpls ldp transport-ip command to configure an LDP transport address.

Use the undo mpls ldp transport-ip command to restore the default LDP transport address.

By default, LSR ID is set as a transport address.

When there are multiple directly-connected and MPLS LDP-enabled links between two LSR neighbors, all these links must be configured with the same transport address (it is recommended to adopt the default LSR ID as the transport address). Otherwise, the system may be unable to set up a steady LDP session.

For a Remote-peer, the transport address cannot be configured and is fixed to the LSR ID.

By default, an LSR ID is the address of some Loopback interface and the Remote peer can route to this address for a session. For a Local peer, the address of the local interface or the Router ID of LSR can be adopted as its transport address.

Examples

# Set the address of the current interface as a transport address.

<H3C> system-view

[H3C] interface vlan-interface 201

[H3C-Vlan-interface201] mpls ldp transport-ip interface

# Set the address of another interface as a transport address.

[H3C-Vlan-interface201] mpls ldp transport-ip 10.1.11.2

1.2.21  remote-ip

Syntax

remote-ip remoteip

View

remote-peer view

Parameters

remoteip: IP address of the Remote-peer.

Description

Use the remote-ip command to configure a Remote-IP address. The address should be the lsr-id of the remote LSR. As Remote Peers adopt LSR ID as their transport addresses, the last two Remote Peers use the lsr-id as their transport addresses for creating TCP connection.

Related commands: mpls ldp remote-peer.

Examples

# Configure the address of remote-peer.

<H3C> system-view

[H3C] mpls ldp remote-peer 12

[H3C-mpls-remote12] remote-ip 192.168.1.1

 

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become A Partner
  • Partner Policy & Program
  • Global Learning
  • Partner Sales Resources
  • Partner Business Management
  • Service Business
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网