If a network has loops, it is recommended that you set a relatively large path cost for ports with
low link rates. STP/RSTP then blocks these ports.
Procedure
Step 1
Run:
system-view
The system view is displayed.
Step 2
Run:
stp pathcost-standard
{
dot1d-1998
|
dot1t
|
legacy
}
A path cost calculation method is configured.
By default, the IEEE 802.1t standard (
dot1t
) is used to calculate the default path cost.
All switching devices on a network must use the same path cost calculation method.
Step 3
Run:
interface
interface-type interface-number
The Ethernet interface view is displayed.
Step 4
Run:
stp cost
cost
A path cost is set for the interface.
l
When the Huawei proprietary calculation method is used,
cost
ranges from 1 to 200000.
l
When the IEEE 802.1d standard method is used,
cost
ranges from 1 to 65535.
l
When the IEEE 802.1t standard method is used,
cost
ranges from 1 to 200000000.
----End
7.3.5 (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 will be selected as a designated port is determined by its priority. For details, see
.
To block a port to eliminate loops, set the port priority value to be larger than the default value
when the devices have the same bridge ID and path cost. This port will be blocked during
designated port selection.
Procedure
Step 1
Run:
system-view
The system view is displayed.
Huawei AR3200 Series Enterprise Routers
Configuration Guide - LAN
7 STP/RSTP Configuration
Issue 02 (2012-03-30)
Huawei Proprietary and Confidential
Copyright © Huawei Technologies Co., Ltd.
192