Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Note STP

2025-04-07 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

STP

-definition

-effect

-Typ

1. 802.1d-STP: spanning Tree Protocol PVST/PVST+ (Cisco)

2. 802.1w-RSTP: rapid spanning Tree Protocol PV-RSTP (Cisco)

3. 802.1s-MSTP: multiple spanning Tree Protocol

-message

PVST:per-vlan STP, that is, running a STP (802.1d) inside each VLAN

The working process of STP:

1. Determine the role of the switch

Root switch: there is one and only one in the entire switching network

Non-root switch: the remaining switches are called non-root switches.

Note: each non-root switch will calculate the shortest, loop-free, layer 2 data forwarding path to the root switch, and eventually the path is in the "forwarding" state. Election principle: compare the BID (bridge ID) of each switch: priority + MAC address priority: default value is 32768; 2 bytes MAC address: use the MAC;6 bytes of the motherboard of the switch; comparison principle-first compare the priority, the smaller the better; secondly, compare the MAC address, the smaller the better; 2. Determine the role of the port root port: on each non-root switch, there is and only one. The port closest to the root switch; designated port: there is one and only one in each "network segment / segment"; the port closest to the root switch Non-designated port: all other ports, called "non-designated port" 3, determine the status of the port down-off (meaning that the current port does not have STP enabled) listening-listening, listening on all BPDU in the network in order to determine the role of the switch and port The port stays in this state for 15s; learning-learning, this stage is mainly to learn the source MAC address of the data frame received on the port, thus forming the MAC address table; the port stays in this state for 15s Forwarding-forwarding (final state), which implements the sending and receiving of packets blocking-blocking (final state), which cannot send and receive packets; can only receive BPDU.

BPDU type:

1. Configure BPDU

Used to create and maintain STP loop-free forwarding tree

2 、 TCN BPDU

Only when the STP loop-free forwarding path tree (topology) changes

Generate and send.

And it is: the switch that senses the change, generates TCN BPDU, and only

Send it to the root switch, and then forward it to all others

Non-root switch

STP timer:

Hello: the interval at which the switch periodically sends BPDU. The default is 2s.

Forward-delay: forwarding delay. Default time is 15s.

Max-age: maximum aging time. Default time is 20s.

STP parameter modification (Cisco):

1. Modify the STP priority of the switch (make sure there are primary and secondary root switches in the network)

Spanning-tree vlan x priority {value}, value is a multiple of 4096

2. Modify the STP mode of the switch (you must make sure that the STP mode of all switches on the network is the same) spanning-tree mode {pvst | rapid-pvst | mstp} 3, modify the port cost interface fas0/22 of the switch (the link refers to the trunk link) spanning-tree vlan 3 cost {value} 4, turn off the STP function no spanning-tree vlan x for a certain VLAN

STP parameter modification (Huawei):

1. Modify the STP priority of the switch:

[SW] stp priority {value}-> must be a multiple of 4096

2. Modify the STP mode of the switch

[SW] stp mode {stp | rstp | mstp}

3. Modify the STP cost of the switch port:

[SW] interface fas0/13

[sw-fas0/13] stp cost {value}

4. Turn off / enable STP on the switch:

[sw] stp disable-> close STP

[sw] stp enable-> enable STP. Default is enabled.

Verify the command:

Show spanning-tree vlan x-> you can view STP information about VLAN x on the switch

Show spanning-tree-> you can view STP information about all VLAN on the switch.

Show spanning-tree summary-> you can view the mode of the STP that the switch is running

Show version-> you can view the base mac of the switch

Display stp display stp brief

Note:

The STP function on the switch is on by default; it can be turned off manually

=

Configuration of MSTP:

MST domain (region), which can contain multiple instances at the same time

MSTI (instance), that is, MST instance. A MSTI can be associated with multiple VLAN at the same time.

Configure MST region

[SW] stp region-configuration

[sw-mstp-region] name of region-name {string} / / configuration region

[sw-mstp-region] instance {id} vlan x y z m n / / configure the associated VLAN

[sw-mstp-region] active region-configuration

[sw-mstp-region] display this

Configure MSTI

[sw1] stp instance {id} priority {value}

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report