No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search


To have a better experience, please upgrade your IE browser.


ME60 V800R010C10SPC500 Configuration Guide - LAN Access and MAN Access 01

This is ME60 V800R010C10SPC500 Configuration Guide - LAN Access and MAN Access
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
(Optional) Configuring a Path Cost of a Port in an MSTI

(Optional) Configuring a Path Cost of a Port in an MSTI

The Multiple Spanning Tree Protocol (MSTP) path cost determines root port selection in a Multiple Spanning Tree Instance (MSTI). The port with the lowest path cost to the root bridge is selected as a root port.


A path cost is port-specific, which is used by MSTP as a reference to select a link.

Path costs of a port are an important basis for calculating spanning trees. If you set different path costs for a port in different Multiple Spanning Tree Instances (MSTIs), you can make VLAN traffic be transmitted along different physical links and thus carry out VLAN load balancing.

Use the Huawei private calculation method as an example. The following table maps link rates and default path cost values of ports.
Table 14-1 Mapping between link rates and path cost values

Link Rate

Recommended Path Cost

Recommended Path Cost Range

Path Cost Range

10 Mbit/s


200 to 20000

1 to 200000

100 Mbit/s


20 to 2000

1 to 200000

1 Gbit/s


2 to 200

1 to 200000

10 Gbit/s


2 to 20

1 to 200000

Higher than 10 Gbit/s


1 to 2

1 to 200000

On a network where loops occur, you are recommended to set a relatively large path cost for the port at a low link rate. MSTP puts the port with the large path cost in the Blocking state and blocks the link where this port resides.


  1. Run system-view

    The system view is displayed.

  2. Run stp pathcost-standard { dot1d-1998 | dot1t | legacy }

    A path cost calculation method is configured.

    All switching devices on a network must use the same path cost calculation method.

  3. Run interface interface-type interface-number

    The view of the Ethernet interface participating in STP calculation is displayed.

    The following configuration can be configured both on a Layer 2 interface and a Layer 3 interface.

  4. Run stp instance instance-id cost cost

    A path cost is set for the port in the current MSTI.

    • When the Huawei proprietory calculation method is used, cost ranges from 1 to 200000.
    • When the IEEE 802.1d standard method is used, cost ranges from 1 to 65535.
    • When the IEEE 802.1t standard method is used, cost ranges from 1 to 2000,000,00.

  5. Run commit

    The configuration is committed.

Updated: 2019-01-04

Document ID: EDOC1100059440

Views: 26966

Downloads: 18

Average rating:
This Document Applies to these Products
Related Version
Related Documents
Previous Next