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

Reminder

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

upgrade

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).
Configuring Basic STP/RSTP Functions

Configuring Basic STP/RSTP Functions

STP/Rapid Spanning Tree Protocol (RSTP) is used to block redundant links on the Layer 2 network and trim a network into a loop-free tree topology.

Applicable Environment

On a complex network, loops are inevitable. With the requirement for network redundancy backup, network designers tend to deploy multiple physical links between two devices, one of which is the master and the others are the backup. Loops are likely or bound to occur in such a situation.

Loops will cause broadcast storms, thereby exhausting network resources and paralyzing the network. Loops also cause flapping of MAC address tables and thus damages MAC address entries.

STP/RSTP can be deployed on a network to eliminate loops. If a loop is detected, STP/RSTP blocks one port to eliminate the loop.

As shown in Figure 13-4, Device , Device B, Device C, and Device D form a ring network. STP or RSTP is deployed on the ring network to eliminate loops, enhancing reliability of the network.
Figure 13-4 Diagram of a ring network

NOTE:

If the current switching device supports STP and RSTP, RSTP is recommended.

Pre-configuration Tasks

Before configuring basic STP/RSTP functions, complete the following task:
  • Connecting interfaces and setting physical parameters for the interfaces to ensure that the physical status of the interfaces is Up

Configuration Procedures

Figure 13-5 Flowchart for configuring basic STP/RSTP functions

Configuring the STP/RSTP Mode

Before configuring basic STP/Rapid Spanning Tree Protocol (RSTP) functions, you need to configure the working mode of a switching device to STP/RSTP. RSTP is compatible with STP.

Procedure

  1. Run system-view

    The system view is displayed.

  2. Run stp mode { stp | rstp }

    The working mode of the switching device is configured as STP/RSTP.

    On a ring network running only STP, the working mode of a switching device is configured as STP; on a ring network running RSTP, the working mode of a switching device is configured as RSTP. In other cases, the working mode of a switching device is configured as MSTP by default.

  3. Run commit

    The configuration is committed.

(Optional) Configuring Switching Device Priorities

Select a switching device (functioning as a root bridge) from switching devices for each spanning tree. You can configure the priorities of the switching devices to preferentially select a root bridge. The lower the numerical value is, the higher priority a switching device has and the more likely the switching device will be selected as a root bridge.

Context

On an STP/RSTP-capable network, there is only one root bridge and it is the logic center of the entire spanning tree. In root bridge selection, the switching device with high performance and network hierarchy is generally selected as a root bridge; however, the priority of such a device may be not that high. Thus setting a high priority for the switching device is necessary so that the device can function as a root bridge.

Other devices with low performance and network hierarchy are not fit to be a root bridge. Therefore, set low priorities for these devices.

Procedure

  1. Run system-view

    The system view is displayed.

  2. Run stp priority priority

    The priority of a switching device is configured.

    NOTE:
    • To configure a switching device as a primary root bridge, you can run the stp root primary command directly. The priority value of this switching device is 0.

    • To configure a switching device as a secondary root bridge, run the stp root secondary command. The priority value of this switching device is 4096.

      A switching device cannot act as a primary root bridge and a secondary root bridge at the same time.

    • If you want to change the priority of a switching device after you run the stp root primary command or the stp root secondary command to configure the switching device as a primary root bridge or a secondary root bridge, disable the root bridge function or secondary root bridge function, and then run the stp priority priority command to re-set a priority.

  3. Run commit

    The configuration is committed.

(Optional) Configuring the Path Cost for a Port

The STP/Rapid Spanning Tree Protocol (RSTP) path cost determines root port selection. The port from which to the root port costs the least is selected as the root port.

Context

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

The range of the path cost value is determined by the calculation method. After the calculation method is determined, you are recommended to set a relatively small path cost value for the port at a high link rate.

Use the Huawei proprietory calculation method as an example. Different link rates correspond to default path cost values of ports. For details, see Table 13-4.
Table 13-4 Mappings between link rates and path cost values

Link Rate

Recommended value

Recommended Value Range

Value Range

10 Mbit/s

2000

200 to 20000

1 to 200000

100 Mbit/s

200

20 to 2000

1 to 200000

1 Gbit/s

20

2 to 200

1 to 200000

10 Gbit/s

2

2 to 20

1 to 200000

Over 10 Gbit/s

1

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. STP/RSTP puts the port with the large path cost in the Blocking state and blocks the link where this port resides.

Procedure

  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 calculation method for path costs.

  3. Run interface interface-type interface-number

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

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

  4. Run stp cost cost

    A path cost is set for the port.

    • 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.

(Optional) Configuring Port Priorities

In each spanning tree, select a designated port for each connection according to the bridge ID, the cost of path and port IDs. The lower the numerical value, the more likely the port on a switching device becomes a designated port; the higher the numerical value, the more likely the port is to be blocked.

Context

Whether a port on a switching device will be selected as a designated port is determined by its priority. For details, see Overview of STP/RSTP.

If you expect to block a port on a switching device to eliminate loops, set the port priority value to be larger than the default value when the devices have the same bridge ID and the cost of path. This port will be blocked in designated port selection.

Procedure

  1. Run system-view

    The system view is displayed.

  2. Run interface interface-type interface-number

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

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

  3. Run stp port priority priority

    The port priority is configured.

  4. Run commit

    The configuration is committed.

Enabling STP/RSTP

After STP/Rapid Spanning Tree Protocol (RSTP) is enabled, spanning trees are calculated.

Context

After STP/RSTP is enabled on a ring network, STP/RSTP immediately calculates spanning trees on the network. Configurations on the switching device, such as the switching device priority and port priority, will affect spanning tree calculation. Any change of the configurations may cause network flapping. Therefore, to ensure rapid and stable spanning tree calculation, perform basic configurations on the switching device and its ports and enable STP/RSTP.

Procedure

  1. Run system-view

    The system view is displayed.

  2. Run stp enable

    STP/RSTP is enabled on the switching device.

    By default, the STP/RSTP function is enabled on a ME60.

    NOTE:

    On an STP-capable Layer 2 network, packets with the same source MAC address may form loops. To prevent loops, an interface must be blocked, and an alarm must be reported to the NMS. However, STP and MAC flapping-based loop detection are mutually exclusive by default. To allow both STP and MAC flapping-based loop detection to be enabled, run the loop-detect eth-loop assist-stp enable command.

    STP and MAC flapping-based loop detection have different blocking principles and may block different interfaces on a network, leading to temporary traffic interruptions. Therefore, exercise caution when running the loop-detect eth-loop assist-stp enable command.

  3. Run commit

    The configuration is committed.

Verifying the Basic STP/RSTP Function Configuration

After basic STP/Rapid Spanning Tree Protocol (RSTP) functions are configured, you can view the information such as the port role and port status to check whether the spanning tree calculation is correctly performed.

Prerequisites

All configurations of basic STP/RSTP functions are complete.

Procedure

  • Run the display stp [ interface interface-typeinterface-number ] [ brief ] command to view spanning-tree status and statistics.
  • Run the display stp [ process process-id ] [ instance instance-id ] abnormal-interface command to view information about abnormal interfaces running the Spanning Tree Protocol (STP).

Example

Run the display stp command, and you can view the spanning-tree working mode, root bridge, priority of the root bridge, convergence mode, path cost calculation method, and path cost of a root port. For example:
<HUAWEI> display stp
-------[CIST Global Info][Mode RSTP]-------
CIST Bridge         :32768.00e0-4e1f-b200
Bridge Times        :Hello 2s MaxAge 20s FwDly 15s MaxHop 20
CIST Root/ERPC      :0    .00e0-e70a-4d00 / 20
CIST RegRoot/IRPC   :32768.00e0-4e1f-b200 / 0
CIST RootPortId     :128.1
BPDU-Protection     :Disabled
TC or TCN received  :0
TC count per hello  :0
STP Converge Mode   :Normal
Time since last TC  :0 days 0h:26m:16s
----[Port1(GigabitEthernet1/0/1)][FORWARDING]----
 Port Protocol       :enabled
 Port Role           :Root Port
 Port Priority       :128
 Port Cost(Legacy)  :Config=auto / Active=20
 Desg. Bridge/Port   :0.00e0-e70a-4d00 / 128.5
 Port Edged          :Config=default / Active=disabled
 Point-to-point      :Config=auto / Active=true
 Transit Limit       :147 packets/hello-time
 Protection Type     :None
 Port STP Mode       :RSTP
 Port Protocol Type  :Config=auto / Active=dot1s
 BPDU Encapsulation  :Config=stp / Active=stp
 PortTimes           :Hello 2s MaxAge 20s FwDly 15s RemHop 0
 TC or TCN send      :1
 TC or TCN received  :0
 BPDU Sent           :4
          TCN: 0, Config: 0, RST: 4, MST: 0
 BPDU Received       :22
          TCN: 0, Config: 0, RST: 22, MST: 0
----[Port2(GigabitEthernet1/0/3)][DISCARDING]----
 Port Protocol       :enabled
 Port Role           :Alternate Port
 Port Priority       :160
 Port Cost(Legacy)   :Config=auto / Active=20
 Desg. Bridge/Port   :4096.00e0-6606-be00 / 128.1
 Port Edged          :Config=default / Active=disabled
 Point-to-point      :Config=auto / Active=true
 Transit Limit       :147 packets/hello-time
 Protection Type     :None
 Port STP Mode       :RSTP
 Port Protocol Type  :Config=auto / Active=dot1s
 BPDU Encapsulation  :Config=stp / Active=stp
 PortTimes           :Hello 2s MaxAge 14s FwDly 10s RemHop 0
 TC or TCN send      :1
 TC or TCN received  :0
 BPDU Sent           :2
          TCN: 0, Config: 0, RST: 2, MST: 0
 BPDU Received       :22
          TCN: 0, Config: 0, RST: 22, MST: 0  

Run the display stp [ process process-id ] [ instance instance-id ] abnormal-interface command to view information about abnormal interfaces running the Spanning Tree Protocol (STP). For example:

<HUAWEI> display stp instance 0 abnormal-interface
MSTID    Interface                     Status          Reason                   
   0     GigabitEthernet2/0/0          DISCARDING      LOOP-Protected           
   0     GigabitEthernet2/0/1          DOWN            BPDU-Protected           
   0     GigabitEthernet2/0/2          DISCARDING      ROOT-Protected           
   0     GigabitEthernet2/0/3          DISCARDING      LOOP-Detected
Translation
Download
Updated: 2019-01-04

Document ID: EDOC1100059440

Views: 29788

Downloads: 21

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