quidway s2300 configuration guide - ethernet(v100r003c00 03)[1]

235
Quidway S2300 Series Ethernet Switches V100R003C00 Configuration Guide - Ethernet Issue 03 Date 2009-11-25 Huawei Proprietary and Confidential Copyright © Huawei Technologies Co., Ltd.

Upload: francisco-moraga

Post on 30-Oct-2014

1.601 views

Category:

Documents


13 download

TRANSCRIPT

Page 1: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Quidway S2300 Series Ethernet Switches

V100R003C00

Configuration Guide - Ethernet

Issue 03

Date 2009-11-25

Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Page 2: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Huawei Technologies Co., Ltd. provides customers with comprehensive technical support and service. For anyassistance, please contact our local office or company headquarters.

Huawei Technologies Co., Ltd.Address: Huawei Industrial Base

Bantian, LonggangShenzhen 518129People's Republic of China

Website: http://www.huawei.com

Email: [email protected]

Copyright © Huawei Technologies Co., Ltd. 2009. All rights reserved.No part of this document may be reproduced or transmitted in any form or by any means without prior writtenconsent of Huawei Technologies Co., Ltd. Trademarks and Permissions

and other Huawei trademarks are the property of Huawei Technologies Co., Ltd.All other trademarks and trade names mentioned in this document are the property of their respective holders. NoticeThe purchased products, services and features are stipulated by the contract made between Huawei and thecustomer. All or part of the products, services and features described in this document may not be within thepurchase scope or the usage scope. Unless otherwise specified in the contract, all statements, information,and recommendations in this document are provided "AS IS" without warranties, guarantees or representationsof any kind, either express or implied.

The information in this document is subject to change without notice. Every effort has been made in thepreparation of this document to ensure accuracy of the contents, but all statements, information, andrecommendations in this document do not constitute the warranty of any kind, express or implied.

Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Page 3: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Contents

About This Document.....................................................................................................................1

1 Ethernet Interface Configuration............................................................................................1-11.1 Introduction.....................................................................................................................................................1-3

1.1.1 Ethernet Interfaces..................................................................................................................................1-31.1.2 Interface Isolation...................................................................................................................................1-41.1.3 References..............................................................................................................................................1-51.1.4 Logical Relationships Between Configuration Tasks............................................................................1-5

1.2 Configuring Basic Attributes of Ethernet Interfaces.......................................................................................1-51.2.1 Establishing the Configuration Task......................................................................................................1-61.2.2 (Optional) Setting the Description of an Interface.................................................................................1-61.2.3 (Optional) Setting the Cable Type for an Interface................................................................................1-71.2.4 (Optional) Setting the Working Mode of an Interface...........................................................................1-71.2.5 (Optional) Setting the Rate of an Interface............................................................................................1-81.2.6 (Optional) Enabling Flow Control.........................................................................................................1-91.2.7 Checking the Configuration...................................................................................................................1-9

1.3 Configuring Advanced Attributes of Ethernet Interfaces..............................................................................1-101.3.1 Establishing the Configuration Task....................................................................................................1-101.3.2 Configuring Traffic Suppression..........................................................................................................1-111.3.3 (Optional) Enabling an Interface to Allow Jumbo Frames to Pass Through.......................................1-121.3.4 (Optional) Configuring an Interfaceto Process BPDUs.......................................................................1-121.3.5 (Optional) Configuring Security Protection on an Interface................................................................1-131.3.6 Checking the Configuration.................................................................................................................1-14

1.4 Configuring Auto-negotiation of Ethernet Interfaces...................................................................................1-141.4.1 Establishing the Configuration Task....................................................................................................1-151.4.2 (Optional) Enabling Auto-negotiation.................................................................................................1-151.4.3 (Optional) Enabling Auto-negotiation of Flow Control.......................................................................1-161.4.4 Checking the Configuration.................................................................................................................1-16

1.5 Configuring External Loopback Detection on Ethernet Interfaces...............................................................1-171.5.1 Establishing the Configuration Task....................................................................................................1-171.5.2 Enabling External Loopback Detection on Interfaces..........................................................................1-181.5.3 (Optional) Setting the Interval for External Loopback Detection on Interfaces..................................1-181.5.4 (Optional) Configuring External Loopback Detection Actions on Interfaces.....................................1-191.5.5 Checking the Configuration.................................................................................................................1-19

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet Contents

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

i

Page 4: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.6 Configuring the VCT Function of the S-switch............................................................................................1-191.6.1 Establishing the Configuration Task....................................................................................................1-201.6.2 Detecting the Status of a Connected Cable..........................................................................................1-20

1.7 Creating an Eth-Trunk...................................................................................................................................1-211.7.1 Establishing the Configuration Task....................................................................................................1-211.7.2 Creating an Eth-Trunk..........................................................................................................................1-221.7.3 Adding Member Interfaces to an Eth-Trunk........................................................................................1-221.7.4 (Optional) Setting the Load Balancing Mode for an Eth-Trunk..........................................................1-231.7.5 Checking the Configuration.................................................................................................................1-23

1.8 Deleting an Eth-Trunk...................................................................................................................................1-241.8.1 Establishing the Configuration Task....................................................................................................1-241.8.2 (Optional) Deleting a Member Interface from an Eth-Trunk...............................................................1-251.8.3 (Optional) Deleting an Eth-Trunk........................................................................................................1-251.8.4 Checking the Configuration.................................................................................................................1-26

1.9 Creating an Interface Group..........................................................................................................................1-261.9.1 Establishing the Configuration Task....................................................................................................1-261.9.2 Creating an Interface Group.................................................................................................................1-271.9.3 Adding Member Interfaces to an Interface Group...............................................................................1-271.9.4 Checking the Configuration.................................................................................................................1-28

1.10 Deleting an Interface Group........................................................................................................................1-281.10.1 Establishing the Configuration Task..................................................................................................1-281.10.2 (Optional) Deleting a Member Interface from an Interface Group....................................................1-291.10.3 (Optional) Deleting an Interface Group.............................................................................................1-291.10.4 Checking the Configuration...............................................................................................................1-30

1.11 Configuring Interface Isolation...................................................................................................................1-301.11.1 Establishing the Configuration Task..................................................................................................1-311.11.2 Configuring Interface Isolation..........................................................................................................1-311.11.3 Checking the Configuration...............................................................................................................1-32

1.12 Maintaining Ethernet Interfaces..................................................................................................................1-321.13 Configuration Examples..............................................................................................................................1-33

1.13.1 Example for Setting Attributes of Ethernet Interfaces.......................................................................1-331.13.2 Example for Configuring Interface Isolation.....................................................................................1-35

2 LACP Configuration..................................................................................................................2-12.1 Introduction to Link Aggregation...................................................................................................................2-2

2.1.1 Link Aggregation Overview...................................................................................................................2-22.1.2 Link Aggregation Modes Supported by the S-switch............................................................................2-22.1.3 Related Concepts of LACP....................................................................................................................2-32.1.4 Logical Relationships Between Configuration Tasks............................................................................2-4

2.2 Configuring Link Aggregation in Manual Load Balancing Mode..................................................................2-42.2.1 Establishing the Configuration Task......................................................................................................2-42.2.2 Creating an Eth-Trunk............................................................................................................................2-52.2.3 (Optional) Configuring the Eth-Trunk to Work in Manual Load Balancing Mode...............................2-5

ContentsQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

ii Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 5: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

2.2.4 Adding a Member Interface to the Eth-Trunk........................................................................................2-62.2.5 (Optional) Setting the Load Balancing Mode........................................................................................2-62.2.6 Checking the Configuration...................................................................................................................2-7

2.3 Configuring Link Aggregation in Static LACP Mode....................................................................................2-82.3.1 Establishing the Configuration Task......................................................................................................2-82.3.2 Creating an Eth-Trunk............................................................................................................................2-92.3.3 Configuring the Eth-Trunk to Work in Static LACP Mode...................................................................2-92.3.4 Adding a Member Interface to the Eth-Trunk......................................................................................2-102.3.5 Configuring the S-switch to Process BPDUs.......................................................................................2-112.3.6 (Optional) Setting the LACP Priority of the System............................................................................2-112.3.7 (Optional) Setting the Upper Threshold for the Number of Active Interfaces....................................2-122.3.8 (Optional) Setting the Lower Threshold for the Number of Active Interfaces....................................2-122.3.9 (Optional) Setting the LACP Priority of the Interface.........................................................................2-132.3.10 (Optional) Enabling LACP Preemption and Setting the Delay for LACP Preemption.....................2-142.3.11 Checking the Configuration...............................................................................................................2-15

2.4 Maintaining LACP........................................................................................................................................2-162.4.1 Clearing the Statistics of Received and Sent LACPDUs.....................................................................2-162.4.2 Debugging LACP.................................................................................................................................2-162.4.3 Monitoring the Operation Status of the LAG.......................................................................................2-17

2.5 Configuration Examples................................................................................................................................2-172.5.1 Example for Configuring Link Aggregation in Manual Load Balancing Mode..................................2-172.5.2 Example for Configuring Link Aggregation in Static LACP Mode....................................................2-20

3 VLAN Configuration.................................................................................................................3-13.1 Introduction.....................................................................................................................................................3-2

3.1.1 VLAN.....................................................................................................................................................3-23.1.2 VLAN Classification..............................................................................................................................3-23.1.3 VLAN Features Supported by the S-switch...........................................................................................3-33.1.4 Logical Relationships Between Configuration Tasks............................................................................3-3

3.2 Configuring a VLAN......................................................................................................................................3-33.2.1 Establishing the Configuration Task......................................................................................................3-33.2.2 (Optional) Creating a VLAN..................................................................................................................3-43.2.3 (Optional) Creating VLANs in Batches.................................................................................................3-43.2.4 Checking the Configuration...................................................................................................................3-5

3.3 Adding Interfaces to a VLAN.........................................................................................................................3-53.3.1 Establishing the Configuration Task......................................................................................................3-63.3.2 Adding Access Interfaces to a VLAN....................................................................................................3-63.3.3 (Optional) Adding Trunk Interfaces to a VLAN....................................................................................3-83.3.4 (Optional) Adding Hybrid Interfaces to a VLAN..................................................................................3-83.3.5 (Optional) Adding QinQ Interfaces to a VLAN.....................................................................................3-93.3.6 (Optional) Adding Interfaces to VLANs in Batches............................................................................3-103.3.7 Checking the Configuration.................................................................................................................3-12

3.4 Configuring VLANIF Interfaces...................................................................................................................3-12

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet Contents

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

iii

Page 6: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

3.4.1 Establishing the Configuration Task....................................................................................................3-133.4.2 Creating a VLANIF Interface...............................................................................................................3-133.4.3 Assigning IP Addresses to VLANIF Interfaces...................................................................................3-143.4.4 (Optional) Setting the MTU of a VLANIF Interface...........................................................................3-143.4.5 Checking the Configuration.................................................................................................................3-15

3.5 Configuring MAC Address-Based VLANs..................................................................................................3-153.5.1 Establishing the Configuration Task....................................................................................................3-153.5.2 Relating a MAC Address with a VLAN..............................................................................................3-163.5.3 Allowing Packets of the MAC Address-based VLAN to Pass Through the Interface.........................3-163.5.4 Enabling MAC Address-Based VLAN Classification.........................................................................3-173.5.5 (Optional) Setting the Precedence for VLAN Matching......................................................................3-173.5.6 Checking the Configuration.................................................................................................................3-18

3.6 Configuring a Management VLAN...............................................................................................................3-183.6.1 Establishing the Configuration Task....................................................................................................3-193.6.2 Configuring a Management VLAN......................................................................................................3-193.6.3 Checking the Configuration.................................................................................................................3-19

3.7 Configuration Examples................................................................................................................................3-203.7.1 Example for Configuring Trunk Links on the S-switch.......................................................................3-203.7.2 Example for Configuring VLAN Integration.......................................................................................3-22

4 VLAN Aggregation Configuration.........................................................................................4-14.1 Introduction.....................................................................................................................................................4-2

4.1.1 Concept of VLAN Aggregation.............................................................................................................4-24.1.2 VLAN Aggregation Supported by the S-switch.................................................................................... 4-24.1.3 Logical Relationships Between Configuration Tasks............................................................................4-3

4.2 Configuring VLAN Aggregation....................................................................................................................4-34.2.1 Establishing the Configuration Task......................................................................................................4-34.2.2 Configuring Sub VLANs....................................................................................................................... 4-34.2.3 Configuring a Super VLAN...................................................................................................................4-44.2.4 Assigning IP Addresses to VLANIF Interfaces.....................................................................................4-54.2.5 Enabling ARP Proxy in the Super-VLAN............................................................................................. 4-54.2.6 Checking the Configuration...................................................................................................................4-6

4.3 Configuration Examples..................................................................................................................................4-74.3.1 Example for Configuring VLAN Aggregation...................................................................................... 4-7

5 VLAN Mapping Configuration...............................................................................................5-15.1 Introduction to VLAN Mapping..................................................................................................................... 5-2

5.1.1 VLAN Mapping Overview.....................................................................................................................5-25.1.2 VLAN Mapping Features Supported by the S-switch........................................................................... 5-3

5.2 Configuring VLAN Mapping..........................................................................................................................5-45.2.1 Establishing the Configuration Task......................................................................................................5-45.2.2 Creating an S-VLAN and a C-VLAN....................................................................................................5-55.2.3 Configuring the Type of an Interface Type as Hybrid...........................................................................5-55.2.4 Adding Interfaces to an S-VLAN...........................................................................................................5-6

ContentsQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

iv Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 7: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

5.2.5 Enabling Selective QinQ on an Interface...............................................................................................5-65.2.6 (Optional) Configuring an Interface to Trust the 802.1p Priorities Carried in Packets.........................5-75.2.7 Configuring VLAN Mapping.................................................................................................................5-75.2.8 Checking the Configuration...................................................................................................................5-8

5.3 Configuration Examples..................................................................................................................................5-95.3.1 Example for Configuring VLAN Mapping............................................................................................5-9

6 Voice VLAN Configuration.....................................................................................................6-16.1 Introduction.....................................................................................................................................................6-2

6.1.1 Identification of Voice Flows.................................................................................................................6-26.1.2 Voice VLAN Features Supported by the S-switch................................................................................6-36.1.3 Logical Relationships Between Configuration Tasks............................................................................6-4

6.2 Configuring Voice VLANs of the Automatic Mode.......................................................................................6-46.2.1 Establishing the Configuration Task......................................................................................................6-46.2.2 (Optional) Configuring Other Identifiable OUIs for the Voice VLAN.................................................6-56.2.3 (Optional) Setting the Aging Time of a Voice VLAN...........................................................................6-56.2.4 Enabling the Voice VLAN Function on an Interface.............................................................................6-66.2.5 (Optional) Configuring the Device to Work in the Security Mode........................................................6-66.2.6 Configuring a Voice VLAN to Work in Automatic Mode....................................................................6-76.2.7 Checking the Configuration...................................................................................................................6-7

6.3 Configuring Voice VLANs of the Manual Mode...........................................................................................6-86.3.1 Establishing the Configuration Task......................................................................................................6-86.3.2 (Optional) Configuring Other Identifiable OUIs for the Voice VLAN.................................................6-96.3.3 Enabling the Voice VLAN Function on an Interface.............................................................................6-96.3.4 (Optional) Configuring the Device to Work in the Security Mode......................................................6-106.3.5 Configuring a Voice VLAN to Work in Manual Mode.......................................................................6-106.3.6 Adding Interfaces to the Voice VLAN.................................................................................................6-116.3.7 Checking the Configuration.................................................................................................................6-11

6.4 Configuring an Interface to Interwork with Non-Huawei Voice Devices....................................................6-126.4.1 Enabling an Interface to Interwork with Non-Huawei Voice Devices................................................6-12

6.5 Configuration Examples................................................................................................................................6-136.5.1 Example for Configuring the Voice VLAN of the Automatic Mode...................................................6-136.5.2 Example for Configuring the Voice VLAN of the Manual Mode.......................................................6-15

7 QinQ Configuration..................................................................................................................7-17.1 Introduction.....................................................................................................................................................7-2

7.1.1 QinQ.......................................................................................................................................................7-27.1.2 References..............................................................................................................................................7-27.1.3 Logical Relationships Between Configuration Tasks............................................................................7-2

7.2 Configure QinQ Interfaces..............................................................................................................................7-27.2.1 Establishing the Configuration Task......................................................................................................7-27.2.2 Setting the Interface Type......................................................................................................................7-37.2.3 (Optional) Setting the TPID Etype Value in the Outer VLAN Tag.......................................................7-47.2.4 Setting the VLAN ID of the Outer VLAN Tag......................................................................................7-4

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet Contents

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

v

Page 8: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

7.2.5 Checking the Configuration...................................................................................................................7-57.3 Configuration Examples..................................................................................................................................7-5

7.3.1 Example for Configuring QinQ..............................................................................................................7-57.3.2 Example for Setting the TPID Etype Value in the Outer VLAN Tags..................................................7-8

8 MAC Table Configuration.......................................................................................................8-18.1 Introduction.....................................................................................................................................................8-2

8.1.1 MAC Table.............................................................................................................................................8-28.1.2 Capacity of a MAC Table and Limit to the Number of MAC Entries Learned by an Interface............8-28.1.3 References..............................................................................................................................................8-28.1.4 Logical Relationships Between Configuration Tasks............................................................................8-3

8.2 Configuring the MAC Table...........................................................................................................................8-38.2.1 Establishing the Configuration Task......................................................................................................8-38.2.2 (Optional) Configuring Static MAC Address Entries............................................................................8-38.2.3 (Optional) Configuring Blackhole MAC Address Entries.....................................................................8-48.2.4 (Optional) Setting the Aging Time of Dynamic MAC Entries..............................................................8-58.2.5 Checking the Configuration...................................................................................................................8-6

8.3 Restricting MAC Address Learning................................................................................................................8-68.3.1 Establishing the Configuration Task......................................................................................................8-78.3.2 Enabling Restriction of MAC Address Learning...................................................................................8-78.3.3 (Optional) Configuring the Limit to the Amount of MAC Entries Learned by an Interface.................8-88.3.4 Checking the Configuration...................................................................................................................8-8

8.4 Configuring the S-switch to Discard Packets with Illegal MAC Addresses...................................................8-88.4.1 Establishing the Configuration Task......................................................................................................8-98.4.2 Dropping Packets with Specified Illegal MAC Addresses.................................................................... 8-98.4.3 Clearing Alarms for the Dropping of Packets with Illegal MAC Addresses.........................................8-98.4.4 Checking the Configuration.................................................................................................................8-10

8.5 Configuration Examples................................................................................................................................8-108.5.1 Example for Configuring the MAC Table...........................................................................................8-108.5.2 Example for Configuring the Limit to the Number of MAC Entries Learned by an Interface............8-12

9 MSTP Configuration.................................................................................................................9-19.1 Introduction.....................................................................................................................................................9-2

9.1.1 STP, RSTP, and MSTP..........................................................................................................................9-29.1.2 References..............................................................................................................................................9-2

9.2 Enabling Basic Functions of MSTP on the S-switch......................................................................................9-29.2.1 Establishing the Configuration Task......................................................................................................9-39.2.2 (Optional) Enabling S-switch to Process BPDUs..................................................................................9-39.2.3 Enabling MSTP......................................................................................................................................9-39.2.4 Checking the Configuration...................................................................................................................9-4

9.3 Adding an S-switch to a Specified MST Region............................................................................................ 9-49.3.1 Establishing the Configuration Task......................................................................................................9-49.3.2 Setting the MSTP Mode of the S-switch................................................................................................9-59.3.3 Setting the MST Region.........................................................................................................................9-6

ContentsQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

vi Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 9: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

9.3.4 Activating the Configuration of an MST Region...................................................................................9-69.3.5 (Optional) Setting the S-switch as the Root Switch or Secondary Root Switch....................................9-79.3.6 (Optional) Setting the Priority of the S-switch in a Specified MSTI.....................................................9-89.3.7 Checking the Configuration...................................................................................................................9-9

9.4 Configuring MSTP Parameters of the S-switch..............................................................................................9-99.4.1 Establishing the Configuration Task......................................................................................................9-99.4.2 (Optional) Configuring MSTP Network Parameters of the S-switch..................................................9-109.4.3 (Optional) Configuring MSTP Parameters of an Interface..................................................................9-119.4.4 (Optional) Switching an Interface to the MSTP Mode........................................................................9-13

9.5 Configuring MSTP Protection on the S-switch.............................................................................................9-149.5.1 Establishing the Configuration Task....................................................................................................9-149.5.2 (Optional) Configuring BPDU Protection on the S-switch..................................................................9-159.5.3 (Optional) Configuring Root Protection on an Interface......................................................................9-159.5.4 (Optional) Configuring Loop Protection on an Interface.....................................................................9-169.5.5 Checking the Configuration.................................................................................................................9-17

9.6 Maintaining MSTP........................................................................................................................................9-179.6.1 Displaying MSTP Running Information..............................................................................................9-189.6.2 Clearing MSTP Statistics.....................................................................................................................9-189.6.3 Debugging MSTP.................................................................................................................................9-18

9.7 Configuration Examples................................................................................................................................9-199.7.1 Example for Configuring MSTP..........................................................................................................9-19

10 BPDU Tunneling and Partitioned STP Configuration...................................................10-110.1 Introduction.................................................................................................................................................10-2

10.1.1 BPDU Tunneling................................................................................................................................10-210.1.2 Partitioned STP..................................................................................................................................10-210.1.3 Logic Relationships Between Configuration Tasks...........................................................................10-2

10.2 Configuring Interface-based Transparent Transmission of BPDUs from the Same Customer Network.............................................................................................................................................................................10-3

10.2.1 Establishing the Configuration Task..................................................................................................10-310.2.2 Enabling STP and Enabling the BPDU Function on CEs..................................................................10-410.2.3 Configuring the Provider Mode for UPEs..........................................................................................10-410.2.4 Enabling UPEs to Process BPDUs.....................................................................................................10-410.2.5 Checking the Configuration...............................................................................................................10-5

10.3 Configuring Interface-based Transparent Transmission of BPDUs from Different Customer Networks.............................................................................................................................................................................10-5

10.3.1 Establishing the Configuration Task..................................................................................................10-610.3.2 Enabling STP and Enabling the BPDU Function on CEs..................................................................10-610.3.3 Enabling UPEs to Process BPDUs.....................................................................................................10-710.3.4 Adding the UPE Interfaces to the Specified VLAN in Untagged Mode............................................10-710.3.5 (Optional) Replacing the MAC Address of BPDUs with a Multicast MAC Address on the UPEs.......................................................................................................................................................................10-810.3.6 Enabling BPDU Tunneling on the UPEs...........................................................................................10-810.3.7 Checking the Configuration...............................................................................................................10-9

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet Contents

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

vii

Page 10: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10.4 Configuring VLAN-based BPDU Tunneling..............................................................................................10-910.4.1 Establishing the Configuration Task................................................................................................10-1010.4.2 Enabling STP and Enabling the BPDU Function on CEs................................................................10-1010.4.3 Enabling UPEs to Process BPDUs...................................................................................................10-1110.4.4 Setting VLAN ID of the BPDUs that CE Interfaces Allow to Pass Trough....................................10-1110.4.5 Tagging BPDUs on the CEs.............................................................................................................10-1210.4.6 (Optional) Replacing the MAC Address of BPDUs with a Multicast MAC Address on the UPEs.....................................................................................................................................................................10-1210.4.7 Configuring Tagged BPDUs to Pass Through the BPDU Tunnel on UPEs....................................10-1310.4.8 Checking the Configuration.............................................................................................................10-13

10.5 Configuring Partitioned STP.....................................................................................................................10-1410.5.1 Establishing the Configuration Task................................................................................................10-1510.5.2 Enabling STP and Enabling the BPDU Function.............................................................................10-1610.5.3 Enabling Interfaces Connected to the MAN to Tag BPDUs............................................................10-1610.5.4 Setting VLAN IDs of the BPDUs That the Interface at the Network Side Allows to Pass Through.....................................................................................................................................................................10-1710.5.5 Configuring the S-switch to Accept Tagged BPDUs.......................................................................10-1710.5.6 Configuring BPDU Tunneling.........................................................................................................10-1810.5.7 Enabling STP Snooping...................................................................................................................10-1910.5.8 Checking the Configuration.............................................................................................................10-19

10.6 Maintaining...............................................................................................................................................10-2010.6.1 Setting the Bandwidth Consumed by BPDUs Sent to the Queues on the CPU...............................10-2010.6.2 Clearing Statistics about Discarded BPDUs....................................................................................10-2110.6.3 Checking Statistics About Discarded BPDUs..................................................................................10-21

10.7 Configuration Examples............................................................................................................................10-2110.7.1 Example for Configuring Interface-based BPDU Tunneling of the Same Customer......................10-2210.7.2 Example for Configuring Interface-based BPDU Tunnel of Different Customer...........................10-2410.7.3 Example for Configuring VLAN-based BPDU Tunneling..............................................................10-2910.7.4 Example for Configuring Partitioned STP.......................................................................................10-33

ContentsQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

viii Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 11: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Figures

Figure 1-1 Networking for applying unidirectional interface isolation................................................................1-4Figure 1-2 Networking for applying bidirectional interface isolation..................................................................1-5Figure 1-3 Networking for setting attributes of Ethernet interfaces...................................................................1-33Figure 1-4 Networking for configuring interface isolation................................................................................1-36Figure 2-1 Determining the active links by the Actor in static LACP mode.......................................................2-3Figure 2-2 Networking diagram of link aggregation in manual load balancing mode........................................ 2-4Figure 2-3 Networking diagram of link aggregation in static LACP mode.........................................................2-8Figure 2-4 Networking diagram of link aggregation in manual load balancing mode......................................2-18Figure 2-5 Networking diagram of link aggregation in static LACP mode.......................................................2-20Figure 3-1 Networking of adding interfaces to a VLAN...................................................................................3-11Figure 3-2 Networking diagram for configuring trunk links on the S-switch....................................................3-21Figure 3-3 Networking diagram for configuring VLAN integration.................................................................3-23Figure 4-1 Networking diagram for configuring VLAN aggregation..................................................................4-7Figure 5-1 Networking diagram of VLAN mapping............................................................................................5-3Figure 5-2 Networking for configuring VLAN mapping.....................................................................................5-9Figure 6-1 Configuring voice VLANs of the automatic mode...........................................................................6-13Figure 6-2 Configuring voice VLANs of the manual mode...............................................................................6-15Figure 7-1 Networking diagram for configuring QinQ ports...............................................................................7-6Figure 7-2 Networking diagram of configuring the compatibility of the TPID Etype value in the outer VLAN tags...............................................................................................................................................................................7-8Figure 8-1 Configuring the limit to the number of MAC entries learned by an interface on an interface.........8-12Figure 9-1 Networking diagram for configuring basic MSTP functions...........................................................9-20Figure 10-1 Networking of partitioned STP.....................................................................................................10-15Figure 10-2 Networking for configuring interface-based transparent transmission of BPDUs from the samecustomer network..............................................................................................................................................10-22Figure 10-3 Networking for configuring interface-based transparent transmission of BPDUs from differentcustomer networks.............................................................................................................................................10-25Figure 10-4 Networking for configuring VLAN-based BPDU tunneling........................................................10-29Figure 10-5 Networking for configuring partitioned STP................................................................................10-34

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet Figures

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

ix

Page 12: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]
Page 13: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Tables

Table 1-1 Rules for numbering FE and GE interfaces......................................................................................... 1-3Table 1-2 Attributes of FE interfaces...................................................................................................................1-4Table 1-3 Attributes of GE interfaces...................................................................................................................1-4Table 6-1 Default OUI addresses......................................................................................................................... 6-2Table 6-2 Packet processing methods in various voice VLAN modes................................................................ 6-3

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet Tables

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

xi

Page 14: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]
Page 15: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

About This Document

PurposeThis document describes the Ethernet feature that is supported by the S-switch. The Ethernetfeature is described by providing configuration procedures and configuration examples.

This document covers the following topics:l Feature description

l Data preparation

l Pre-configuration tasks

l Configuration procedures

l Checking the configuration

l Configuration examples

This document guides you through the configuration and the applicable environment of theEthernet feature of the S-switch.

This document is not applicable to S2352EI product.

Related VersionsThe following table lists the product versions related to this document.

Product Name Version

S2300 V100R003C00

Intended AudienceThis document is intended for:

l Commissioning engineers

l Data configuration engineers

l Network administrators

l System maintenance engineers

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet About This Document

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1

Page 16: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

OrganizationThis document is organized as follows.

Chapter Description

1 Ethernet InterfaceConfiguration

Describes the basics, methods, and examples forconfiguring the Ethernet interface.

2 LACP Configuration Describes the basics, methods, and examples forconfiguring the Link Aggregation.

3 VLAN Configuration Describes the basics, methods, and examples forconfiguring the Virtual Local Area Network (VLAN).

4 VLAN AggregationConfiguration

Describes the basics, methods, and examples forconfiguring the VLAN Aggregation.

5 VLAN MappingConfiguration

Describes the basics, methods, and examples forconfiguring the VLAN Mapping.

6 Voice VLAN Configuration Describes the basics, methods, and examples forconfiguring the Voice VLAN.

7 QinQ Configuration Describes the basics, methods, and examples forconfiguring QinQ.

8 MAC Table Configuration Describes the basics, methods, and examples forconfiguring the MAC table.

9 MSTP Configuration Describes the basics, methods, and examples forconfiguring the Spanning Tree Protocol (STP), RapidSpanning Tree Protocol (RSTP), and Multiple SpanningTree Protocol (MSTP).

10 BPDU Tunneling andPartitioned STPConfiguration

Describes the basics, methods, and examples forconfiguring the Bridge Protocol Data Unit (BPDU) tunneland partitioned STP.

Conventions

Symbol Conventions

The symbols that may be found in this document are defined as follows.

Symbol Description

DANGERIndicates a hazard with a high level of risk, which ifnot avoided, will result in death or serious injuries.

About This DocumentQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 17: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Symbol Description

WARNINGIndicates a hazard with a medium or low level of risk,which if not avoided, could result in minor ormoderate injuries.

CAUTIONIndicates a potentially hazardous situation, which ifnot avoided, could result in equipment damage, dataloss, performance degradation, or unexpectedresults.

NOTE Provides additional information to emphasize orsupplement important points of the main text.

TIP Indicates a tip that may help you solve a problem orsave your time.

General ConventionsConvention Description

Times New Roman Normal paragraphs are in Times New Roman.

Boldface Names of files, directories, folders, and users are in boldface.For example, Log in as user Root.

Italic Book titles are in Italics.

Courier New “Terminal display is in Courier New. Examples of informationdisplayed on the screen are in Courier New.

Command ConventionsConvention Description

Boldface The keywords of a command line are in boldface.

Italic Command arguments are in italic.

[ ] Items (keywords or arguments) in brackets [ ] are optional.

{ x | y | ... } Alternative items are grouped in braces and separated by verticalbars. One is selected.

[ x | y | ... ] Optional alternative items are grouped in square brackets andseparated by vertical bars. One or none is selected.

{ x | y | ... } * Optional items are grouped in braces and separated by verticalbars. A minimum of one item or a maximum of all items can beselected.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet About This Document

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3

Page 18: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Convention Description

[ x | y | ... ] * Optional alternative items are grouped in square brackets andseparated by vertical bars. Several or none is selected.

&<1-n> The parameter before the & sign can be repeated 1 to n times.

# A line starting with the # sign is comments.

GUI ConventionsConvention Description

Boldface Buttons, menus, parameters, tabs, window, and dialog titles arein boldface. For example, click OK.

>

Multi-level menus are in boldface and separated by the ">" signs.For example, choose File > Create > Folder.

Keyboard OperationsFormat Description

Key Press the key. For example, press Enter and press Tab.

Key 1+Key 2 Press the keys concurrently. For example, pressing Ctrl+Alt+A means the three keys should be pressed concurrently.

Key 1, Key 2 Press the keys in turn. For example, pressing Alt, A means thetwo keys should be pressed in turn.

Mouse OperationAction Description

Click Select and release the primary mouse button without moving thepointer.

Double-click Press the primary mouse button twice continuously and quicklywithout moving the pointer.

Drag Press and hold the primary mouse button and move the pointerto a certain position.

About This DocumentQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 19: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Update HistoryUpdates between document issues are cumulative. Therefore, the latest document versioncontains all updates made to previous versions.

Updates in Issue 03 (2009-11-25)Third commercial release. The document is updated as follows:

l Fixing bug

l Rewriting copyright statement

l Updating manual version

Updates in Issue 02 (2009-08-14)Second commercial release. The document is updated as follows:

l Fixing bug

l Rewriting copyright statement

l Updating manual version

Updates in Issue 01 (2009-06-30)This is the first release.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet About This Document

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

5

Page 20: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]
Page 21: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1 Ethernet Interface Configuration

About This Chapter

This chapter describes the basics, configuration methods, and configuration examples ofEthernet interfaces.

1.1 IntroductionThis section describes Ethernet interfaces and the interface isolation function supported by theS-switch.

1.2 Configuring Basic Attributes of Ethernet InterfacesThis section describes how to configure the description, cable type, working mode, and rate ofEthernet interfaces.

1.3 Configuring Advanced Attributes of Ethernet InterfacesThis section describes how to configure traffic suppression on Ethernet interfaces and how toconfigure Ethernet interfaces to allow jumbo frames to pass through, to discard incoming taggedframes, and to process Bridge Protocol Data Units (BPDUs).

1.4 Configuring Auto-negotiation of Ethernet InterfacesThis section describes how to configure auto-negotiation and auto-negotiation of flow controlof Ethernet interfaces.

1.5 Configuring External Loopback Detection on Ethernet InterfacesThis section describes how to configure external loopback detection on Ethernet interfaces.

1.6 Configuring the VCT Function of the S-switchThis section describes how to configure the VCT function of the S-switch.

1.7 Creating an Eth-TrunkThis section describes how to create an Eth-Trunk.

1.8 Deleting an Eth-TrunkDeleting an Eth-Trunk

1.9 Creating an Interface GroupThis section describes how to create an interface group.

1.10 Deleting an Interface GroupDeleting an Interface Group

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-1

Page 22: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.11 Configuring Interface IsolationThis section describes how to configure interface isolation.

1.12 Maintaining Ethernet InterfacesThis section describes how to maintain Ethernet interfaces.

1.13 Configuration ExamplesThis section provides several examples for configuring Ethernet interfaces.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 23: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.1 IntroductionThis section describes Ethernet interfaces and the interface isolation function supported by theS-switch.

1.1.1 Ethernet Interfaces

1.1.2 Interface Isolation

1.1.3 References

1.1.4 Logical Relationships Between Configuration Tasks

1.1.1 Ethernet Interfaces

The S-switch supports the following Ethernet interfaces:

l Fast Ethernet (FE) interfaces

l Gigabit Ethernet (GE) interfaces

The rules for numbering FE and GE interfaces are as follows:

The interfaces of the S-switch are numbered in the rule of slot number/sub-card number/interfacesequence number.

l Slot number: indicates the number of the slot where the LPU is located. The value is 0.

l Sub-card number: indicates the number of a sub-card. The value is 0.

l Interface sequence number: indicates the sequence numbers of the interfaces that arelocated on S-switch.

Table 1-1 Rules for numbering FE and GE interfaces

Figure ShowingInterfaceNumbering

Description

1

4

3

6

5

......

...

2The S-switch has two rows of service interfaces with the lower-leftinterface numbered 1. The other interfaces are numbered inascending order from bottom to up, and then from left to right.For example, the upper-left interface numbered 0/0/2.

FE Interfaces

FE interfaces can be either FE electrical interfaces or FE optical interfaces.

Table 1-2 shows the attributes of FE electrical interfaces and FE optical interfaces.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-3

Page 24: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Table 1-2 Attributes of FE interfaces

Interface Type Rate(Mbit/s)

Full-Duplex

Half-Duplex

Auto-negotiation Mode

Non-AutomaticNegotiation Mode

FE electrical interface 10/100 √ √ √ √

FE optical interface 100 √ × × √

GE InterfacesTable 1-3 shows the attributes of GE interfaces.

Table 1-3 Attributes of GE interfaces

Interface Type Rate(Mbit/s)

Full-Duplex

Half-Duplex

Auto-negotiation Mode

Non-AutomaticNegotiation Mode

GE optical interface 1000 √ × √ √

1.1.2 Interface Isolation

The S-switch supports interface isolation, which implements Layer 2 isolation betweeninterfaces. Interface isolation is supported by the following interfaces on the S-switch:l FE interfaces

l GE interfaces

l Eth-Trunks

NOTE

Interface isolation cannot be configured on member interfaces of an Eth-Trunk.

Unidirectional IsolationAs shown in Figure 1-1, if interface isolation is configured on Interface A, Interface A cannotsend packets to Interface B; Interface B, however, can send packets to Interface A.

Figure 1-1 Networking for applying unidirectional interface isolation

A B

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 25: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Bidirectional IsolationAs shown in Figure 1-2, if interface isolation is configured on Interface A and Interface B,Interface A and Interface B cannot exchange packets. This implements bidirectional isolationbetween Interface A and Interface B.

Figure 1-2 Networking for applying bidirectional interface isolation

A B

Rules for Configuring Interface IsolationOn the S-switch, interface isolation can be configured on any two interfaces that support thisfunction.

1.1.3 ReferencesFor details on Ethernet interfaces, refer to the Quidway S2300 Series Ethernet Switches FeatureDescription.

1.1.4 Logical Relationships Between Configuration Tasks

1.2 Configuring Basic Attributes of Ethernet Interfaces is a prerequisite to advancedconfigurations.

1.2 Configuring Basic Attributes of Ethernet InterfacesThis section describes how to configure the description, cable type, working mode, and rate ofEthernet interfaces.

1.2.2 (Optional) Setting the Description of an Interface to 1.2.6 (Optional) Enabling FlowControl are optional and are not listed in sequence.

1.2.1 Establishing the Configuration Task

1.2.2 (Optional) Setting the Description of an Interface

1.2.3 (Optional) Setting the Cable Type for an Interface

1.2.4 (Optional) Setting the Working Mode of an Interface

1.2.5 (Optional) Setting the Rate of an Interface

1.2.6 (Optional) Enabling Flow Control

1.2.7 Checking the Configuration

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-5

Page 26: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.2.1 Establishing the Configuration Task

Applicable Environment

The configuration task is applicable to the following:

l To identify an interface, set the description of the interface.

l By default, an FE electrical interface automatically identifies the type of the cable connectedto it. When the FE electrical interface fails to identify the cable type, you can set the cabletype for the interface.

l By default, an FE electrical interface and the directly connected device automaticallynegotiate and determine their common working mode and rate. If the peer device does notsupport auto-negotiation, you can set the working mode and rate of the FE electricalinterface the same as those of the peer device.

l If the traffic received by an Ethernet interface on the S-switch exceeds its processingcapability, and the interface directly connected to the local interface also supports flowcontrol, you can enable flow control on the local interface. After flow control is enabled,the interface sends a special data frame called the Pause frame to the peer interface to notifythe peer interface to stop sending traffic, if the received traffic reaches the set threshold. Ifthe peer interface also supports flow control, it reduces the rate of sending frames so thatthe local interface can process received frames properly.

Pre-configuration Tasks

None.

Data Preparation

To set basic attributes of Ethernet interfaces, you need the following data.

No. Data

1 Number of an Ethernet interface

2 (Optional) Description of the Ethernet interface

3 (Optional) Cable type for the FE electrical interface

4 (Optional) Duplex mode of the FE electrical interface

5 (Optional) Rate of the FE electrical interface

1.2.2 (Optional) Setting the Description of an Interface

Context

Do as follows on the S-switch where the description needs to be set for an Ethernet interface.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 27: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

ProcedureStep 1 Run:

system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Step 3 Run:description description

The description of the interface is set.

By default, the description of an interface shows the type and number of the interface. Forexample, the description of GigabitEthernet 0/0/1 is "HUAWEI, Quidway Series, Ethernet0/0/1interface."

----End

1.2.3 (Optional) Setting the Cable Type for an Interface

ContextDo as follows on the S-switch where the cable type needs to be set for an Ethernet interface.

ProcedureStep 1 Run:

system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view is displayed.

Step 3 Run:mdi { across | auto | normal }

The cable type is set for the FE electrical interface.

By default, an FE electrical interface automatically identifies the type of the cable connected toit.

----End

1.2.4 (Optional) Setting the Working Mode of an Interface

ContextDo as follows on the S-switch where the working mode needs to be set for an Ethernet electricalinterface.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-7

Page 28: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface ethernet interface-number

The Ethernet interface view is displayed.

Step 3 Run:undo negotiation auto

The FE electrical interface is configured to work in non-automatic negotiation mode.

Step 4 Run:duplex { full | half }

The working mode of the FE electrical interface is set.

By default, the working mode of an FE electrical interface is full-duplex when it runs in non-automatic negotiation mode.

----End

1.2.5 (Optional) Setting the Rate of an Interface

Context

Do as follows on the S-switch where the working mode needs to be set for an Ethernet electricalinterface.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view is displayed.

Step 3 Run:undo negotiation auto

The FE electrical interface is configured to work in non-automatic negotiation mode.

Step 4 Run:speed { 10 | 100 }

The rate of the FE electrical interface is set.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 29: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

By default, the rate of an FE electrical interface is 100 Mbit/s when it works in non-automaticnegotiation mode.

----End

1.2.6 (Optional) Enabling Flow Control

ContextDo as follows on the S-switch and the peer S-switch that need flow control on Ethernet interfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Step 3 Run:flow-control

Flow control is enabled on the EthernetGE interface.

By default, flow control is disabled on an EthernetGE interface.

----End

1.2.7 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check the basicconfiguration of anEthernet interface.

display interface [ interface-type [ interface-number ] ][ verbose ] [ | { begin | exclude | include } regular-expression ]

Check the cable typeand flow control statusof an Ethernet interface.

display current-configuration interface interface-type interface-number

After the configurations succeed, the following results can be obtained with the precedingcommand:

l The basic configurations, including the description, working mode, and rate of the Ethernetinterface are correctly set.

l The cable type of the Ethernet interface is correctly set.

l Flow control is enabled or disabled as configured.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-9

Page 30: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.3 Configuring Advanced Attributes of Ethernet InterfacesThis section describes how to configure traffic suppression on Ethernet interfaces and how toconfigure Ethernet interfaces to allow jumbo frames to pass through, to discard incoming taggedframes, and to process Bridge Protocol Data Units (BPDUs).

1.3.1 Establishing the Configuration Task

1.3.2 Configuring Traffic Suppression

1.3.3 (Optional) Enabling an Interface to Allow Jumbo Frames to Pass Through

1.3.4 (Optional) Configuring an Interfaceto Process BPDUs

1.3.5 (Optional) Configuring Security Protection on an Interface

1.3.6 Checking the Configuration

1.3.1 Establishing the Configuration Task

Applicable Environment

The configuration task is applicable to the following:

l The S-switch supports the suppression of the broadcast packets, multicast packets, andunknown unicast packets received by Ethernet interfaces. When the number of broadcastpackets, multicast packets, or unknown unicast packets exceeds the set threshold, thesystem discards the excessive packets. This reduces the traffic to an allowable range andensures normal transmission of network services.

l When there are jumbo frames on the network and the frames need to pass through anEthernet interface, you need to enable the Ethernet interface to allow jumbo frames to passthrough.

NOTE

S2300SI does not allow jumbo frames to pass through any interfaces.

l In normal situations, when an interface is not allowed to receive tagged frames, for example,the interface directly connects a user host, you can configure the interface to discardincoming tagged frames. This protects the system against hackers that use forged tags.

l When an interface needs to run the Multiple Spanning Tree Protocol (MSTP) or HuaweiGroup Management Protocol (HGMP), you need to enable the interface to process BPDUs.Otherwise, the interface discards all BPDUs it receives.

Pre-configuration Tasks

None.

Data Preparation

To set advanced attributes of Ethernet interfaces, you need the following data.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-10 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 31: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

No. Data

1 Number of an Ethernet interface

2 (Optional) Maximum percentage of broadcast traffic, multicast traffic, and unknownunicast traffic that an Ethernet interface allows to pass through

3 (Optional) Type and number of the interface where the incoming tagged frames needto be discarded

4 (Optional) Type and number of the interface where BPDUs need to be processed

1.3.2 Configuring Traffic Suppression

ContextDo as follows on the S-switch where the description needs to be set for an Ethernet interface.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view displayed.

Step 3 Run:broadcast-suppression broadcast-pct

The maximum percentage of broadcast traffic that the Ethernet interface allows to pass throughis set.

Step 4 Run:multicast-suppression multicast-pct

The maximum percentage of multicast traffic that the Ethernet interface allows to pass throughis set.

Step 5 Run:unicast-suppression unicast-pct

The maximum percentage of unknown unicast traffic that the Ethernet interface allows to passthrough is set.

By default, the maximum percentage of broadcast traffic, multicast traffic, and unknown unicasttraffic that an Ethernet interface allows to pass through is 100% respectively. That is, thebroadcast traffic, unknown multicast traffic, and unknown unicast traffic are not suppressed onan Ethernet interface.

----End

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-11

Page 32: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.3.3 (Optional) Enabling an Interface to Allow Jumbo Frames toPass Through

ContextDo as follows on the S-switch where you need to enable an Ethernet interface to allow jumboframes to pass through.

NOTE

S2300SI does not allow jumbo frames to pass through any interfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Step 3 Run:jumboframe enable

The Ethernet interface is enabled to allow jumbo frames to pass through.

By default, an Ethernet interface does not allow jumbo frames to pass through.

----End

1.3.4 (Optional) Configuring an Interfaceto Process BPDUs

ContextDo as follows on the S-switch where you need to configure the S-switch to process BPDUs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu enable

The S-switch is configured to process BPDUs.

By default, the S-switch does not process BPDUs.

----End

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-12 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 33: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.3.5 (Optional) Configuring Security Protection on an Interface

ContextDo as follows on the S-switch on which security protection on interfaces should be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:mac-address restrict

The restriction on MAC address learning is enabled globally on the S-switch.

Step 3 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Step 4 Run:mac-table limit limit-number

The maximum number of dynamic MAC address entries that a specified interface can learn isspecified.

By default, the number of dynamic MAC address entries that an interface can learn is notrestricted.

NOTE

S2300SI does not support restricting MAC address learning on GigabitEthernet interfaces.

Step 5 Run:port-security enable

Security protection is enabled on an interface.

Step 6 Run:port-security mac-address sticky enable

Sticky MAC is enabled on an interface.

Step 7 (Optional) Run:port-security mac-address sticky mac-address vlan vlan-id

A sticky MAC address entry is manually added.

NOTE

You need to enable sticky MAC on an interface before using the port-security mac-address sticky mac-address vlan vlan-id command.

S2300SI does not support security protection or sticky MAC on an interface.

----End

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-13

Page 34: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.3.6 Checking the Configuration

ProcedureStep 1 Run the display current-configuration [ | { begin | exclude | include } regular-expression ]

command to check whether traffic suppression is enabled on an Ethernet interface.

Step 2 Run the display current-configuration interface interface-type interface-number command tocheck whether the following functions are configured on an Ethernet interface:l Allowing jumbo frames to pass through

l processing BPDUs

l security protection

Step 3 Run the display mac-address sticky [ interface-type interface-number ] command to checkinformation about the sticky MAC address entries.

----End

ExampleRun the display current-configuration command to check whether traffic suppression iscorrectly configured on an Ethernet interface. For example:

<Quidway> display current-configuration | include suppression broadcast-suppression 20 multicast-suppression 30 unknown-unicast-suppression 40

Run the display current-configuration interface gigabitethernet 0/0/1 command to checkwhether security protection is enabled on GagabitEthernet 0/0/1.

# interface GigabitEthernet0/0/1 mac-table limit 5 port-security enable port-security mac-address sticky enable#

Run the display mac-address sticky [ interface-type interface-number ] command to checkinformation about the sticky MAC address entries.

<Quidway> display mac-address sticky gigabitethernet 0/0/1MAC Address VLAN/VSI Port Type Lsp----------------------------------------------------------------------------0001-0001-04d4 10 GigabitEthernet0/0/1 sticky 0/-0001-0001-04d7 10 GigabitEthernet0/0/1 sticky 0/-0001-0001-04d8 10 GigabitEthernet0/0/1 sticky 0/-0001-0001-04d1 10 GigabitEthernet0/0/1 sticky 0/-0001-0001-04d2 10 GigabitEthernet0/0/1 sticky 0/-

Total matching items displayed = 5

1.4 Configuring Auto-negotiation of Ethernet InterfacesThis section describes how to configure auto-negotiation and auto-negotiation of flow controlof Ethernet interfaces.

You must perform 1.4.2 (Optional) Enabling Auto-negotiation before performing 1.4.3(Optional) Enabling Auto-negotiation of Flow Control.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-14 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 35: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.4.1 Establishing the Configuration Task

1.4.2 (Optional) Enabling Auto-negotiation

1.4.3 (Optional) Enabling Auto-negotiation of Flow Control

1.4.4 Checking the Configuration

1.4.1 Establishing the Configuration Task

Applicable Environmentl FE interfaces and GE interfaces on the S-switch support auto-negotiation. An FE interface

negotiates the duplex mode and rate with the peer interface. A GE interface and the peerinterface can negotiate and determine whether to enable flow control only after the flow-control negotiation command is used to enable auto-negotiation of flow control on bothsides.

l GE interfaces on the S-switch support auto-negotiation of flow control. Auto-negotiationof flow control allows an interface and the directly connected interface to negotiate anddetermine whether to enable flow control on both sides. This simplifies systemconfiguration and management.

Pre-configuration Tasks

None.

Data Preparation

To configure auto-negotiation of Ethernet interfaces, you need the following data.

No. Data

1 Number of an Ethernet interface

1.4.2 (Optional) Enabling Auto-negotiation

Context

Do as follows on the S-switch and the peer S-switch that need auto-negotiation on Ethernetinterfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-15

Page 36: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The GE interface view is displayed.

Step 3 Run:negotiation auto

The GE interface is configured to work in auto-negotiation mode.

By default, GE interfaces work in automatic negotiation mode.

NOTE

Optical interfaces on the 4xGE line card do not support auto negotiation.

----End

1.4.3 (Optional) Enabling Auto-negotiation of Flow Control

ContextDo as follows on the S-switch and the peer S-switch that need auto-negotiation of flow controlon Ethernet interfaces.

GE interfaces support auto-negotiation of flow control. This function, however, is not supportedby FE interfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The GE interface view is displayed.

Step 3 Run:flow-control negotiation

Auto-negotiation of flow control is enabled on the GE interface.

NOTE

By default, auto-negotiation of flow control is disabled on an Ethernet interface.

----End

1.4.4 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check auto-negotiation and auto-negotiation of flow control on anEthernet interface.

display current-configuration interface interface-typeinterface-number

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-16 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 37: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

After the configuration succeeds, run the preceding command. You can view that auto-negotiation and auto-negotiation of flow control are correctly configured on the Ethernetinterface.

1.5 Configuring External Loopback Detection on EthernetInterfaces

This section describes how to configure external loopback detection on Ethernet interfaces.

1.5.3 (Optional) Setting the Interval for External Loopback Detection on Interfaces to 1.5.4(Optional) Configuring External Loopback Detection Actions on Interfaces are optional.You must perform 1.5.2 Enabling External Loopback Detection on Interfaces beforeperforming 1.5.3 (Optional) Setting the Interval for External Loopback Detection onInterfaces and 1.5.4 (Optional) Configuring External Loopback Detection Actions onInterfaces.

1.5.1 Establishing the Configuration Task

1.5.2 Enabling External Loopback Detection on Interfaces

1.5.3 (Optional) Setting the Interval for External Loopback Detection on Interfaces

1.5.4 (Optional) Configuring External Loopback Detection Actions on Interfaces

1.5.5 Checking the Configuration

1.5.1 Establishing the Configuration Task

Applicable Environment

After external loopback detection is enabled on Ethernet interfaces, the device detects whetheran external loopback occurs on an interface at regular intervals. If an external loopback occurson an interface, the device disables, restricts, or blocks the interface.

NOTE

S2300SI does not support external loopback detection on Ethernet interfaces.

Pre-configuration Tasks

None.

Data Preparation

To configure external loopback detection on Ethernet interfaces, you need the following data.

No. Data

1 Number of an Ethernet interface

2 Interval for external loopback detection

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-17

Page 38: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.5.2 Enabling External Loopback Detection on Interfaces

Context

Do as follows on the S-switch where external loopback detection needs to be enabled oninterfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:loopback-detect enable

External loopback detection is enabled on the interface.

NOTE

You can run the loopback-detect enable command in the system view to enable external loopbackdetection for all interfaces.

----End

1.5.3 (Optional) Setting the Interval for External LoopbackDetection on Interfaces

Context

Do as follows on the S-switch where external loopback detection needs to be enabled oninterfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:loopback-detect interval time

The interval for external loopback detection is set on interfaces.

----End

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-18 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 39: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.5.4 (Optional) Configuring External Loopback Detection Actionson Interfaces

ContextDo as follows on the S-switch where external loopback detection needs to be enabled oninterfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view is displayed.

Step 3 Run:loopback-detect action { block | trap | shutdown }

The action performed on the interface when an external loop occurs is configured.

----End

1.5.5 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check external loopbackdetection on an Ethernetinterface.

display current-configuration interface interface-typeinterface-number

After the configuration succeeds, run the preceding command. You can view that externalloopback detection is correctly configured on the Ethernet interface.

[Quidway] interface GigabitEthernet0/0/5[Quidway-GigabitEthernet0/0/5] display current-configuration interface GigabitEthernet0/0/5#interface GigabitEthernet0/0/5 loopback-detect enable loopback-detect action shutdown#return

1.6 Configuring the VCT Function of the S-switchThis section describes how to configure the VCT function of the S-switch.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-19

Page 40: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.6.1 Establishing the Configuration Task

1.6.2 Detecting the Status of a Connected Cable

1.6.1 Establishing the Configuration Task

Applicable Environment

After establishing the configuration task, you can enable the VCT function of the S-switch. Withthis function, you can detect the fault status of a cable and the length of the faulty cable segment.

Pre-configuration Tasks

Before enabling the cable detection function, complete the following task:

l Configuring the working mode of the interface to auto-negotiation

Data Preparation

To configure the VCT function of the S-switch, you need the following data.

No. Data

1 Number of the Ethernet interface connected to the cable

1.6.2 Detecting the Status of a Connected Cable

Context

On the S-switch to detect the cable status, do as follows:

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:display cable interface-type interface-number

The status of the current cable is detected.

The detected status of the current cable can be any of the following.

Status

Description

normal

The cable status is normal.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-20 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 41: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Status

Description

abnormal

The cable status is abnormal.l open: A segment of the cable is disconnected.

l short: A segment of the cable is short-circuited.

l open/short: A segment of the cable is open or short-circuited.

l crosstalk: The cable sequence is incorrect.

unknown

The cable status is unknown.

NOTE

When the cable status is abnormal, the error of the length of the abnormal cable segment is ±1 m.

When the cable status is normal, the error of the length of the cable is ±10 m.

You can check the status of the cable only when the interface works in auto-negotiation mode.

Currently, the FE electrical interfaces do not support the cable detection function.

----End

1.7 Creating an Eth-TrunkThis section describes how to create an Eth-Trunk.

1.7.1 Establishing the Configuration Task

1.7.2 Creating an Eth-Trunk

1.7.3 Adding Member Interfaces to an Eth-Trunk

1.7.4 (Optional) Setting the Load Balancing Mode for an Eth-Trunk

1.7.5 Checking the Configuration

1.7.1 Establishing the Configuration Task

Applicable Environment

You can configure Eth-Trunks in the following scenarios:

l The bandwidth is insufficient when two S-switchs are connected through a single link.

l The connection reliability cannot be satisfied when two S-switchs are connected througha single link.

In the preceding situations, Eth-Trunks can be applied to balance the outgoing and incomingtraffic among many physical links. This increases the bandwidth and connection reliabilitybetween the two S-switchs.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-21

Page 42: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Pre-configuration TasksNone.

Data PreparationTo configure Eth-Trunks, you need the following data.

No. Data

1 IDs of Eth-Trunks

2 Types and numbers of member interfaces

1.7.2 Creating an Eth-Trunk

ContextDo as follows on the S-switch and the peer S-switch where an Eth-Trunk needs to be created.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

An Eth-Trunk is created.

----End

1.7.3 Adding Member Interfaces to an Eth-Trunk

ContextDo as follows on the S-switch and the peer S-switch where an Eth-Trunk needs to be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-22 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 43: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Step 3 Run:eth-trunk trunk-id

The Ethernet interface or GE interface is added to an Eth-Trunk.

When you add an Ethernet interface to an Eth-Trunk, the interface must adopt the default valuesof certain attributes. Otherwise, the interface cannot be added to the Eth-Trunk.

NOTE

If the Multiple Spanning Tree Protocol (MSTP) is enabled on the device where the interface to be addedto an Eth-Trunk resides, you must shut down the interface before adding the interface to the Eth-Trunk.After the interface is added to the Eth-Trunk, you can enable the interface. Otherwise, a temporary broadcaststorm occurs.

----End

1.7.4 (Optional) Setting the Load Balancing Mode for an Eth-Trunk

Context

Do as follows on the S-switch and the peer S-switch where an Eth-Trunk needs to be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:load-balance { dmac | smac | smacxordmac | sip | dip | sipxordip }

The load balancing mode is set for the Eth-Trunk.

By default, the load balancing mode of an Eth-Trunk is smacxordmac.

NOTE

S2300SI only supports the following load balancing mode of an Eth-Trunk:

l dmac

l smac

l smacxordmac

----End

1.7.5 Checking the ConfigurationRun the following commands to check the previous configuration.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-23

Page 44: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Action Command

Check the member interfaces ofan Eth-Trunk.

display trunkmembership eth-trunk trunk-id

Check the load balancing mode ofan Eth-Trunk.

display interface eth-trunk [ trunk-id ] [ verbose ] [ |{ begin | exclude | include } regular-expression ]

After the configuration succeeds, the following results can be obtained with the precedingcommands:

l The member interfaces are properly configured for the Eth-Trunk.

l The load balancing mode is properly set for the Eth-Trunk.

1.8 Deleting an Eth-TrunkDeleting an Eth-Trunk

1.8.2 (Optional) Deleting a Member Interface from an Eth-Trunk is the prerequisite to 1.8.3(Optional) Deleting an Eth-Trunk. You must delete all member interfaces of an Eth-Trunkbefore deleting the Eth-Trunk.

1.8.1 Establishing the Configuration Task

1.8.2 (Optional) Deleting a Member Interface from an Eth-Trunk

1.8.3 (Optional) Deleting an Eth-Trunk

1.8.4 Checking the Configuration

1.8.1 Establishing the Configuration Task

Applicable Environment

The configuration task is applicable to the following:

l A member interface needs to be deleted from an Eth-Trunk.

l An Eth-Trunk needs to be deleted.

Pre-configuration Tasks

Before deleting an Eth-Trunk, you must configure the Eth-Trunk or member interfaces of theEth-Trunk.

Data Preparation

To delete member interfaces from an Eth-Trunk or delete an Eth-Trunk, you need the followingdata.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-24 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 45: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

No. Data

1 (Optional) Numbers of the member interfaces to be deleted

2 (Optional) ID of the Eth-Trunk to be deleted

1.8.2 (Optional) Deleting a Member Interface from an Eth-Trunk

Context

Do as follows to delete a member interface from an Eth-Trunk.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Step 3 Run:undo eth-trunk trunk-id

The Ethernet interface is deleted from a specified Eth-Trunk.

----End

1.8.3 (Optional) Deleting an Eth-Trunk

Context

Do as follows to delete an Eth-Trunk.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:undo interface eth-trunk trunk-id

The specified Eth-Trunk is deleted.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-25

Page 46: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

Ensure that all member interfaces of an Eth-Trunk are deleted before deleting the Eth-Trunk. Otherwise,the Eth-Trunk cannot be deleted.

----End

1.8.4 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check member interfaces of anEth-Trunk.

display trunkmembership eth-trunk trunk-id

Check an Eth-Trunk. display current-configuration [ | { begin | exclude |include } regular-expression ]

After the configuration succeeds, the following results can be obtained with the precedingcommands:

l The member interfaces are properly configured for the Eth-Trunk.

l The current configuration is displayed in the system view and you can find that the specifiedEth-Trunk is deleted.

1.9 Creating an Interface GroupThis section describes how to create an interface group.

1.9.1 Establishing the Configuration Task

1.9.2 Creating an Interface Group

1.9.3 Adding Member Interfaces to an Interface Group

1.9.4 Checking the Configuration

1.9.1 Establishing the Configuration Task

Applicable EnvironmentTo run a command on multiple interfaces of the S-switch, you can add these interfaces into aninterface group, and then run the command in the interface group view to configure interfacesin batches.

Pre-configuration TasksNone

Data PreparationBefore configuring an interface group, you need the following data.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-26 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 47: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

No. Data

1 Name of an interface group

2 Type and number of a member interface

1.9.2 Creating an Interface Group

Context

Do as follows on the S-switch on which an interface group is required.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:port-group port-group-name

An interface group is created and the interface group view is displayed.

----End

1.9.3 Adding Member Interfaces to an Interface Group

Context

Do as follows on the S-switch on which member interfaces are to be added to an interface group.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:port-group port-group-name

The interface group view is displayed.

Step 3 Run:group-member { interface-type1 interface-number1 [ to interface-type2 interface-number2 ] } &<1-10>

Specified interfaces are added to the interface group.

----End

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-27

Page 48: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.9.4 Checking the Configuration

PrerequisiteRun the following command to check the previous configuration.

Procedure

Step 1 Run the display port-group { all | port-group-name } command to check information about thecurrent interface group.

----End

Example

Run the display port-group { all | port-group-name } command to check information about thecurrent interface group. For example:

<Quidway> display port-group allPortgroup:hhEthernet0/0/2Ethernet0/0/4Ethernet0/0/5Ethernet0/0/6Ethernet0/0/7Ethernet0/0/8

Portgroup:ffEthernet0/0/12Ethernet0/0/13Ethernet0/0/14Ethernet0/0/15Ethernet0/0/16Ethernet0/0/17Ethernet0/0/18

1.10 Deleting an Interface GroupDeleting an Interface Group

1.10.1 Establishing the Configuration Task

1.10.2 (Optional) Deleting a Member Interface from an Interface Group

1.10.3 (Optional) Deleting an Interface Group

1.10.4 Checking the Configuration

1.10.1 Establishing the Configuration Task

Applicable Environment

The configuration task is applicable to the following:

l A specified member interface is to be deleted from an interface group.

l An interface group is to be deleted.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-28 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 49: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Pre-configuration Tasks

Before deleting an interface group, complete the following tasks:

l 1.9.2 Creating an Interface Group

l 1.9.3 Adding Member Interfaces to an Interface Group

Data Preparation

To delete a member interface or an interface group, you need the following data.

No. Data

1 (Optional) Number of the member interface to be deleted

2 (Optional) Name of the interface group to be deleted

1.10.2 (Optional) Deleting a Member Interface from an InterfaceGroup

Context

Do as follows on the S-switch on which an interface group is to be deleted.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:port-group port-group-name

The interface group view is displayed.

Step 3 Run:undo group-member { interface-type1 interface-number1 [ to interface-type2 interface-number2 ] } &<1-10>

A specified member interface is deleted from the interface group.

----End

1.10.3 (Optional) Deleting an Interface Group

Context

Do as follows on the S-switch on which an interface group is to be deleted.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-29

Page 50: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:undo port-group { all | port-group-name }

A specified interface group is deleted.

----End

1.10.4 Checking the Configuration

PrerequisiteRun the following command to check the previous configuration.

Procedure

Step 1 Run the display port-group { all | port-group-name } command to check information about thecurrent interface group.

----End

ExampleRun the display port-group { all | port-group-name } command to check information about thecurrent interface group. For example:

<Quidway> display port-group allPortgroup:hhGigabitEthernet0/0/2GigabitEthernet0/0/4GigabitEthernet0/0/5GigabitEthernet0/0/6GigabitEthernet0/0/7GigabitEthernet0/0/8

1.11 Configuring Interface IsolationThis section describes how to configure interface isolation.

1.11.1 Establishing the Configuration Task

1.11.2 Configuring Interface Isolation

1.11.3 Checking the Configuration

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-30 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 51: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

1.11.1 Establishing the Configuration Task

Applicable EnvironmentWhen two Ethernet interfaces, two Eth-Trunks, or an Ethernet interface and an Eth-Trunk donot need to communicate, or only unidirectional communication is required, you can configureinterface isolation to implement unidirectional isolation or bidirectional isolation.

Pre-configuration TasksNone.

Data PreparationTo configure interface isolation, you need the following data.

No. Data

1 Number of the Ethernet interface to be isolated

1.11.2 Configuring Interface Isolation

ContextDo as follows on the S-switch that needs interface isolation.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:port-isolate mode { l2 | all }

The port isolation mode is set.

Step 3 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Or run:

interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 4 Run:am isolate { interface-type interface-number }&<1-8>

Or

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-31

Page 52: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

port-isolate enable

Interface isolation is enabled.

If you want to implement unidirectional isolation between Interface A and Interface B so thatpackets sent by interface A cannot reach interface B whereas packets sent by interface B canreach interface A, specify the parameters as follows:

l interface-type interface-number in Step 3 should specify the type and number of InterfaceA.

l { interface-type interface-number }&<1-8> in Step 4 should specify the type and number ofInterface B.

If you want to implement bidirectional isolation between Interface A and Interface B so thatpackets sent from Interface A and Interface B cannot reach each other, use the following ways:

l To isolate Interface B from Interface A, in addition to the preceding configuration, specifythe parameters as follows:– interface-type interface-number in Step 3 should specify the type and number of Interface

B.– { interface-type interface-number }&<1-8> in Step 4 should specify the type and number

of Interface A.l To add Interface A and Interface B to an isolation group, specify the parameters as follows:

– interface-type interface-number of interface in Step 3 should specify the type and numberof Interface A and that of Interface B.

– The port-isolateenable command in Step 4 should be run on Interface A and InterfaceB.

----End

1.11.3 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check the configuration ofinterface isolation on an Ethernetinterface or an Eth-Trunk.

display current-configuration interface interface-typeinterface-number

Check information about theinterfaces added to an isolationgroup.

display port-isolate group

After the configuration succeeds, run the preceding command. You can view that interfaceisolation is correctly configured on an Ethernet interface or an Eth-Trunk.

1.12 Maintaining Ethernet InterfacesThis section describes how to maintain Ethernet interfaces.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-32 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 53: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

CAUTIONDebugging affects the performance of the system. So, after debugging, run the undo debuggingall command to disable it immediately.

When a fault occurs on an Ethernet interface or an Eth-Trunk, you can run the followingdebugging command in the user view to debug the Ethernet interface or Eth-Trunk, view thedebugging information, locate the fault, and analyze the cause. For the procedure for displayingthe debugging information, refer to the chapter "Maintenance and Debugging" in the QuidwayS2300 Series Ethernet Switches Configuration Guide - Device Management.

Action Command

Enable the debugging of data link layerfeatures.

debugging l2if [ error | event | msg |updown ]

1.13 Configuration ExamplesThis section provides several examples for configuring Ethernet interfaces.

1.13.1 Example for Setting Attributes of Ethernet Interfaces1.13.2 Example for Configuring Interface Isolation

1.13.1 Example for Setting Attributes of Ethernet Interfaces

Networking RequirementsAs shown in Figure 1-3, GE 0/0/1 on S-switch-A is connected to GE 0/0/2 on S-switch-B; GE0/0/1 on S-switch-C is connected to a LAN switch (LSW).

l To prevent congestion on the links, it is required that auto-negotiation of flow control beenabled on S-switch-A and S-switch-B.

l To ensure normal transmission of services, it is required that the following be achieved onthe Ethernet interfaces of all the S-switches:– The maximum percentage of broadcast, multicast, and unknown unicast traffic that an

Ethernet interface allows to pass through is not more than 15%.– Jumbo frames are allowed to pass through.

NOTE

S2300SI does not allow jumbo frames to pass through any interfaces.

Figure 1-3 Networking for setting attributes of Ethernet interfaces

MetroGE0/0/2 GE0/0/1

GE0/0/1

S-switch-A S-switch-CS-switch-B

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-33

Page 54: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Configuration RoadmapThe configuration roadmap is as follows:

l Configure traffic suppression on S-switch-A, S-switch-B, and S-switch-C.

l Configure auto-negotiation of flow control on S-switch-A and S-switch-B.

l Configure S-switch-A, S-switch-B, and S-switch-C to allow jumbo frames to pass through.

Data PreparationTo complete the configuration, you need the following data:l Numbers of interfaces that connect S-switch-A and S-switch-B

l Number of the interface on S-switch-C that connects the LSW

Configuration Procedure1. Configure traffic suppression on S-switch-A, S-switch-B, and S-switch-C.

# Configure S-switch-A.<Quidway> system-view[Quidway] interface gigabitethernet 0/0/1[Quidway-GigabitEthernet0/0/1] broadcast-suppression 15[Quidway-GigabitEthernet0/0/1] multicast-suppression 15[Quidway-GigabitEthernet0/0/1] unicast-suppression 15# Configure S-switch-B.<Quidway> system-view[Quidway] interface gigabitethernet 0/0/2[Quidway-GigabitEthernet0/0/2] broadcast-suppression 15[Quidway-GigabitEthernet0/0/2] multicast-suppression 15[Quidway-GigabitEthernet0/0/2] unicast-suppression 15# Configure S-switch-C.<Quidway> system-view[Quidway] interface gigabitethernet 0/0/1[Quidway-GigabitEthernet0/0/1] broadcast-suppression 15[Quidway-GigabitEthernet0/0/1] multicast-suppression 15[Quidway-GigabitEthernet0/0/1] unicast-suppression 15

2. Configure auto-negotiation of flow control on S-switch-A and S-switch-B.# Configure S-switch-A.<Quidway> system-view[Quidway] interface gigabitethernet 0/0/1[Quidway-GigabitEthernet0/0/1] negotiation auto[Quidway-GigabitEthernet0/0/1] flow-control negotiation# Configure S-switch-B.<Quidway> system-view[Quidway] interface gigabitethernet 0/0/2[Quidway-GigabitEthernet0/0/2] negotiation auto[Quidway-Gigabitethernet0/0/2] flow-control negotiation

3. Configure S-switch-A, S-switch-B, and S-switch-C to allow jumbo frames to pass through.# Configure S-switch-A.<Quidway> system-view[Quidway] interface gigabitethernet 0/0/1[Quidway-Gigabitethernet0/0/1] jumboframe enable# Configure S-switch-B.

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-34 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 55: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

<Quidway> system-view[Quidway] interface gigabitethernet 0/0/2[Quidway-Gigabitethernet0/0/2] jumboframe enable# Configure S-switch-C.<Quidway> system-view[Quidway] interface gigabitethernet 0/0/1[Quidway-Gigabitethernet0/0/1] jumboframe enable

Configuration Filesl Configuration file of S-switch-A

#interface Gigabitethernet0/0/1 broadcast-suppression 15 multicast-suppression 15 unicast-suppression 15 negotiation auto flow-control negotiation jumboframe enable#return

l Configuration file of S-switch-B#interface Gigabitethernet0/0/2 broadcast-suppression 15 multicast-suppression 15 unicast-suppression 15 negotiation auto flow-control negotiation jumboframe enable#return

l Configuration files of S-switch-C#interface Gigabitethernet0/0/1 broadcast-suppression 15 multicast-suppression 15 unicast-suppression 15 jumboframe enable#return

1.13.2 Example for Configuring Interface Isolation

Networking RequirementsAs shown in Figure 1-4, security threats exist in the network connected to Ethernet 0/0/2. Thus,it is required that Ethernet 0/0/2 be isolated from Ethernet 0/0/1, and Ethernet 0/0/2 and Ethernet0/0/3 be isolated from each other.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-35

Page 56: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Figure 1-4 Networking for configuring interface isolation

VLAN6Eth0/0/1 Eth0/0/3

Eth0/0/2

S-switch-A

1 2 3

Configuration RoadmapThe configuration roadmap is as follows:

l Create VLAN 6 and add Ethernet 0/0/1, Ethernet 0/0/2, and Ethernet 0/0/3 to VLAN 6.

l Isolate Ethernet 0/0/2 from Ethernet 0/0/1.

l Add Ethernet 0/0/2 and Ethernet 0/0/3 to an interface group in batches, and configure theinterface isolation function on the interface group to implement bidirectional isolation.

Data PreparationTo complete the configuration, you need the following data:

l Numbers of interfaces that connect S-switch-A to the three LSWs

Configuration Procedure1. Create VLAN 6 and add Ethernet 0/0/1, Ethernet 0/0/2, and Ethernet 0/0/3 to VLAN 6.

[Quidway] vlan batch 6[Quidway-vlan6] port ethernet 0/0/1 to 0/0/3[Quidway-vlan6] quit

2. Isolate Ethernet 0/0/2 from Ethernet 0/0/1.[Quidway] interface ethernet 0/0/2[Quidway-Ethernet0/0/2] am isolate ethernet 0/0/1[Quidway-Ethernet0/0/2] quit

3. Add Ethernet 0/0/2 and Ethernet 0/0/3 to an interface group in batches, and configure theinterface isolation function on the interface group to implement bidirectional isolation.[Quidway] port-group geli[Quidway-port-group-geli] group-member ethernet 0/0/2 to ethernet 0/0/3[Quidway-port-group-geli] port-isolate enable[Quidway-port-group-geli] quitOr add Ethernet 0/0/2 and Ethernet 0/0/3 to an isolation group to implement bidirectionalisolation between Ethernet 0/0/2 and Ethernet 0/0/3.[Quidway] interface ethernet 0/0/2[Quidway-Ethernet0/0/2] port-isolate enable

1 Ethernet Interface ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

1-36 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 57: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

[Quidway-Ethernet0/0/2] quit[Quidway] interface ethernet 0/0/3[Quidway-Ethernet0/0/3] port-isolate enable

4. Verify the configuration.

Do as follows to verify the configuration:

l Ping a host in Network 2 from a host in Network 1. The ping fails. The host in Network2 can receive packets sent from Network 1; the host in Network 1, however, cannotreceive the packets replied from Network 2. This indicates that Ethernet 0/0/2 is isolatedfrom Ethernet 0/0/1.

l Ping a host in Network 2 from a host in Network 3. The ping fails; the host in Network2 cannot receive packets sent from Network 3. Ping a host in Network 3 from a host inNetwork 2. The ping fails; the host in Network 3 cannot receive packets sent fromNetwork 2. This indicates that Ethernet 0/0/2 and Ethernet 0/0/3 are isolated from eachother.

Configuration Files

Configuration file of S-switch-A

# sysname Quidway# vlan batch 6#interface ethernet0/0/1 port default vlan 6#interface ethernet0/0/2 port default vlan 6 am isolate ethernet0/0/1 port-isolate enable#interface ethernet0/0/3 port default vlan 6 port-isolate enable# port-group geli group-member Ethernet0/0/2 group-member Ethernet0/0/3#return

Or, configuration file of S-switch-A

# sysname Quidway# vlan batch 6#interface ethernet0/0/1 port default vlan 6#interface ethernet0/0/2 port default vlan 6 am isolate ethernet0/0/1 port-isolate enable#interface ethernet0/0/3 port default vlan 6 port-isolate enable#return

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 1 Ethernet Interface Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

1-37

Page 58: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]
Page 59: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

2 LACP Configuration

About This Chapter

This chapter describes basic knowledge, configuration methods, and configuration examples ofthe Link Aggregation Control Protocol (LACP).

2.1 Introduction to Link AggregationThis section describes the concepts of link aggregation and the classification of link aggregationsupported by the S-switch.

2.2 Configuring Link Aggregation in Manual Load Balancing ModeThis section describes how to configure link aggregation in manual load balancing mode.

2.3 Configuring Link Aggregation in Static LACP ModeThis section describes how to configure link aggregation in static LACP mode.

2.4 Maintaining LACPThis section describes how to clear the LACP statistics, debug the link aggregation group,andmonitor the operation status of the link aggregation group.

2.5 Configuration ExamplesThis section provides several configuration examples of LACP.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-1

Page 60: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

2.1 Introduction to Link AggregationThis section describes the concepts of link aggregation and the classification of link aggregationsupported by the S-switch.

2.1.1 Link Aggregation Overview

2.1.2 Link Aggregation Modes Supported by the S-switch

2.1.3 Related Concepts of LACP

2.1.4 Logical Relationships Between Configuration Tasks

2.1.1 Link Aggregation Overview

Link aggregation refers to a method of binding a group of physical interfaces together as a logicalinterface to increase the bandwidth. Link aggregation is also called the multi-interface loadsharing group or Link Aggregation Group (LAG). For more information about link aggregation,refer to IEEE802.3ad.

By setting up an LAG between two devices, you can obtain higher bandwidth and greaterreliability. Link aggregation provides redundancy protection for communications among deviceswithout upgrading the hardware.

2.1.2 Link Aggregation Modes Supported by the S-switch

Manual Load Balancing ModeIn manual load balancing mode, you can manually add member interfaces to an LAG. Allinterfaces are in the forwarding state to transmit packets. Load balancing that the S-switch canperform load balancing based on destination MAC addresses, source MAC addresses, sourceMAC address exclusive-or destination MAC address, source IP addresses, destination IPaddresses, or source address exclusive-or destination IP address.

In manual load balancing mode, you must set up an Eth-Trunk and add interfaces to the Eth-Trunk. You must also configure member interfaces in the active state. The Link AggregationControl Protocol Date Units (LACPDUs) are not required.

The manual load balancing mode is used when the peer device does not support LACP.

Static LACP ModeThe static LACP mode refers to a link aggregation method of determining active and inactiveinterfaces by negotiating aggregation parameters through LACPDUs. In static LACP mode, youmust manually set up an Eth-Trunk and add member interfaces to the Eth-Trunk. The active andinactive interfaces are negotiated through parameters in the LACPDUs.

The static LACP mode is called M:N mode. The static LACP mode can implement loadbalancing and backup. In an LAG, M links are active to forward data and perform load balancing.In addition, other N links are inactive. They act as backup links that do not forward data. Whena fault occurs on one of the M links, the system selects the link with the highest priority fromthe N backup links to replace the faulty link. At the same time, the link becomes active and startsto forward data.

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 61: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

There is the dynamic LACP mode in comparison to the static LACP mode. In dynamic LACPmode, the creation of the Eth-Trunk and the addition of the member interfaces are automaticallynegotiated through parameters in the LACPDUs without manual interference. The dynamicLACP mode can be easily configured. It is, however, too flexible and thus hard to manage. TheS-switch does not support link aggregation in dynamic LACP mode.

2.1.3 Related Concepts of LACP

Active and Inactive InterfacesThe interfaces that are responsible for forwarding data are active interfaces. In contrary, theinterfaces that do not forward data are inactive interfaces. According to the operation modes,active and inactive interfaces are classified as follows:

l Manual load balancing mode: Generally, all member interfaces are active ones unless faultsoccur on these interfaces.

l Static LACP mode: The interfaces connected to M links are active interfaces that areresponsible for forwarding data; the interfaces connected to N links are inactive interfacesthat are responsible for redundancy.

Actor and PartnerIn static LACP mode, the device with a higher LACP priority at both ends of an LAG is theActor and the device with a lower LACP priority is the Partner.

Differentiating the Actor and the Partner is to ensure that active interfaces of devices at bothends are the same. If devices at both ends select active interfaces according to the priority oftheir own interfaces, the active interfaces may be different and the active links cannot be set up.Therefore, the Actor is first determined. The Partner selects active interfaces according to thepriority of the interfaces of the Actor, as shown in Figure 2-1.

Figure 2-1 Determining the active links by the Actor in static LACP mode

The Actor determinesactive links

S-switch-B

S-switch-B

S-switch-A

The device with highersystem priority

The device with lowersystem priority

S-switch-A

Active interfacesseleted by S-switch-A

Active interfacesseleted by S-switch-B

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-3

Page 62: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

2.1.4 Logical Relationships Between Configuration Tasks

There is no strict logical relationship between configuration tasks. You can perform anyconfiguration task as required.

2.2 Configuring Link Aggregation in Manual LoadBalancing Mode

This section describes how to configure link aggregation in manual load balancing mode.

2.2.1 Establishing the Configuration Task

2.2.2 Creating an Eth-Trunk

2.2.3 (Optional) Configuring the Eth-Trunk to Work in Manual Load Balancing Mode

2.2.4 Adding a Member Interface to the Eth-Trunk

2.2.5 (Optional) Setting the Load Balancing Mode

2.2.6 Checking the Configuration

2.2.1 Establishing the Configuration Task

Applicable Environment

As shown in Figure 2-2, when the bandwidth or the reliability of two devices needs to beincreased, you can create an Eth-Trunk in manual load balancing mode on the S-switch and addmultiple member interfaces to the Eth-Trunk to increase the bandwidth and reliability of devices.

Figure 2-2 Networking diagram of link aggregation in manual load balancing mode

Eth-Trunk 1Eth-Trunk 1S-switch-A

Eth-Trunk

S-switch-B

Pre-configuration Tasks

Before configuring link aggregation in manual load balancing mode, complete the followingtask:

l Powering on the S-switch

Data Preparation

Before configuring link aggregation in manual load balancing mode, you need the followingdata.

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 63: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

No. Data

1 Number of the Eth-Trunk in manual load balancing mode

2 Type and number of the member interface

2.2.2 Creating an Eth-Trunk

ContextDo as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

An Eth-Trunk is created and the Eth-Trunk interface view is displayed.

NOTE

The IDs of the Eth-Trunks created on the S-switchs at both ends can be different. To identify and maintain theEth-Trunks at both ends, using the same ID for the Eth-Trunks at both ends is recommended.

----End

2.2.3 (Optional) Configuring the Eth-Trunk to Work in ManualLoad Balancing Mode

ContextNOTE

Ensure that an Eth-Trunk does not contain any member interface before you configure the operation mode ofthe Eth-Trunk; otherwise, the operation mode of the Eth-Trunk cannot be changed. Run the undo eth-trunktrunk-id command in the interface view to delete the existing member interfaces.

Do as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-5

Page 64: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The Eth-Trunk interface view is displayed.

Step 3 Run:mode manual [ load-balance ]

The Eth-Trunk is configured to work in manual load balancing mode.

By default, an Eth-Trunk works in manual load balancing mode. If you do not adjust the operationmode of an Eth-Trunk to the static LACP mode during or after the establishment of the Eth-Trunk, you can choose not to configure the manual load balancing mode.

----End

2.2.4 Adding a Member Interface to the Eth-Trunk

ContextDo as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:eth-trunk trunk-id

The current interface is added to the Eth-Trunk.

NOTE

When adding an interface to an Eth-Trunk, ensure that no configuration such as the cable type, duplex mode,and rate exists on the interface. Run the display this command to check whether the configuration exists on theinterface. If the configuration exists on the interface, first delete the configuration, and then add the interface tothe Eth-Trunk.

----End

2.2.5 (Optional) Setting the Load Balancing Mode

ContextDo as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 65: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:load-balance { dmac | smac | smacxordmac | sip | dip | sipxordip }

The manual load balancing mode of the Eth-Trunk is set.

By default, the load balancing mode of an Eth-Trunk is smacxordmac.

The load balancing mode of the local end and that of the peer end can be different because theydo not interact with each other.

NOTE

S2300SI only supports the following load balancing mode of an Eth-Trunk:

l dmac

l smac

l smacxordmac

----End

2.2.6 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check the member interface ofthe Eth-Trunk.

display trunkmembership eth-trunk trunk-id

Check the manual load balancingmode of the Eth-Trunk.

display eth-trunk [ trunk-id [ interface interface-typeinterface-number ] ]

Run the display trunkmembership eth-trunk command. If you can view the operation modeof the Eth-Trunk as Normal, number of member interfaces, number of member interfaces in theUp state, and information about member interfaces, it means that the configuration succeeds.

<Quidway> display trunkmembership eth-trunk 1Trunk ID: 1used status: VALIDTYPE: ethernetWorking Mode : NormalWorking State: NormalNumber Of Ports in Trunk = 3Number Of UP Ports in Trunk = 3operate status: up Interface Ethernet0/0/1, valid, selected, operate up, weight=1,standby interface NULL Interface Ethernet0/0/2, valid, selected, operate up, weight=1,standby interface NULL Interface Ethernet0/0/3, valid, selected, operate up, weight=1,

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-7

Page 66: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

standby interface NULL

Run the display eth-trunk command to check the load balancing mode of an Eth-Trunk. If theload balancing mode is displayed as Normal, it means that the configuration succeeds.<Quidway> display eth-trunk 1Eth-Trunk1's state information is:WorkingMode: NORMAL Hash arithmetic: According to MACLeast Active-linknumber: 1 Max Bandwidth-affected-linknumber: 8Operate status: up Number Of Up Port In Trunk: 3--------------------------------------------------------------------------------PortName Status WeightEthernet0/0/1 Up 1Ethernet0/0/2 Up 1Ethernet0/0/3 Up 1

2.3 Configuring Link Aggregation in Static LACP ModeThis section describes how to configure link aggregation in static LACP mode.2.3.1 Establishing the Configuration Task2.3.2 Creating an Eth-Trunk2.3.3 Configuring the Eth-Trunk to Work in Static LACP Mode2.3.4 Adding a Member Interface to the Eth-Trunk2.3.5 Configuring the S-switch to Process BPDUs2.3.6 (Optional) Setting the LACP Priority of the System2.3.7 (Optional) Setting the Upper Threshold for the Number of Active Interfaces2.3.8 (Optional) Setting the Lower Threshold for the Number of Active Interfaces2.3.9 (Optional) Setting the LACP Priority of the Interface2.3.10 (Optional) Enabling LACP Preemption and Setting the Delay for LACP Preemption2.3.11 Checking the Configuration

2.3.1 Establishing the Configuration Task

Applicable EnvironmentTo improve the bandwidth and the reliability of two devices, you should create an LAG on twodirectly connected S-switchs. The requirements are as follows:

l The links between two devices can implement redundancy. When a fault occurs on certainlinks, the backup links are used to replace the faulty ones to keep data transmissionuninterrupted.

l The active links can perform load balancing.

Figure 2-3 Networking diagram of link aggregation in static LACP mode

S-switch-BS-switch-A Eth-Trunk 1Eth-Trunk 1

Active linksBackup links

Eth-Trunk

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 67: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

An Eth-Trunk in static LACP mode does not support the following interfaces to be aggregated:

l Gigabit Ethernet interfaces and 100M Ethernet interfaces

Pre-configuration Tasks

Before configuring link aggregation in static LACP mode, complete the following task:

l Powering on the S-switch

Data Preparation

To configure link aggregation in static LACP mode, you need the following data.

No. Data

1 Number of the Eth-Trunk

2 Type and number of the member interface

3 Upper threshold for the number of active interfaces

2.3.2 Creating an Eth-Trunk

Context

Do as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

An Eth-Trunk is created and the Eth-Trunk interface view is displayed.

NOTE

The IDs of the Eth-Trunks created on the S-switchs at both ends can be different. To identify and maintain theEth-Trunks at both ends, using the same ID for the Eth-Trunks at both ends is recommended.

----End

2.3.3 Configuring the Eth-Trunk to Work in Static LACP Mode

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-9

Page 68: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

ContextNOTE

Ensure that the Eth-Trunk does not contain any member interface before you configure the operation mode ofthe Eth-Trunk; otherwise, the operation mode of the Eth-Trunk cannot be modified. Run the undo eth-trunktrunk-id command in the interface view to delete the existing member interfaces.

Do as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:mode lacp-static

The Eth-Trunk is configured to work in static LACP mode.

By default, an Eth-Trunk works in manual load balancing mode.

Step 4 Run:lacp timeout{ fast | slow}

The timeout duration of LACP packets is set.

By default, the timeout duration of LACP packets is thirty seconds.

----End

2.3.4 Adding a Member Interface to the Eth-Trunk

ContextDo as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:eth-trunk trunk-id

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-10 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 69: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The interface is added to the Eth-Trunk.

NOTE

l When adding an interface to an Eth-Trunk, ensure that no configuration exists on the interface. You canconfigure the cable type, duplex mode, and rate for the interface. Run the display this command to checkwhether the configuration exists on the interface. If the configuration exists on the interface, first delete theconfiguration, and then add the interface to the Eth-Trunk.

l The number of interfaces added to the LAG should not be greater than eight.

----End

2.3.5 Configuring the S-switch to Process BPDUs

ContextDo as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu enable

The S-switch is configured to process Bridge Protocol Data Units (BPDUs).

When configuring link aggregation in static LACP mode, you need run the bpdu enablecommand in the System view so that the S-switch can receive and process LACPDUs. If thebpdu enable command is not run, the S-switch discards LACPDUs. As a result, the Eth-Trunkbecomes Down.

----End

2.3.6 (Optional) Setting the LACP Priority of the System

ContextDo as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:lacp priority priority

The LACP priority is set for the system of the S-switch.

The lower the LACP priority of the system is, the higher the priority of the S-switch is.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-11

Page 70: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

You can select a S-switch at one end as the Actor and set the LACP priority of the system to asmaller value. By default, the LACP priority of the system is 32768. Therefore, one end can bethe Actor only when its LACP priority of the system is smaller than 32768.

----End

2.3.7 (Optional) Setting the Upper Threshold for the Number ofActive Interfaces

ContextDo as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:max bandwidth-affected-linknumber link-number

The upper threshold is set for the number of active interfaces.

By default, the upper threshold for the number of active interfaces is 8.

In static LACP mode, you can control maximum number M of active interfaces in an Eth-Trunkby setting the upper threshold for the number of active interfaces. The remaining memberinterfaces are backup ones.

If the upper threshold is not set, a maximum of eight interfaces in the Eth-Trunk can be active.

NOTE

l The upper threshold for the number of active interfaces should not be smaller than the lower threshold forthe number of active interfaces.

l The upper threshold for the number of active interfaces of the local S-switch and that of the remote S-switch can be different. If the upper threshold for the number of active interfaces at both ends is different,take the smaller upper threshold.

----End

2.3.8 (Optional) Setting the Lower Threshold for the Number ofActive Interfaces

ContextDo as follows on the S-switchs at both ends.

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-12 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 71: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:least active-linknumber link-number

The lower threshold is set for the number of active interfaces.

By default, the lower threshold for the number of active interfaces is 1.

In static LACP mode, you can determine the minimum number of active interfaces in an Eth-Trunk by setting the lower threshold for the number of active interfaces. If the number of activeinterfaces in static LACP mode is smaller than the value, the interface of the Eth-Trunk becomesDown.

NOTE

l The lower threshold for the number of active interfaces should not be greater than the upper threshold forthe number of active interfaces.

l The lower threshold for the number of active interfaces of the local S-switch and that of the remote S-switch can be different. If the lower threshold at both ends are different, take the greater lower threshold.

----End

2.3.9 (Optional) Setting the LACP Priority of the Interface

ContextDo as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:lacp priority priority

The LACP priority is set for the interface.

By default, the LACP priority of an interface is 32768.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-13

Page 72: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

The LACP priority of the interface indicates the priority when the interface becomes the active interface. Thelower the LACP priority of the interface is, the higher the priority of the interface is. By default, the LACPpriority of an interface is 32768.

----End

2.3.10 (Optional) Enabling LACP Preemption and Setting the Delayfor LACP Preemption

ContextDo as follows on the S-switchs at both ends.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:lacp preempt enable

LACP preemption is enabled for the Eth-Trunk.

By default, LACP preemption is disabled.

NOTE

To ensure normal running of an Eth-Trunk, it is recommended that you enable or disable LACP preemptionon both ends of the Eth-Trunk.

Step 4 Run:lacp preempt delay delay-time

The delay is set for LACP preemption on the Eth-Trunk.

By default, the delay for LACP preemption is 30s.

NOTE

Before enabling LACP preemption, you should set the upper threshold for the number of active interfaces.

The preemption function takes effect only on the active interface. The preemption function must be configuredtogether with the upper limit of active interfaces. To guarantee that the preemption function works normally, itis recommended that the preemption function and the upper limit of active interfaces be configured on only theactive interface before you use the preemption function.

When LACP preemption is enabled, the interface with the highest LACP priority can be an activeinterface. For example, when an interface with a high priority switches to inactive due to failureand then recovers, the interface can become the active interface if LACP preemption is enabled;the interface cannot become the active interface if the LACP preemption function is disabled.

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-14 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 73: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The delay for LACP preemption refers to the period when an inactive interface of the Eth-Trunkin static LACP mode switches to active.

----End

2.3.11 Checking the ConfigurationRun the following commands on both S-switchs to check the previous configuration.

Action Command

Check the member interface ofthe Eth-Trunk.

display trunkmembership eth-trunk trunk-id

Check information about the Eth-Trunk and active interfaces.

display eth-trunk [ trunk-id [ interface interface-typeinterface-number ] ]

Run the display trunkmembership eth-trunk command. If you can view the operation modeof the Eth-Trunk as Static, number of member interfaces, number of member interfaces in theUp state, and information about member interfaces, it means that the configuration succeeds.

<Quidway> display trunkmembership eth-trunk 1Trunk ID: 1used status: VALIDTYPE: ethernetWorking Mode : StaticNumber Of Ports in Trunk = 3Number Of UP Ports in Trunk = 3operate status: upInterface GigabitEthernet0/0/1, valid, selected, operate up, weight=1,standby interface NULLInterface GigabitEthernet0/0/2, valid, selected, operate up, weight=1,standby interface NULLInterface GigabitEthernet0/0/3, valid, selected, operate down, weight=1,standby interface NULL

Run the display eth-trunk command to check the working mode.

<Quidway> display eth-trunk 1Eth-Trunk1's state information is:Local:LAG ID: 1 WorkingMode: STATICPreempt Delay Time: 60 Sec Hash arithmetic: According to MACSystem Priority: 50 System ID: 0001-0168-0182Least Active-linknumber: 1 Max Bandwidth-affected-linknumber: 8Operate status: down Number Of Up Port In Trunk: 0--------------------------------------------------------------------------------ActorPortName Status PortType PortPri PortNo PortKey PortState WeightGigabitEthernet0/0/1 Selected 100M 32768 1 289 11111100 1GigabitEthernet0/0/2 Selected 100M 32768 2 289 11111100 1GigabitEthernet0/0/3 Selected 100M 32768 3 289 11111100 1 Partner:--------------------------------------------------------------------------------ActorPortName SysPri SystemID PortPri PortNo PortKey PortStateGigabitEthernet0/0/1 32768 0077-7777-7777 32768 1 289 11111100GigabitEthernet0/0/2 32768 0077-7777-7777 32768 2 289 11111100GigabitEthernet0/0/3 32768 0077-7777-7777 32768 3 289 11111100

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-15

Page 74: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

2.4 Maintaining LACPThis section describes how to clear the LACP statistics, debug the link aggregation group,andmonitor the operation status of the link aggregation group.

2.4.1 Clearing the Statistics of Received and Sent LACPDUs

2.4.2 Debugging LACP

2.4.3 Monitoring the Operation Status of the LAG

2.4.1 Clearing the Statistics of Received and Sent LACPDUs

CAUTIONThe statistics of received and sent LACPDUs cannot be restored after you clear them. So, confirmthe action before you use the command.

To clear the statistics of received and sent LACPDUs, run the following command in the userview.

Action Command

Clear the statistics ofreceived and sentLACPDUs.

reset lacp statistics eth-trunk [ trunk-id [ interfaceinterface-type interface-number ] ]

2.4.2 Debugging LACP

CAUTIONDebugging affects the performance of the system. So, after debugging, run the undo debuggingall command to disable it immediately.

When an LACP fault occurs, run the following debugging commands in the user view to locatethe fault.

Action Command

Debug Eth-Trunk errors. debugging trunk error [ slot slot-number ]

Debug Eth-Trunk events. debugging trunk event [ slot slot-number ]

Debug LACPDUs. debugging trunk lacp-pdu [ slot slot-number ]

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-16 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 75: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Action Command

Debug LACP messages. debugging trunk lagmsg [ slot slot-number ]

Debug Eth-Trunk messages. debugging trunk msg [ slot slot-number ]

Debug Eth-Trunk state machines. debugging trunk state-machine [ slot slot-number ]

Debug information when the Eth-Trunk isUp and Down.

debugging trunk updown [ slot slot-number ]

2.4.3 Monitoring the Operation Status of the LAG

During routine maintenance, you can run the following commands in any view to check theoperation status of the LAG.

Action Command

Check the status of the LAG. display eth-trunk [ trunk-id [ interface interface-typeinterface-number ] ]

Check the statistics ofreceived and sentLACPDUs.

display lacp statistics eth-trunk [ trunk-id [ interfaceinterface-type interface-number ] ]

Check the member interfaceof the Eth-Trunk.

display trunkmembership eth-trunk trunk-id

2.5 Configuration ExamplesThis section provides several configuration examples of LACP.

2.5.1 Example for Configuring Link Aggregation in Manual Load Balancing Mode

2.5.2 Example for Configuring Link Aggregation in Static LACP Mode

2.5.1 Example for Configuring Link Aggregation in Manual LoadBalancing Mode

Networking Requirements

As shown in Figure 2-4, S-switch-A and S-switch-B are two S-switchs and the link between S-switch-A and S-switch-B is one of the backbone transmission links of the Metropolitan AreaNetwork (MAN). The link is required to be of high reliability and load balancing of data trafficcan be performed between S-switch-A and S-switch-B.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-17

Page 76: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Figure 2-4 Networking diagram of link aggregation in manual load balancing mode

Eth-Trunk

Eth-Trunk 1 Eth-Trunk 1

S-switch-BS-switch-AEth 0/0/1

Eth 0/0/2

Eth 0/0/3

Eth 0/0/1Eth 0/0/2

Eth 0/0/3

Configuration RoadmapThe configuration roadmap is as follows:

1. Create VLAN and add add interfaces to the VLAN.2. Create an Eth-Trunk.3. Add member interfaces to the Eth-Trunk.

NOTE

After the Eth-Trunk is created, the Eth-Trunk works in manual load balancing mode by default. That is,you do not need to configure the Eth-Trunk in manual load balancing mode by default. If the currentoperation mode is configured as another mode, use the mode command to change the mode.

Data PreparationTo complete the configuration, you need the following data:

l Number of the LAG

l Type and number of the member interface of the Eth-Trunk

Configuration Procedure1. Create VLAN and add interfaces to the VLAN.

[Quidway] vlan 6[Quidway-vlan6] port GigabitEthernet 0/0/1 to 0/0/3

2. Create an Eth-Trunk.# Configure S-switch-A.<Quidway> system-view[Quidway] sysname S-switch-A[S-switch-A] interface eth-trunk 1[S-switch-A-Eth-Trunk1] quit# Configure S-switch-B.<Quidway> system-view[Quidway] sysname S-switch-B[S-switch-B] interface eth-trunk 1[S-switch-B-Eth-Trunk1] quit

3. Add member interfaces to the Eth-Trunk.# Configure S-switch-A.[S-switch-A] interface Ethernet0/0/1[S-switch-A-Ethernet0/0/1] eth-trunk 1[S-switch-A-Ethernet0/0/1] quit[S-switch-A] interface Ethernet0/0/2[S-switch-A-Ethernet0/0/2] eth-trunk 1[S-switch-A-Ethernet0/0/2] quit

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-18 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 77: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

[S-switch-A] interface Ethernet0/0/3[S-switch-A-Ethernet0/0/3] eth-trunk 1[S-switch-A-Ethernet0/0/3] quit# Configure S-switch-B.[S-switch-B-] interface Ethernet0/0/1[S-switch-B-Ethernet0/0/1] eth-trunk 1[S-switch-B-Ethernet0/0/1] quit[S-switch-B] interface Ethernet0/0/2[S-switch-B-Ethernet0/0/2] eth-trunk 1[S-switch-B-Ethernet0/0/2] quit[S-switch-B] interface Ethernet0/0/3[S-switch-B-Ethernet0/0/3] eth-trunk 1[S-switch-B-Ethernet0/0/3] quit

4. Verify the configuration.Run the display trunkmembership command in any view to check whether Eth-Trunk 1is created successfully and whether member interfaces are added correctly. Take S-switch-A as an example.[S-switch-A] display trunkmembership eth-trunk 1Trunk ID: 1used status: VALIDTYPE: ethernetWorking Mode : NormalWorking State: NormalNumber Of Ports in Trunk = 3Number Of UP Ports in Trunk = 3operate status: upInterface Ethernet0/0/1, valid, selected, operate up, weight=1,standby interface NULL Interface Ethernet0/0/2, valid, selected, operate up, weight=1,standby interface NULL Interface Ethernet0/0/3, valid, selected, operate up, weight=1,standby interface NULL

Configuration Filesl Configuration file of S-switch-A

# sysname S-switch-A#interface Eth-Trunk1#interface Ethernet0/0/1eth-trunk 1#interface Ethernet0/0/2eth-trunk 1#interface Ethernet0/0/3eth-trunk 1#return

l Configuration file of S-switch-B# sysname S-switch-B#interface Eth-Trunk1#interface Ethernet0/0/1eth-trunk 1#interface Ethernet0/0/2eth-trunk 1

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-19

Page 78: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

#interface Ethernet0/0/3eth-trunk 1#return

2.5.2 Example for Configuring Link Aggregation in Static LACPMode

Networking RequirementsAs shown in Figure 2-5, to improve the bandwidth and the reliability of two devices, configurethe link aggregation group on two directly connected S-switchs. The requirements are as follows:

l M active links can perform load balancing.

l N links between two devices can act as backup links to perform redundancy. When a faultoccurs on a link of active links, the backup link replaces the faulty link to keep the reliabilityof data transmission.

Figure 2-5 Networking diagram of link aggregation in static LACP mode

Eth-Trunk

Eth-Trunk 1 Eth-Trunk 1

S-switch-BS-switch-AEth 0/0/1

Eth 0/0/2

Eth 0/0/3

Eth 0/0/1Eth 0/0/2

Eth 0/0/3

Active linksBackup links

Configuration RoadmapThe configuration roadmap is as follows:

1. Create an Eth-Trunk on the S-switch and configure the Eth-Trunk to work in static LACPmode.

2. Add member interfaces to the Eth-Trunk.3. Configure the S-switch to process BPDUs.4. Set the LACP priority of the system and determine the Actor.5. Set the upper threshold for the number of active interfaces.6. Set the LACP priority of the interface and determine the active link.

Data PreparationTo complete the configuration, you need the following data:

l Number of the LAG of the S-switchs at both ends

l LACP priority of the system of S-switch-A

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-20 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 79: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

l Upper threshold for the number of active interfaces

l LACP priority of the active interface

Configuration Procedure1. Create an Eth-Trunk numbered one and configure Eth-Trunk 1 to work in static LACP

mode.

# Configure S-switch-A.<Quidway> system-view[Quidway] sysname S-switch-A[S-switch-A] interface eth-trunk 1[S-switch-A-Eth-Trunk1] mode lacp-static[S-switch-A-Eth-Trunk1] quit

# Configure S-switch-B.<Quidway> system-view[Quidway] sysname S-switch-B[S-switch-B] interface eth-trunk 1[S-switch-B-Eth-Trunk1] mode lacp-static[S-switch-B-Eth-Trunk1] quit

2. Add member interfaces to the Eth-Trunk.

# Configure S-switch-A.[S-switch-A] interface ethernet 0/0/1[S-switch-A-Ethernet0/0/1] eth-trunk 1[S-switch-A-Ethernet0/0/1] quit[S-switch-A] interface ethernet 0/0/2[S-switch-A-Ethernet0/0/2] eth-trunk 1[S-switch-A-Ethernet0/0/2] quit[S-switch-A] interface ethernet 0/0/3[S-switch-A-Ethernet0/0/3] eth-trunk 1[S-switch-A-Ethernet0/0/3] quit

# Configure S-switch-B.[S-switch-B] interface ethernet 0/0/1[S-switch-B-Ethernet0/0/1] eth-trunk 1[S-switch-B-Ethernet0/0/1] quit[S-switch-B] interface ethernet 0/0/2[S-switch-B-Ethernet0/0/2] eth-trunk 1[S-switch-B-Ethernet0/0/2] quit[S-switch-B] interface ethernet 0/0/3[S-switch-B-Ethernet0/0/3] eth-trunk 1[S-switch-B-Ethernet0/0/3] quit

3. Configure the S-switch to process BPDUs.

# Configure S-switch-A.[S-switch-A] bpdu enable

# Configure S-switch-B.[S-switch-B] bpdu enable

4. On S-switch-A, set the LACP priority of the system to 100 so that S-switch-A becomes theActor.[S-switch-A] lacp priority 100

5. On S-switch-A, set upper threshold M for the number of active interfaces to 2.[S-switch-A] interface eth-trunk 1[S-switch-A-Eth-Trunk1] max bandwidth-affected-linknumber 2[S-switch-A-Eth-Trunk1] quit

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-21

Page 80: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

S-switch-A functions as the Actor, so S-switch-B does not need to set the upper threshold. In Step6, the LACP priority of the interface needs to be set on S-switch-A only.

6. On S-switch-A, set the LACP priority of the interface and determine active links.[S-switch-A] interface ethernet 0/0/1[S-switch-A-Ethernet0/0/1] lacp priority 100[S-switch-A-Ethernet0/0/1] quit[S-switch-A] interface ethernet 0/0/2[S-switch-A-Ethernet0/0/2] lacp priority 100[S-switch-A-Ethernet0/0/2] quit

7. Verify the configuration.

# Check the information about the Eth-Trunks of the S-switchs and check whether thenegotiation succeeds on the link.[S-switch-A] display eth-trunk 1Eth-Trunk1's state information is:Local:LAG ID: 1 WorkingMode: STATICPreempt Delay: Disabled Hash arithmetic: According to MACSystem Priority: 100 System ID: 0077-7777-7777Least Active-linknumber: 1 Max Bandwidth-affected-linknumber: 2Operate status: up Number Of Up Port In Trunk: 2--------------------------------------------------------------------------------ActorPortName Status PortType PortPri PortNo PortKey PortState WeightEthernet0/0/1 Selected 100M 100 1 289 11111100 1Ethernet0/0/2 Selected 100M 100 2 289 11111100 1Ethernet0/0/3 Unselect 100M 32768 3 289 11100000 1

Partner:--------------------------------------------------------------------------------ActorPortName SysPri SystemID PortPri PortNo PortKey PortStateEthernet0/0/1 32768 0001-0168-0182 32768 1 289 11111100Ethernet0/0/2 32768 0001-0168-0182 32768 2 289 11111100Ethernet0/0/3 32768 0001-0168-0182 32768 3 289 11100000 [S-switch-B] display eth-trunk 1Eth-Trunk1's state information is: Local:LAG ID: 1 WorkingMode: STATICPreempt Delay: Disabled Hash arithmetic: According to MACSystem Priority: 32768 System ID: 0001-0168-0182Least Active-linknumber: 1 Max Bandwidth-affected-linknumber: 8Operate status: up Number Of Up Port In Trunk: 2--------------------------------------------------------------------------------ActorPortName Status PortType PortPri PortNo PortKey PortState WeightEthernet0/0/1 Selected 100M 32768 1 289 11111100 1Ethernet0/0/2 Selected 100M 32768 2 289 11111100 1Ethernet0/0/3 Unselect 100M 32768 3 289 11100000 1

Partner:--------------------------------------------------------------------------------ActorPortName SysPri SystemID PortPri PortNo PortKey PortStateEthernet0/0/1 100 0077-7777-7777 100 1 289 11111100Ethernet0/0/2 100 0077-7777-7777 100 2 289 11111100Ethernet0/0/3 100 0077-7777-7777 32768 3 289 11100000

The preceding information shows that the LACP priority of the system on S-switch-A is100, which is higher than that on S-switch-B. The two member interfaces of the Eth-Trunk,Ethernet 0/0/1 and Ethernet 0/0/2, become active interfaces. They are in the Selected state.

2 LACP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

2-22 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 81: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Ethernet 0/0/3 is in the Unselected state. Load balancing can be implemented on M linksand redundancy can be performed on N links.

Configuration Filesl Configuration file of S-switch-A

# sysname S-switch-A# bpdu enable# lacp priority 100#interface Eth-Trunk1 mode lacp-static max bandwidth-affected-linknumber 2#interface Ethernet0/0/1 eth-trunk 1 lacp priority 100#interface Ethernet0/0/2 eth-trunk 1 lacp priority 100#interface Ethernet0/0/3 eth-trunk 1#return

l Configuration file of S-switch-B# sysname S-switch-B## bpdu enableinterface Eth-Trunk1 mode lacp-static#interface Ethernet0/0/1 eth-trunk 1#interface Ethernet0/0/2 eth-trunk 1#interface Ethernet0/0/3 eth-trunk 1#return

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 2 LACP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

2-23

Page 82: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]
Page 83: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

3 VLAN Configuration

About This Chapter

This chapter describes the basics of Virtual Local Area Networks (VLANs) and the proceduresand examples for configuring VLANs.

3.1 IntroductionThis section describes the definition and functions of VLANs, references related to VLANs, andlogical relationships between configuration tasks.

3.2 Configuring a VLANThis section describes how to configure a VLAN.To device hosts on a same Ethernet networkinto different broadcast domains, you need to perform this task.

3.3 Adding Interfaces to a VLANThis section describes how to add access interfaces, QinQ interfaces, hybrid interfaces, and trunkinterfaces to a VLAN. To allow user packets to pass an interface, you need to perform this task.

3.4 Configuring VLANIF InterfacesThis section describes how to configure VLANIF interfaces. To implement interconnection atthe network layer through logical interfaces, you need to perform this task.

3.5 Configuring MAC Address-Based VLANsThis section describes how to configure MAC address-based VLANs. You can perform this taskto ensure the secure and flexible access of terminals.

3.6 Configuring a Management VLANThis section describes how to configure a management VLAN.

3.7 Configuration ExamplesThis section provides an example for configuring VLAN.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-1

Page 84: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

3.1 IntroductionThis section describes the definition and functions of VLANs, references related to VLANs, andlogical relationships between configuration tasks.

3.1.1 VLAN

3.1.2 VLAN Classification

3.1.3 VLAN Features Supported by the S-switch

3.1.4 Logical Relationships Between Configuration Tasks

3.1.1 VLAN

Definition

A Local Area Network (LAN) can be divided into several logical LANs. Each logical LAN isa broadcast domain, which is called a VLAN.

In VLAN networking, devices that need to communicate are classified into a VLAN; devicesthat do not need to communicate are classified into different VLANs.This isolates broadcastdomains, reduces broadcast storms, and improves the security of information.

Function

This isolates broadcast domains, reduces broadcast storms, and improves the security ofinformation.

With the expansion of network scales, faults on a local network impact the whole network.WithVLAN applied, faults can be confined to a VLAN. This improves the network robustness.

When multiple VLANs are required to isolate users, you can implement QinQ, that is, add a newVLAN tag to a packet. Through QinQ, up to 4094 x 4094 VLANs can be assigned.To providedifferent Quality of Service (QoS) for different users, you can identify the 802.1p priority inVLAN tags. For details, refer to the Quidway S2300 Series Ethernet Switches FeatureDescription-Ethernet.

3.1.2 VLAN Classification

The S-switch supports five types of VLAN classifications:l Classification of VLANs based on interfaces

VLAN members are defined according to interfaces on a device. An interface can forwardpackets of a VLAN after being added to the VLAN.

l Classification of VLANs based on MAC addressesVLAN members are defined according to source MAC addresses of packets. Packets areforwarded after being added with the VLAN tag.

By default, VLANs are classified based on binding policies, MAC addresses, IP subnets,protocols, and interfaces in sequence.

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 85: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

3.1.3 VLAN Features Supported by the S-switch

VLAN CapacityThe S-switch supports up to 4094 VLANs numbered 1 to 4094.

VLAN TypesThe S-switch supports interface-based VLANs, that is, the S-switch classifies a VLAN by addinginterfaces to the VLAN.

Types of VLAN LinksVLAN links are classified into the following:

l Access links, which connect user hosts and the S-switch

l Trunk links, which connect S-switches and the S-switches.

For detailed information about link types, refer to the Quidway S2300 Series EthernetSwitches Feature Description - Ethernet.

3.1.4 Logical Relationships Between Configuration Tasks

To classify devices that need to communicate into a VLAN and devices that do not need tocommunicate into different VLANs to ensure the security of the network.

perform the following tasks:

l 3.2 Configuring a VLAN

l 3.3 Adding Interfaces to a VLAN

l 3.4 Configuring VLANIF Interfaces

3.2 Configuring a VLANThis section describes how to configure a VLAN.To device hosts on a same Ethernet networkinto different broadcast domains, you need to perform this task.

3.2.1 Establishing the Configuration Task

3.2.2 (Optional) Creating a VLAN

3.2.3 (Optional) Creating VLANs in Batches

3.2.4 Checking the Configuration

3.2.1 Establishing the Configuration Task

Applicable EnvironmentThrough VLANs, hosts that do not need to communicate are isolated. VLANs improve networksecurity, reduce broadcast traffic, and suppress broadcast storms.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-3

Page 86: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Pre-configuration Tasks

None.

Data Preparation

To create a VLAN, you need the following data.

No. Data

1 VLAN ID

3.2.2 (Optional) Creating a VLAN

Context

Do as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:vlan vlan-id

A VLAN is created and the VLAN view is displayed.

NOTE

You can configure a management VLAN on the S-switch to forward Huawei Group Management Protocol(HGMP) packets. Using management VLANs in other scenarios is not recommended. By default, themanagement VLAN on the S-switch is VLAN 1.

For detailed information about management VLANs, refer to Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Network Management.

Step 3 (Optional) Run:description description

The description of the VLAN is set.

Setting VLAN description facilitates the management and memorization of the VLAN. Bydefault, the description of a VLAN indicates the VLAN ID. For example, the description ofVLAN 15 is "VLAN 0015."

----End

3.2.3 (Optional) Creating VLANs in Batches

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 87: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

the system view is displayed.

Step 2 Run:vlan batch { vlan-id1 [ to vlan-id2 ] }&<1-10>

VLANs are created in batches.

----End

3.2.4 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check information about aVLAN.

display vlan [ vlan-id [ verbose ] ]

Run the display vlancommand to check information about the VLANs created.

<Quidway> display vlanVLAN ID Type Status MAC Learning ---------------------------------------------------------- 1 common enable enable 4 common enable enable 7 common enable enable 8 common enable enable 9 common enable enable

Total vlan displayed = 5

Run the display vlan vlan-id verbose command to check whether the VLAN description iscorrect.

<Quidway> display vlan 4 verbose VLAN ID : 4 VLAN Type : Common Description : VLAN 0004 huawei Status : Enable Statistics : Disable

3.3 Adding Interfaces to a VLANThis section describes how to add access interfaces, QinQ interfaces, hybrid interfaces, and trunkinterfaces to a VLAN. To allow user packets to pass an interface, you need to perform this task.

3.3.1 Establishing the Configuration Task

3.3.2 Adding Access Interfaces to a VLAN

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-5

Page 88: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

3.3.3 (Optional) Adding Trunk Interfaces to a VLAN

3.3.4 (Optional) Adding Hybrid Interfaces to a VLAN

3.3.5 (Optional) Adding QinQ Interfaces to a VLAN

3.3.6 (Optional) Adding Interfaces to VLANs in Batches

3.3.7 Checking the Configuration

3.3.1 Establishing the Configuration Task

Applicable EnvironmentVLANs are classified according to interfaces. You can group interfaces that process the sametype of services into a VLAN. In this manner, interfaces that process different types of servicesare isolated. For example, interface 1 and interface 2 both connect to broadband access users;interface 3 connects to users of video services. In this case, interface 1 and interface 2 are groupedinto a VLAN; interface 3 is grouped into another VLAN.

Pre-configuration TasksBefore adding interfaces to a VLAN, complete the following task:

l 3.2 Configuring a VLAN

Data PreparationTo add interfaces to a VLAN, you need the following data.

No. Data

1 Types and Number of the interfaces to be added to a VLAN

2 VLAN IDs

3.3.2 Adding Access Interfaces to a VLAN

Context

Adding Access Interfaces to a VLAN

ContextDo as follows VLANIF interface on the S-switch.

Procedure

Step 1 Run:system-view

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 89: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:port link-type access

The interface type is set.

By default, the link type is hybrid.

Step 4 Run:quit

Return to the system view.

Step 5 Run:vlan vlan-id

The VLAN view is displayed.

Step 6 Run:port interface-type { interface-number1 [ to interface-number2 ] }&<1-10>

Access interfaces are added to their default VLAN.

----End

Configuring a Default VLAN for Interfaces

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:port link-type access

The interface type is set.

By default, the interface type is hybrid.

Step 4 Run:port default vlan vlan-id

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-7

Page 90: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The default VLAN of interfaces are set.

----End

3.3.3 (Optional) Adding Trunk Interfaces to a VLAN

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 (Optional) Run:port link-type trunk

The interface type is set to trunk.

By default, the interface type is hybrid.

Step 4 Run:port trunk allow-pass vlan { { vlan-id1 [ to vlan-id2 ] }&<1-10> | all }

Trunk interfaces are added to the VLAN.

----End

3.3.4 (Optional) Adding Hybrid Interfaces to a VLAN

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface number

The interface view is displayed.

Step 3 Run:port link-type hybrid

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 91: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The interface type is set to hybrid.

By default, the interface type is hybrid.

Step 4 Run:port default vlan vlan-id

The default VLAN of hybrid interfaces is set.

Or run (in the VLAN view):

port interface-type { interface-number1 [ to interface-number2 ] }&<1-10>

The default VLAN of the hybrid interface is set.

You can use this command to set the default VLAN for multiple hybrid interfaces.

Or run:

port trunk allow-pass vlan { { vlan-id1 [ to vlan-id2 ] }&<1-10> | all }

Hybrid interfaces are added to the VLAN in tagged mode.

Or run:

port hybrid untagged vlan { { vlan-id1 [ to vlan-id2 ] }&<1-10> | all }

Hybrid interfaces are added to the VLAN in untagged mode.

----End

3.3.5 (Optional) Adding QinQ Interfaces to a VLAN

Context

Adding QinQ Interfaces to a VLAN

ContextDo as follows on the S-switch.

NOTE

The S2300SI does not support QinQ interfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:port link-type dot1q-tunnel

The interface type is set.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-9

Page 92: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

By default, the interface type is hybrid.

Step 4 Run:quit

Return to the system view.

Step 5 Run:vlan vlan-id

The VLAN view is displayed.

Step 6 Run:port interface-type { interface-number1 [ to interface-number2 ] }&<1-10>

QinQ interfaces are added to the default VLAN of the interfaces.

----End

Configuring a Default VLAN for Interfaces

ContextDo as follows on the S-switch.

NOTE

The S2300SI does not support QinQ interfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:port link-type dot1q-tunnel

The interface type is set.

By default, the interface type is hybrid.

Step 4 Run:port default vlan vlan-id

The default VLAN of interfaces is set.

----End

3.3.6 (Optional) Adding Interfaces to VLANs in Batches

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-10 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 93: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Context

For the S-switches on the current network, interface numbers and VLAN IDs are regularlyrelated. In actual operation, to add multiple interfaces to a VLAN, you have to run the samecommand repeatedly, which is liable to make mistakes and lays a burden on users.

As shown in Figure 3-1, multiple interfaces are added to one VLAN or to different VLANs thatare regularly related. In this case, you can add interfaces to a VLAN or VLANs in batches toreduce users' repeated actions and improve devices' operability.

Figure 3-1 Networking of adding interfaces to a VLAN

VLAN1VLAN1 VLAN1 VLAN2VLAN1 VLAN3 VLAN20VLAN10 VLAN30

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:port-group port-group-name

An interface is added to an interface group and the interface group view is displayed.

Step 3 Run:port { default | hybrid untagged | trunk allow-pass } vlan vlan-id step step [ decreased | increased ]

The interface type is set.

By default, interfaces are added to VLANs in an ascending order.

Step 4 Run:quit

Return to the system view.

NOTE

l Interface types must be consistent with the parameters in the command. Otherwise, the system promptserrors.

l Parameters must be specified reasonably. Otherwise, the system prompts errors.

----End

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-11

Page 94: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

3.3.7 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check the VLAN to which aninterface is added.

display interface [ interface-type [ interface-number ] ]

Check information about aVLAN.

display vlan vlan-id

Run the display interface [ interface-type [ interface-number ] ] command. You can view thatGE 0/0/1 is added to VLAN 2.

<Quidway> display interface gigabitethernet 0/0/1GigabitEthernet2/0/1 current state : UPDescription : HUAWEI, Quidway Series, GigabitEthernet0/0/1 Interface, Switch PortPVID : 2The Maximum Transmit Unit is 1500 bytes Internet protocol processing : disabled IP Sending Frames' Format is PKTFMT_ETHNT_2, Hardware address is 0010-8300-0026NO AUTO NEGOTIATION, SPEED 1000M, DUPLEX FULL, LOOPBACK NOT SET; Transmitter's pause : enable, Receiver's pause : enable ; Last 300 seconds input rate: 82 bytes/sec, 1 packets/secLast 300 seconds output rate: 74 bytes/sec, 1 packets/sec Last 300 seconds Multicast input rate: 1 packets/sec Last 300 seconds Multicast output rate: 1 packets/sec Input: 16328 Packets, 1068290 Bytes 256 Broadcasts, 29 Multicasts 0 Oversizes, 0 Undersizes 0 FCSs, 0 PausesOutput: 16322 Packets, 1176245 Bytes 148 Broadcasts, 6 Multicasts 0 Oversizes, 0 Defers 0 FCSs, 0 Pauses 0 Collisions

Run the display vlan vlan-id command. You can view that GE 0/0/1 is added to VLAN 2.

<Quidway> display vlan 2VLAN ID Type Status MAC Learning ---------------------------------------------------------- 2 common enable enable ----------------Untagged Port: GigabitEthernet0/0/1----------------Interface PhysicalGigabitEthernet0/0/1 UP

3.4 Configuring VLANIF InterfacesThis section describes how to configure VLANIF interfaces. To implement interconnection atthe network layer through logical interfaces, you need to perform this task.

3.4.1 Establishing the Configuration Task

3.4.2 Creating a VLANIF Interface

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-12 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 95: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

3.4.3 Assigning IP Addresses to VLANIF Interfaces

3.4.4 (Optional) Setting the MTU of a VLANIF Interface

3.4.5 Checking the Configuration

3.4.1 Establishing the Configuration Task

Applicable Environmentl On the S-switch, you can create a logical interface for a VLAN, that is, a VLANIF interface.

A VLANIF interface is a network layer interface to which you can assign an IP address.The S-switch can communicate with other devices through the IP address of its VLANIFinterface.

l The S-switch supports static routes to implement the communication between devices indifferent VLANs.

Pre-configuration TasksBefore configuring VLANIF interfaces and static routes, complete the following task:l 3.2 Configuring a VLAN

Data PreparationTo configure VLANIF interfaces and static routes, you need the following data.

No. Data

1 ID of a VLAN

2 IP address of each VLANIF interface

3 Destination IP address, mask, and IP address of the next hop

3.4.2 Creating a VLANIF Interface

ContextDo as follows on the S-switch that needs to be configured with VLANIF interfaces.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface vlanif vlan-id

A VLANIF interface is created and the VLANIF interface view is displayed.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-13

Page 96: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The S-switch supports only one VLANIF interface.

----End

3.4.3 Assigning IP Addresses to VLANIF Interfaces

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface vlanif vlan-id

A VLANIF interface is created and the VLANIF interface view is displayed.

Step 3 Run:ip address ip-address { mask | mask-length } [ sub ]

An IP address is assigned to the VLANIF interface.

----End

3.4.4 (Optional) Setting the MTU of a VLANIF Interface

ContextNOTE

l After changing the maximum transmission unit (MTU) by using the mtu command on a specifiedinterface, you need to restart the interface to make the new MTU take effect. To restart the interface,run the shutdown command and then the undo shutdown command.

l If you change the MTU of an interface, you need to change the MTU of the peer interface to the samevalue by using the mtu command; otherwise, services may be interrupted.

l To ensure availability of Layer 3 functions, set the MTU value of the VLANIF interface to be smallerthan the maximum length of frames on the physical interface in the corresponding VLAN.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface vlanif vlan-id

The VLANIF interface view is displayed.

Step 3 Run:

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-14 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 97: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

mtu mtu

The MTU of the VLANIF interface is set.

The MTU of a VLANIF interface ranges from 46 to 2000, in bytes. The default value is 1500.

NOTEIf the MTU is too small whereas the packet size is large, the packet is probably split into many fragments.Therefore, the packet may be discarded due to the insufficient QoS queue length. To avoid this situation,lengthen the QoS queue accordingly.

----End

3.4.5 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check the status and basicconfiguration of a VLANIFinterface.

display interface vlanif [ vlan-id ] [ verbose ] [ |{ begin | exclude | include } regular-expression ]

Check the routing table. display ip routing-table protocol { direct | static }[ inactive | verbose ]

After the configuration succeeds, the following results can be obtained with the precedingcommands:

l The IP address of the VLANIF interface is correct.

l The static route is properly configured.

3.5 Configuring MAC Address-Based VLANsThis section describes how to configure MAC address-based VLANs. You can perform this taskto ensure the secure and flexible access of terminals.

3.5.1 Establishing the Configuration Task

3.5.2 Relating a MAC Address with a VLAN

3.5.3 Allowing Packets of the MAC Address-based VLAN to Pass Through the Interface

3.5.4 Enabling MAC Address-Based VLAN Classification

3.5.5 (Optional) Setting the Precedence for VLAN Matching

3.5.6 Checking the Configuration

3.5.1 Establishing the Configuration Task

Applicable EnvironmentMAC address-based VLANs need not to be reconfigured when the physical addresses of terminalusers change. This improves the security of terminal users and ensures the flexible access.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-15

Page 98: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

The S2300SI does not support VLAN assignment based on MAC addresses.

Pre-configuration TasksNone.

Data PreparationTo configure a MAC address-based VLAN, you need the following data.

No. Data

1 VLAN ID

2 VLAN-related MAC address

3 Type and number of the interface where a MAC address-based VLAN isconfigured

3.5.2 Relating a MAC Address with a VLAN

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:vlan vlan-id

A VLAN is created and the VLAN view is displayed.

Step 3 Run:mac-vlan mac-address mac-address

The MAC address is related with the VLAN.

----End

3.5.3 Allowing Packets of the MAC Address-based VLAN to PassThrough the Interface

ContextDo as follows on the S-switch.

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-16 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 99: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:port link-type hybrid

The link type is set to hybrid.

By default, the interface type is hybrid.

MAC address-based VLANs can be configured only on hybrid interfaces.

Step 4 Run:port hybrid untagged vlan vlan-id

The packets with the VLAN tag are permitted to pass the current interface.

----End

3.5.4 Enabling MAC Address-Based VLAN Classification

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:mac-vlan enable

MAC address-based VLAN classification is enabled.

By default, MAC address-based VLAN classification is disabled.

----End

3.5.5 (Optional) Setting the Precedence for VLAN Matching

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-17

Page 100: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Context

Do as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:vlan precedence { mac-vlan | ip-subnet-vlan }

The precedence is set for VLAN matching.

By default, the S-switch matches a VLAN according to the MAC address preferentially.

----End

3.5.6 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check the entries in a MAC-VLAN table.

display mac-vlan { all | mac-address mac-address | vlanvlan-id }

Run the display mac-vlan command to check whether the MAC address is correctly related tothe VLAN.

<Quidway> display mac-vlan all--------------------------------------------- MAC Address VLAN Type ---------------------------------------------- 0002-0002-0002 2 static

Total MAC VLAN address count: 1

3.6 Configuring a Management VLANThis section describes how to configure a management VLAN.

3.6.1 Establishing the Configuration Task

3.6.2 Configuring a Management VLAN

3.6.3 Checking the Configuration

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-18 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 101: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

3.6.1 Establishing the Configuration Task

Applicable Environment

By configuring a VLAN as a management VLAN, you can control the type of the interface addedto this VLAN. Generally, the VLANIF interface corresponding to the management VLAN isused to log in to the management device.

Pre-configuration Tasks

Before configuring a management VLAN, complete the following task:

l Creating a VLAN

Data Preparation

To configure a management VLAN, you need the following data.

No. Data

1 VLAN ID

3.6.2 Configuring a Management VLAN

Context

Do as follows on the S-switch where you need to configure a management VLAN.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:vlan vlan-id

A VLAN is created and the VLAN view is displayed.

Step 3 Run:management-vlan

The VLAN is configured as a management VLAN.

----End

3.6.3 Checking the Configuration

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-19

Page 102: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run the display vlan command to check the configuration of the management VLAN.

----End

ExampleRun the display vlan command, and you can view the configuration of VLANs. The VLANmarked with * is the management VLAN. For example:

<Quidway> display vlanVLAN ID Type Status MAC Learning --------------------------------------1 common enable enable 93 common enable enable 95 common enable enable 1000 *common enable enable * : management-vlan

3.7 Configuration ExamplesThis section provides an example for configuring VLAN.

3.7.1 Example for Configuring Trunk Links on the S-switch

3.7.2 Example for Configuring VLAN Integration

3.7.1 Example for Configuring Trunk Links on the S-switch

Networking RequirementsAs shown in Figure 3-2, an enterprise is composed of four departments. Department 1 isconnected to Ethernet 0/0/1 on the S-switch through DSLAM-A. Department 2 is connected toEthernet 0/0/2 on the S-switch through LSW-A. Department 3 is connected to Ethernet 0/0/3 onthe S-switch through LSW-B. Department 4 is connected to Ethernet 0/0/4 on the S-switchthrough DSLAM-B. The networking requirements are as follows:

l Department 1 and Department 2 in VLAN 2 are isolated from Department 3 and Department4 in VLAN 3.

l Department 1 and Department 2 in VLAN 2 can communicate with each other.

l Department 3 and Department 4 in VLAN 3 can communicate with each other.

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-20 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 103: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Figure 3-2 Networking diagram for configuring trunk links on the S-switch

Metro

Eth0/0/1

VLAN 3

Eth0/0/2 Eth0/0/3

Eth0/0/4

VLAN 2

Configuration RoadmapThe configuration roadmap is as follows:

1. Create a VLAN.2. Add interfaces to the VLAN.

Data PreparationTo complete the configuration, you need the following data:

l Ethernet 0/0/1 and Ethernet 0/0/2, which belong to VLAN 2

l Ethernet 0/0/3 and Ethernet 0/0/4, which belong to VLAN 3

Configuration ProcedureThe following provides only the configurations on the S-switch. For the configurations on otherdevices in Figure 3-2, refer to the manuals of other devices.

1. Configure the S-switch.# Create VLAN 2.<Quidway> system-view[Quidway] vlan 2[Quidway-vlan2] quit# Set the link type of Ethernet 0/0/1 to trunk and add Ethernet 0/0/1 to VLAN 2.[Quidway] interface ethernet 0/0/1[Quidway-Ethernet0/0/1] port link-type trunk

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-21

Page 104: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

[Quidway-Ethernet0/0/1] port trunk allow-pass vlan 2[Quidway-Ethernet0/0/1] quit

# Set the link type of Ethernet 0/0/2 to trunk and add Ethernet 0/0/2 to VLAN 2.[Quidway] interface ethernet 0/0/2[Quidway-Ethernet0/0/2] port link-type trunk[Quidway-Ethernet0/0/2] port trunk allow-pass vlan 2[Quidway-Ethernet0/0/2] quit

# Create VLAN 3.[Quidway] vlan 3[Quidway-vlan3] quit

# Set the link type of Ethernet 0/0/3 to trunk and add Ethernet 0/0/3 to VLAN 3.[Quidway] interface ethernet 0/0/3[Quidway-Ethernet0/0/3] port link-type trunk[Quidway-Ethernet0/0/3] port trunk allow-pass vlan 3[Quidway-Ethernet0/0/3] quit

# Set the link type of Ethernet 0/0/4 to trunk and add Ethernet 0/0/4 to VLAN 3.[Quidway] interface ethernet 0/0/4[Quidway-Ethernet0/0/4] port link-type trunk[Quidway-Ethernet0/0/4] port trunk allow-pass vlan 3[Quidway-Ethernet0/0/4] quit

2. Verify the configuration.No host in VLAN 2, which Department 1 and Department 2 belong to, can successfullyping any host in VLAN 3, which Department 3 and Department 4 belong to. This showsthat Department 1 and Department 2 are isolated from Department 3 and Department 4.Each host of Department 1 can successfully ping any host of Department 2. This showsthat Department 1 is interconnected with Department 2.Each host of Department 3 can also successfully ping any host of Department 4. This showsthat Department 3 is interconnected with Department 4.

Configuration Files

The following lists the configuration files of the S-switch.

# sysname Quidway#vlan batch 2 to 3#interface Ethernet0/0/1 port link-type trunk port trunk allow-pass vlan 2#interface Ethernet0/0/2 port link-type trunk port trunk allow-pass vlan 2#interface Ethernet0/0/3 port link-type trunk port trunk allow-pass vlan 3#interface Ethernet0/0/4 port link-type trunk port trunk allow-pass vlan 3#return

3.7.2 Example for Configuring VLAN Integration

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-22 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 105: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Networking Requirements

As shown in Figure 3-3, User 1 and User 2 are connected to S-switch-A through Ethernet 0/0/1and Ethernet 0/0/2 on a LAN switch; User 3 and User 4 are connected to S-switch-B throughEthernet 0/0/3 and Ethernet 0/0/4 on another LAN switch. The networking requirements are asfollows:

l Each host in VLAN 2 can communicate with any host in VLAN 3.

Figure 3-3 Networking diagram for configuring VLAN integration

S-switch-A

Eth0/0/1 Eth0/0/3

172.16.0.2/16 172.17.0.2/16

Eth0/0/2 Eth0/0/4

172.16.0.1/16 172.17.0.1/16

S-switch-BEth0/0/5 Eth0/0/6

VLAN4VLAN3VLAN2

Configuration Roadmap

The configuration roadmap is as follows:

1. Create VLANs on S-switch-A and S-switch-B and add interfaces on S-switch-A and S-switch-B to the VLANs.

2. Create VLANIF interfaces on S-switch-A and S-switch-B and assign IP addresses to theVLANIF interfaces.

3. Configure static routes on S-switch-A and S-switch-B.

Data Preparation

To complete the configuration, you need the following data:

l Ethernet 0/0/1 and Ethernet 0/0/2, which belong to VLAN 2

l Ethernet 0/0/3 and Ethernet 0/0/4, which belong to VLAN 3

l Ethernet 0/0/5 and Ethernet 0/0/6, which belong to VLAN 4

l IP address of VLANIF 2 on S-switch-A, which is 10.10.1.1/24

l IP address of VLANIF 4 on S-switch-A, which is 10.10.20.1/24

l IP address of VLANIF 3 on S-switch-B, which is 10.10.2.1/24

l IP address of VLANIF 4 on S-switch-B, which is 10.10.20.2/24

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-23

Page 106: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Configuration ProcedureThe following provides only the configurations on the S-switch. For the configurations on otherdevices in Figure 3-3, refer to the manuals of other devices.

1. Create VLANs and add interfaces to the corresponding VLANs.# Create VLAN 2 on S-switch-A.<Quidway> system-view[Quidway] sysname S-switch-A[S-switch-A] vlan 2[S-switch-A-vlan2] quit# Add Ethernet 0/0/1 and Ethernet 0/0/2 to VLAN 2.[S-switch-A] interface ethernet 0/0/1[S-switch-A-Ethernet0/0/1] port link-type trunk[S-switch-A-Ethernet0/0/1] port trunk allow-pass vlan 2[S-switch-A-Ethernet0/0/1] quit[S-switch-A] interface ethernet 0/0/2[S-switch-A-Ethernet0/0/2] port link-type trunk[S-switch-A-Ethernet0/0/2] port trunk allow-pass vlan 2[S-switch-A-Ethernet0/0/2] quit# Create VLAN 4 on S-switch-A.[S-switch-A] vlan 4# Add Ethernet 0/0/5 to VLAN 4.[S-switch-A-vlan4] port ethernet 0/0/5[S-switch-A-vlan4] quit# Create VLAN 3 on S-switch-B.<Quidway> system-view[Quidway] sysname S-switch-B[S-switch-B] vlan 3[S-switch-B-vlan3] quit# Add Ethernet 0/0/3 and Ethernet 0/0/4 to VLAN 3.[S-switch-B] interface ethernet 0/0/3[S-switch-B-Ethernet0/0/3] port link-type trunk[S-switch-B-Ethernet0/0/3] port trunk allow-pass vlan 3[S-switch-B-Ethernet0/0/3] quit[S-switch-B] interface ethernet 0/0/4[S-switch-B-Ethernet0/0/4] port link-type trunk[S-switch-B-Ethernet0/0/4] port trunk allow-pass vlan 3[S-switch-B-Ethernet0/0/4] quit# Create VLAN 4 on S-switch-B.[S-switch-B] vlan 4# Add Ethernet 0/0/6 to VLAN 4.[S-switch-B-vlan4] port ethernet 0/0/6[S-switch-B-vlan4] quit

2. Create VLANIF interfaces and assign IP addresses to the VLANIF interfaces.# Create VLANIF 2 on S-switch-A.[S-switch-A] interface vlanif 2# Assign the IP address of 10.10.1.1/24 to VLANIF 2.[S-switch-A-Vlanif2] ip address 10.10.1.1 24[S-switch-A-Vlanif2] quit# Create VLANIF 4 on S-switch-A.[S-switch-A] interface vlanif 4# Assign the IP address of 10.10.20.1/24 to VLANIF 4.[S-switch-A-Vlanif4] ip address 10.10.20.1 24

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-24 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 107: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

[S-switch-A-Vlanif4] quit# Create VLANIF 3 on S-switch-B.[S-switch-B] interface vlanif 3# Assign the IP address of 10.10.2.1/24 to VLANIF 3.[S-switch-B-Vlanif3] ip address 10.10.2.1 24[S-switch-B-Vlanif3] quit# Create VLANIF 4 on S-switch-B.[S-switch-B] interface vlanif 4# Assign the IP address of 10.10.20.2/24 to VLANIF 4.[S-switch-B-Vlanif4] ip address 10.10.20.2 24[S-switch-B-Vlanif4] quit

3. Configure static routes.# Configure a static route on S-switch-A with the destination IP address as 10.10.2.0, themask as 255.255.255.0, and the IP address of the next hop as 10.10.20.2.[S-switch-A] ip route-static 10.10.2.0 255.255.255.0 10.10.20.2# Configure a static route on S-switch-B with the destination IP address as 10.10.1.0, themask as 255.255.255.0, and the IP address of the next hop as 10.10.20.1.[S-switch-B] ip route-static 10.10.1.0 255.255.255.0 10.10.20.1

4. Verify the configuration.Ping any host in VLAN 2 from any host in VLAN 3. If the ping operations succeed, itindicates that the configuration succeeds.Ping any host in VLAN 3from any host in VLAN 2. If the ping operations succeed, itindicates that the configuration succeeds.

Configuration FilesThe following lists the configuration files of the S-switch.

l Configuration files of S-switch-A# sysname S-switch-A#vlan batch 2 4#interface Vlanif2 ip address 10.10.1.1 255.255.255.0#interface Vlanif4 ip address 10.10.20.1 255.255.255.0#interface Ethernet0/0/1 port link-type trunkport trunk allow-pass vlan 2#interface Ethernet0/0/2 port link-type trunkport trunk allow-pass vlan 2#interface Ethernet0/0/5 port default vlan 4#ip route-static 10.10.2.0 255.255.255.0 10.10.20.2#return

l Configuration files of S-switch-B# sysname S-switch-B

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 3 VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

3-25

Page 108: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

#vlan batch 3 4#interface Vlanif3 ip address 10.10.2.1 255.255.255.0#interface Vlanif4 ip address 10.10.20.2 255.255.255.0#interface Ethernet0/0/3 port link-type trunkport trunk allow-pass vlan 3#interface Ethernet0/0/4 port link-type trunkport trunk allow-pass vlan 3#interface Ethernet0/0/6 port default vlan 4#ip route-static 10.10.1.0 255.255.255.0 10.10.20.1#return

3 VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

3-26 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 109: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

4 VLAN Aggregation Configuration

About This Chapter

This chapter describes the basics, methods, and examples for configuring VLAN aggregation.

4.1 IntroductionThis section describes the concepts of VLAN aggregation and VLAN aggregation featuressupported by the S-switch.

4.2 Configuring VLAN AggregationThis section describes how to configure VLAN aggregation. You can perform this task to enablemultiple VLANs to share an IP address. This can save IP addresses.

4.3 Configuration ExamplesThis section provides configuration examples for VLAN aggregation.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 4 VLAN Aggregation Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

4-1

Page 110: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

4.1 IntroductionThis section describes the concepts of VLAN aggregation and VLAN aggregation featuressupported by the S-switch.

4.1.1 Concept of VLAN Aggregation

4.1.2 VLAN Aggregation Supported by the S-switch

4.1.3 Logical Relationships Between Configuration Tasks

4.1.1 Concept of VLAN Aggregation

To interconnect VLANs on the S-switch, you need to assign an IP address to each VLANIFinterface. If there is a large number of VLANs, many IP addresses are used. VLAN aggregationcan solve the problem that each VLAN interface uses an IP address.

An aggregated VLAN is also called a super VLAN. Multiple VLANs can be aggregated to asuper VLAN. The VLANs that form into a super VLAN are called sub VLANs.

4.1.2 VLAN Aggregation Supported by the S-switch

Super VLANs and Sub VLANs

Each super VLAN supports up to 16 sub VLANs.

A sub VLAN does not need a separate subnet segment. In a super VLAN, the IP address of ahost is in the subnet segment corresponding to the super VLAN, irrespective of the sub VLANthat the host belongs to.

Different from a common VLAN, a super VLAN includes only Layer 3 interfaces rather thanphysical interfaces. A super VLAN is also different from a VLAN without physical interfaces.The Layer 3 virtual interface of a super VLAN is Up when the sub VLANs of the super VLANhas physical interfaces that are in the Up state.

A sub VLAN has only physical interfaces. VLANIF interfaces cannot be set up in a sub VLAN.The Layer 3 switching between a sub VLAN and other sub VLANs and networks is implementedthrough the VLANIF interfaces of the super VLAN.

Sub VLAN Communications

To implement Layer 3 communications in a sub VLAN, users can use the IP address of theVLANIF interface of the super VLAN as the gateway address.

To implement Layer 3 interconnections between a sub VLAN with another sub VLAN or othernetworks, you need to use the Address Resolution Protocol (ARP) proxy function. After ARPproxy is enabled, ARP request and response packets can be forwarded and processed. This canimplement Layer 3 interconnection between isolated interfaces at Layer 2. By default, ARPproxy is disabled in sub VLANs.

4 VLAN Aggregation ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

4-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 111: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

4.1.3 Logical Relationships Between Configuration TasksThe configuration tasks in this chapter are independent. You can perform the task in the orderat your desire.

4.2 Configuring VLAN AggregationThis section describes how to configure VLAN aggregation. You can perform this task to enablemultiple VLANs to share an IP address. This can save IP addresses.

4.2.1 Establishing the Configuration Task

4.2.2 Configuring Sub VLANs

4.2.3 Configuring a Super VLAN

4.2.4 Assigning IP Addresses to VLANIF Interfaces

4.2.5 Enabling ARP Proxy in the Super-VLAN

4.2.6 Checking the Configuration

4.2.1 Establishing the Configuration Task

Applicable Environment

When a large number of VLANs exists in the network, you can configure VLAN aggregationto simplify configuration and facilitate network planning.

NOTE

S2300SI does not support VLAN aggregation.

Pre-configuration Tasks

Before configuring VLAN aggregation, complete the following task:l 1.2 Configuring Basic Attributes of Ethernet Interfaces

Data Preparation

To configure VLAN aggregation, you need the following data.

No. Data

1 Sub VLAN IDs and interface numbers

2 Super VLAN ID

3 IP address and mask of the VLANIF interface

4.2.2 Configuring Sub VLANs

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 4 VLAN Aggregation Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

4-3

Page 112: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

ContextDo as follows on the S-switch that needs to be configured with VLAN aggregation.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:vlan vlan-id

A VLAN is created and the VLAN view is displayed.

Step 3 Run:port interface-type { interface-number1 [ to interface-number2 ] }&<1-10>

Interfaces are added to sub VLANs.

By default, a newly created VLAN functions the same as a sub VLAN.

To configure a sub VLAN, add interfaces to the created VLAN.

----End

4.2.3 Configuring a Super VLAN

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:vlan vlan-id

A VLAN is created and the VLAN view is displayed.

Step 3 Run:aggregate-vlan

A created VLAN is set as a super VLAN.

NOTE

l The ID of the super VLAN must differ from that of sub VLANs. The supper VLAN cannot containany physical interfaces.

l Using the undo aggregate-vlan command in the VLAN view, you can change a super VLAN interfaceto a sub VLAN interface.

Step 4 Run:

4 VLAN Aggregation ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

4-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 113: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

access-vlan { vlan-id1 [ to vlan-id2 ] } &<1-10>

A sub VLAN is added to a super VLAN.

----End

4.2.4 Assigning IP Addresses to VLANIF Interfaces

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface vlanif vlan-id

A VLANIF interface is created.

You can create VLANIF interfaces for super VLANs rather than sub VLANs. Therefore, vlan-id specifies the ID of a super VLAN.

Step 3 Run:ip address ip-address { mask | mask-length }

An IP address is assigned to the VLANIF interface.

NOTE

The network segment that contains the IP address of the VLANIF interface must also contain subnetsegments of sub VLAN users.

----End

4.2.5 Enabling ARP Proxy in the Super-VLAN

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface vlanif vlan-id

A VLANIF interface is created for super VLANs.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 4 VLAN Aggregation Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

4-5

Page 114: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Step 3 Run:arp-proxy enable

ARP proxy is enabled on the VLANIF interface.

Step 4 Run:arp-proxy inter-sub-vlan-proxy enable

ARP proxy between sub VLANs is enabled.

----End

4.2.6 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Display VLANinformation.

display vlan [ vlan-id [ verbose ] ]

Display informationabout the VLANIFinterface.

display interface vlanif [ vlan-id ] [ verbose ] [ | { begin |exclude | include } regular-expression ]

Run the display vlan command. You can view the VLAN type and sub VLAN configuration.Take VLAN 2 as an example:

<Quidway> display vlan 2 verbose VLAN ID : 2 VLAN Type : Super Description : VLAN 0002 Status : Enable Statistics : Disable---------------sub-VLAN List: 3-10

Run the display interface vlanif command. You can view whether the VLANIF interface isproperly configured.

<Quidway> display interface vlanif 2Vlanif2 current state : UPLine protocol current state : UPDescription : Huawei, Quidway Series, Vlanif2 Interface, Route PortThe Maximum Transmit Unit is 1500 bytesInternet Address is 100.1.1.1/24IP Sending Frames' Format is PKTFMT_ETHNT_2, Hardware address is 0200-0000-f500

Last 300 seconds input rate: 1 packets/secLast 300 seconds output rate: 1 packets/sec

Input: 94053 Packets, 58513 Unicasts 17109 Broadcasts, 18431 Multicasts

Output: 57973 Packets, 57973 Unicasts 0 Broadcasts, 0 Multicasts

4 VLAN Aggregation ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

4-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 115: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

4.3 Configuration ExamplesThis section provides configuration examples for VLAN aggregation.

4.3.1 Example for Configuring VLAN Aggregation

4.3.1 Example for Configuring VLAN Aggregation

Networking RequirementsAs shown in Figure 4-1, the S-switch is connected to PC 1, PC 2, PC 3, and PC 4 throughEthernet 0/0/1, Ethernet 0/0/2, Ethernet 0/0/3, and Ethernet 0/0/4. It is required that VLAN 2and VLAN 3 should be able to communicate with each other at Layer 3 after ARP proxy isenabled.

Figure 4-1 Networking diagram for configuring VLAN aggregation

S-switch

VLAN2 VLAN3

VLAN4

PC1 PC2 PC3 PC4

Ethernet 0/0/1Ethernet 0/0/2 Ethernet 0/0/3

Ethernet 0/0/4

Configuration RoadmapThe configuration roadmap is as follows:

1. Create sub VLANs.2. Aggregate sub VLANs to a super VLAN.3. Create super VLANs,add sub VLAN into super VLAN.4. Assign IP Addresses to VLANIF interfaces.5. Enable ARP proxy between sub VLANs.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 4 VLAN Aggregation Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

4-7

Page 116: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

PC 1, PC 2, PC 3, and PC 4 must be assigned with IP addresses that are in the same network segment withVLAN 4.

Data PreparationTo complete the configuration, you need the following data:l Sub VLAN IDs, which are 2 and 3, and super VLAN ID, which is 4

l Ethernet 0/0/1 and Ethernet 0/0/2 belonging to VLAN 2

l Ethernet 0/0/3 and Ethernet 0/0/4 belonging to VLAN 3

l IP address of the super VLAN, which is 10.10.10.1

Configuration Procedure1. Create sub VLAN 2.

<S-switch> system-view[S-switch] vlan 2

2. Add Ethernet 0/0/1 and Ethernet 0/0/2 to VLAN 2.[S-switch-vlan2] port ethernet 0/0/1 0/0/2[S-switch-vlan2] quit

3. Create sub VLAN 3.[S-switch] vlan 3

4. Add Ethernet 0/0/3 and Ethernet 0/0/4 to VLAN 3.[S-switch-vlan3] port ethernet 0/0/3 0/0/4[S-switch-vlan3] quit

5. Create super VLAN 4,add sub vlan2 and sub vlan3 into super vlan[S-switch] vlan 4[S-switch-vlan4] aggregate-vlan[S-switch-vlan4] access-vlan 2 to 3[S-switch-vlan4] quit

6. Assign the IP address of 10.10.10.1 to the super VLAN.[S-switch] interface vlanif 4[S-switch-Vlanif4] ip address 10.10.10.1 255.255.255.0

7. Enable ARP proxy.[S-switch-Vlanif4] arp-proxy inter-sub-vlan-proxy enable

8. Verify the configuration.The PCs in VLAN 2 and VLAN 3 can communicate with each other at Layer 3.

Configuration FilesThe following lists the configuration files of the S-switch.

# sysname S-switch# vlan batch 2 to 4#vlan 4 aggregate-vlan access-vlan 2 to 3#interface Vlanif4 ip address 10.10.10.1 255.255.255.0

4 VLAN Aggregation ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

4-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 117: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

arp-proxy inter-sub-vlan-proxy enable#interface Ethernet0/0/1 port default vlan 2#interface Ethernet0/0/2 port default vlan 2#interface Ethernet0/0/3 port default vlan 3#interface Ethernet0/0/4 port default vlan 3#return

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 4 VLAN Aggregation Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

4-9

Page 118: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]
Page 119: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

5 VLAN Mapping Configuration

About This Chapter

This chapter describes the basics, configuration methods, and configuration examples of VLANmapping.

5.1 Introduction to VLAN MappingThis section describes the concepts of VLAN mapping and the VLAN mapping featuressupported by the S-switch.

5.2 Configuring VLAN MappingThis section describes how to configure VLAN mapping.

5.3 Configuration ExamplesThis section provides several examples for configuring VLAN Mapping.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 5 VLAN Mapping Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

5-1

Page 120: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

5.1 Introduction to VLAN MappingThis section describes the concepts of VLAN mapping and the VLAN mapping featuressupported by the S-switch.

5.1.1 VLAN Mapping Overview

5.1.2 VLAN Mapping Features Supported by the S-switch

5.1.1 VLAN Mapping Overview

DefinitionVLAN mapping is used to implement the mapping between Customer-VLAN (C-VLAN) tagsand Service-VLAN (S-VLAN) tags by replacing the outer VLAN tags of data frames. In thismanner, VLAN convergence is implemented; thus, services are transmitted according to theprovider's network planning.

BackgroundIn the metropolitan Ethernet network shown in Figure 5-1, services such as Internet, IPTV, andVoIP of home users are transmitted through different VLANs. The number of VLANs in thenetwork of the provider, however, is limited; therefore, VLAN convergence needs to beperformed on the switch at the access layer. Thus, the same services of different customers sentthrough different VLANs can be sent through the same VLAN.

5 VLAN Mapping ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

5-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 121: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Figure 5-1 Networking diagram of VLAN mapping

MSTP

MetroEthernet

InternetInternetInternetInternet

SoftX Head-end

VOD ServerInternet

VLAN10 VLAN11 VLAN12 VLAN13 VLAN14 VLAN15

VLAN10->VLAN100VLAN11->VLAN101VLAN12->VLAN102

VLAN13->VLAN100VLAN14->VLAN101VLAN15->VLAN102

HG

HG:Home Gateway

HG

5.1.2 VLAN Mapping Features Supported by the S-switch

Mapping ModeThe S-switch maps the outermost C-VLAN tag carried in a received packet to the S-VLAN tagbased on the interface and the C-VLAN; the S-switch maps the outermost S-VLAN tag carriedin a packet to be sent to the C-VLAN tag based on the S-VLAN and destination MAC address.

The S-switch supports 1:1 mapping and n:1 mapping.

l 1:1 VLAN mappingMap a C-VLAN tag to an S-VLAN tag or map an S-VLAN tag to a C-VLAN tag.

l N:1 VLAN mappingMap multiple C-VLAN tags to an S-VLAN tag.

Transparent TransmissionOn an interface enabled with VLAN mapping, VLAN mapping is not implemented for the packetwhose VLAN does not match any VLAN mapping entry. Instead, the packet is transparentlytransmitted to the outbound interface.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 5 VLAN Mapping Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

5-3

Page 122: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

You can run the port vlan-stacking push command, the transparent transmission function of VLANmapping does not take effect. In this case, the packet whose VLAN does not match any VLAN mappingentry is forwarded in the default VLAN configured on the interface.

Specification

After an interface is configured with VLAN mapping, the interface can be connected to amaximum of 16 customers.

5.2 Configuring VLAN MappingThis section describes how to configure VLAN mapping.

5.2.1 Establishing the Configuration Task

5.2.2 Creating an S-VLAN and a C-VLAN

5.2.3 Configuring the Type of an Interface Type as Hybrid

5.2.4 Adding Interfaces to an S-VLAN

5.2.5 Enabling Selective QinQ on an Interface

5.2.6 (Optional) Configuring an Interface to Trust the 802.1p Priorities Carried in Packets

5.2.7 Configuring VLAN Mapping

5.2.8 Checking the Configuration

5.2.1 Establishing the Configuration Task

Applicable Environment

In the metropolitan Ethernet network, services such as Internet, IPTV, and VoIP of home usersare transmitted through different VLANs. The number of VLANs in S-VLAN, however, islimited; therefore, VLAN mapping needs to be performed on the switch at the access layer. Thus,the same services of different users sent by different VLANs can be sent by the same VLAN.

NOTE

S2300SI does not support VLAN mapping.

Pre-configuration Tasks

None.

Data Preparation

To configure VLAN mapping, you need the following data.

No. Data

1 Number of the interface configured with VLAN mapping

5 VLAN Mapping ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

5-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 123: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

No. Data

2 IDs of C-VLANs

3 IDs of S-VLANs

5.2.2 Creating an S-VLAN and a C-VLAN

ContextDo as follows on the S-switch that needs to be configured with VLAN mapping.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:vlan batch { vlan-id1 [ to vlan-id2 ] }&<1-10>

S-VLANs are created in batches.

Step 3 Run:vlan batch { vlan-id1 [ to vlan-id2 ] }&<1-10>

C-VLANs are created in batches.

----End

5.2.3 Configuring the Type of an Interface Type as Hybrid

ContextDo as follows on the S-switch that needs to be configured with VLAN mapping.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The view of the interface at the customer side is displayed.

Step 3 Run:port link-type hybrid

The type of the interface is set to hybrid.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 5 VLAN Mapping Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

5-5

Page 124: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

By default, the type of the interface is hybrid.

NOTE

On the S-switch, VLAN mapping can be configured on hybrid interfaces only.

----End

5.2.4 Adding Interfaces to an S-VLAN

Context

Do as follows on the S-switch that needs to be configured with VLAN mapping.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The view of the interface at the customer side is displayed.

Step 3 Run:port trunk allow-pass vlan { { vlan-id1 [ to vlan-id2 ] }&<1-10> | all }

The interface at the customer side is added to the S-VLAN.

Step 4 Run:quit

Exit from the view of the interface at the customer side.

Step 5 Run:interface interface-type interface-number

The view of the interface at the network side is displayed.

Step 6 Run:port trunk allow-pass vlan { { vlan-id1 [ to vlan-id2 ] }&<1-10> | all }

The interface at the network side is added to the S-VLAN.

----End

5.2.5 Enabling Selective QinQ on an Interface

Context

Do as follows on the S-switch that needs to be configured with VLAN mapping.

5 VLAN Mapping ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

5-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 125: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The view of the interface at the customer side is displayed.

Step 3 Run:qinq vlan-translation enable

Selective QinQ is enabled on the interface.

By default, selective QinQ is disabled on the interface.

----End

5.2.6 (Optional) Configuring an Interface to Trust the 802.1pPriorities Carried in Packets

Context

When 5.2.7 Configuring VLAN Mapping and configuring the S-VLAN to inherit the priorityof the C-LVAN, configure an interface to trust the 802.1p priorities carried in packets

Do as follows on the S-switch that needs to be configured with VLAN mapping.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The view of the interface at the customer side is displayed.

Step 3 Run:trust 8021p

The interface is configured to trust the 802.1p priorities carried in received packets.

By default, the interface does not trust the 802.1p priorities carried in received packets.

----End

5.2.7 Configuring VLAN Mapping

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 5 VLAN Mapping Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

5-7

Page 126: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Context

If the S-VLAN inherits the priority of the C-VLAN when the C-VLAN tag is mapped to the S-VLAN tag, perform the action of 5.2.6 (Optional) Configuring an Interface to Trust the802.1p Priorities Carried in Packets before configuring VLAN mapping.

Do as follows on the S-switch that needs to be configured with VLAN mapping.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The view of the interface at the customer side is displayed.

Step 3 Run:port vlan-mapping external-vlan vlan-id1 [ to vlan-id2 ] map-external-vlan vlan-id3

VLAN mapping is configured and the mapping between C-VLANs and S-VLANs is set up.

l vlan-id1 specifies the start C-VLAN ID to be replaced.

l vlan-id2 specifies the end C-VLAN ID to be replaced.

l vlan-id3 specifies the S-VLAN ID.

----End

5.2.8 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check the configuration ofVLAN mapping on an interface.

display current-configuration interface interface-typeinterface-number

Run the display current-configuration interface command in any view, and you can checkwhether VLAN mapping is correctly configured on the interface. In this example, C-VLANs 13and 14 are mapped to S-VLAN 100, and C-VLAN 15 is mapped to S-VLAN 101 on Ethernet0/0/2.

<Quidway> display current-configuration interface ethernet 0/0/2#interface Ethernet0/0/2 port trunk allow-pass vlan 100 to 101 trust 8021p qinq vlan-translation enable port vlan-mapping external-vlan 13 to 14 map-external-vlan 100 port vlan-mapping external-vlan 15 map-external-vlan 101#return

5 VLAN Mapping ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

5-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 127: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

5.3 Configuration ExamplesThis section provides several examples for configuring VLAN Mapping.

5.3.1 Example for Configuring VLAN Mapping

5.3.1 Example for Configuring VLAN Mapping

Networking RequirementsAs shown in Figure 5-2, the home users are connected to the S-switch through home gateways.The home users, therefore, can access the network of the provider. The home users require oneor more types of voice telephony, Internet, BTV, and VoD services. The services need to beisolated through VLANs. To save VLAN resources, services of the same type are transmittedin the same VLAN in the networks of providers. In addition, you can create the VLAN wherepackets are transparently transmitted on S-switch-A, and configure the interfaces at the providerside and at the user side to allow these packets to pass through.

Figure 5-2 Networking for configuring VLAN mapping

MSTP

MetroEthernet

InternetInternetInternetInternet

SoftX Head-end

VoD ServerInternet

VLAN13 VLAN14

VLAN10->VLAN100VLAN11->VLAN101VLAN12->VLAN102

VLAN13->VLAN100VLAN14->VLAN100VLAN15->VLAN101

HG:Home Gateway

HG

Eth0/0/3 Eth0/0/3

S-swtitch-A S-swtitch-BEth0/0/2 Eth0/0/2

Eth0/0/1

LAN Swtich

VLAN15

HG

Eth0/0/1

VLAN10 VLAN11 VLAN12

HG

VLAN9

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 5 VLAN Mapping Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

5-9

Page 128: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Configuration RoadmapThe configuration roadmap is as follows:

1. Create S-VLANs on S-switch-A and S-swtich-B and configure interfaces at the providerside and the customer side to permit packets from the S-VLANs to pass through.

2. Create C-VLANs on S-switch-A and S-swtich-B.3. Configure VLAN mapping on the interfaces through which S-switch-A and S-swtich-B are

connected to customers.

Data PreparationTo complete the configuration, you need the following data:

l IDs of C-VLANs

l IDs of S-VLANs

Configuration ProcedureThe following presents only the configurations on the S-switch. For the configurations on otherdevices in Figure 5-2, refer to corresponding manuals.

1. Create S-VLANs.# Create VLAN 9, VLAN 10, VLAN 11, VLAN 12, VLAN 100, VLAN 101, and VLAN102 on S-switch-A.<Quidway> system-view[Quidway] sysname S-switch-A[S-switch-A] vlan batch 9 to 12 100 to 102# Create VLAN 13, VLAN 14, VLAN 15, VLAN 100 and VLAN 101 on S-switch-B.<Quidway> system-view[Quidway] sysname S-switch-B[S-switch-B] vlan batch 13 to 15 100 101

2. Configure interfaces at the provider side to permit packets from the VLANs to pass through.# Configure Ethernet 0/0/1 and Ethernet 0/0/2 on S-switch-A to permit packets from VLAN9,VLAN 100, VLAN 101, and VLAN 102 to pass through.[S-switch-A] interface ethernet 0/0/1[S-switch-A-Ethernet0/0/1] port trunk allow-pass vlan 9 100 to 102[S-switch-A-Ethernet0/0/1] quit[S-switch-A] interface ethernet 0/0/2[S-switch-A-Ethernet0/0/2] port trunk allow-pass vlan 9 100 to 102[S-switch-A-Ethernet0/0/2] quit# Configure Ethernet 0/0/1 and Ethernet 0/0/2 on S-switch-B to permit packets from VLAN100 to VLAN 101 to pass through.The configurations on S-switch-B are similar to that of S-switch-A, and are not mentionedhere.

3. Configure the type of the interface at the customer side to hybrid and configure the interfaceto permit packets from the S-VLAN to pass through.# Configure the type of Ethernet 0/0/3 on S-switch-A as hybrid and configure the interfaceto permit packets from VLAN 9, VLAN 10, VLAN 11, VLAN 12, VLAN 100, VLAN 101,and VLAN 102 to pass through.[S-switch-A] interface ethernet 0/0/3[S-switch-A-Ethernet0/0/3] port link-type hybrid[S-switch-A-Ethernet0/0/3] port trunk allow-pass vlan 9 to 12 100 to 102[S-switch-A-Ethernet0/0/3] quit

5 VLAN Mapping ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

5-10 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 129: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

# Configure Ethernet 0/0/3 on S-switch-B as hybrid and configure the interface to permitpackets from VLAN 13, VLAN 14, VLAN 15, VLAN 100 and VLAN 101 to pass through.The configurations on S-switch-B are similar tos that of S-switch-A, and are not mentionedhere.

4. Configure VLAN mapping on the interface at the customer side.# Enabling selective QinQ on the interface at the customer side on S-switch-A.[S-switch-A-Ethernet0/0/3] port vlan-mapping external-vlan 10 map-external-vlan 100[S-switch-A-Ethernet0/0/3] port vlan-mapping external-vlan 11 map-external-vlan 101[S-switch-A-Ethernet0/0/3] port vlan-mapping external-vlan 12 map-external-vlan 102# Enabling selective QinQ on the interfaces at the customer side of S-switch-B.[S-switch-B] interface ethernet 0/0/3[S-switch-B-Ethernet0/0/3] qinq vlan-translation enable# Configure the interface at the customer side of S-switch-B to trust the 802.1p prioritiescarried in packets.[S-switch-B-Ethernet0/0/3] trust 8021p# Configure VLAN mapping on the interface at the customer side of S-switch-B.[S-switch-B-Ethernet0/0/3] port vlan-mapping external-vlan 13 to 14 map-external-vlan 100[S-switch-B-Ethernet0/0/3] port vlan-mapping external-vlan 15 map-external-vlan 101

5. Verify the configuration.# Run the display current-configuration interface command in the system view to checkthe VLAN mapping configuration. Take the display on S-switch-A as an example.[S-switch-A] display current-configuration interface ethernet 0/0/3#interface Ethernet0/0/3 port trunk allow-pass vlan 9 to 12 100 to 102 trust 8021p qinq vlan-translation enable port vlan-mapping external-vlan 10 map-external-vlan 100 port vlan-mapping external-vlan 11 map-external-vlan 101 port vlan-mapping external-vlan 12 map-external-vlan 102#returnFrom the command output, you can find the following information:l VLAN 10, VLAN 13, and VLAN 14 can communicate with the SoftX server of the

provider.l VLAN 11 and VLAN 15 can communicate with the Internet server of the provider.

l VLAN 12 can communicate with the Head-end server and VoD server of the provider.

l Packets can be transparently transmitted in C-VLAN 9.

Configuration FilesOnly the configuration files about the S-switch are provided.

l Configuration file of S-switch-A# sysname S-switch-A# vlan batch 9 to 12 100 to 102#interface Ethernet0/0/1

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 5 VLAN Mapping Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

5-11

Page 130: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

port trunk allow-pass vlan 9 100 to 102#interface Ethernet0/0/2 port trunk allow-pass vlan 9 100 to 102#interface Ethernet0/0/3 port trunk allow-pass vlan 9 to 12 100 to 102 trust 8021p qinq vlan-translation enable port vlan-mapping external-vlan 10 map-external-vlan 100 port vlan-mapping external-vlan 11 map-external-vlan 101 port vlan-mapping external-vlan 12 map-external-vlan 102#return

l Configuration file of S-switch-B# sysname S-switch-B# vlan batch 13 to 15 100 to 101#interface Ethernet0/0/1 port trunk allow-pass vlan 100 to 101#interface Ethernet0/0/2 port trunk allow-pass vlan 100 to 101#interface Ethernet0/0/3 port trunk allow-pass vlan 12 to 15 100 to 101 trust 8021p qinq vlan-translation enable port vlan-mapping external-vlan 13 to 14 map-external-vlan 100 port vlan-mapping external-vlan 15 map-external-vlan 101#return

5 VLAN Mapping ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

5-12 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 131: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

6 Voice VLAN Configuration

About This Chapter

This chapter describes the basics, methods, and examples for configuring voice VLANs.

6.1 IntroductionThis section describes the concept of voice VLANs and voice VLAN function supported by theS-switch.

6.2 Configuring Voice VLANs of the Automatic ModeThis section describes how to configure voice VLANs of the automatic mode. To automaticallyadd interfaces connected to voice devices to a voice VLAN, you need to perform this task.

6.3 Configuring Voice VLANs of the Manual ModeThis section describes how to configure voice VLANs of the manual mode. To manually addinterfaces connected to voice devices to a voice VLAN, you need to perform this task.

6.4 Configuring an Interface to Interwork with Non-Huawei Voice DevicesThis section describes how to configure an Interface to Interwork with Non-Huawei VoiceDevices.

6.5 Configuration ExamplesThis section provides several examples for configuring voice VLANs.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 6 Voice VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

6-1

Page 132: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

6.1 IntroductionThis section describes the concept of voice VLANs and voice VLAN function supported by theS-switch.

A voice VLAN is dedicated to voice flows. After the interfaces connected to voice devices areadded to a voice VLAN, all voice flows are transmitted in the voice VLAN.

Using voice VLANs, you can effectively configure the Quality of Services (QoS) of voice flowsand increase the transmission priority of voice flows. In this way, the quality of voice servicescan be guaranteed.

6.1.1 Identification of Voice Flows

6.1.2 Voice VLAN Features Supported by the S-switch

6.1.3 Logical Relationships Between Configuration Tasks

6.1.1 Identification of Voice Flows

NOTE

S2300SI does not support Voice VLAN.

The S-switch judges whether a flow entering an interface is a voice flow according to the sourceMAC address field of the flow. The flow whose source MAC address complies with theOrganizationally Unique Identifiers (OUIs) of voice devices set by the system is regarded as avoice flow. The interface receiving voice flows is automatically added to the voice VLAN. Then,the voice flow that is sent by the voice device connected to the interface and carries a voiceVLAN tag can be transmitted through this interface.

You can preset OUIs or use the default OUIs.

The first 24 bits of a MAC address is an OUI, which is a unique identifier allocated to a devicesupplier by the Institute of Electrical and Electronics Engineers (IEEE). An OUI indicates thesupplier of a device. The S-switch supports OUI masks.You can set various masks to adjust thedegree of MAC address matching.

By default, the S-switch can identify seven OUIs, as shown in Table 6-1.

Table 6-1 Default OUI addresses

No. OUI Supplier

1 0001-e300-0000 Siemens phone

2 0003-6b00-0000 Cisco phone

3 0004-0d00-0000 Avaya phone

4 0060-b900-0000 Philips/NEC phone

5 00d0-1e00-0000 Pingtel phone

6 00e0-7500-0000 Polycom phone

6 Voice VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

6-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 133: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

No. OUI Supplier

7 00e0-bb00-0000 3Com phone

6.1.2 Voice VLAN Features Supported by the S-switch

Working Modes of Voice VLANsYou can set the working mode of voice VLANs on an interface according to the voice flowspassing through the interface. A voice VLAN can work in the following modes:l Automatic mode

The S-switch automatically adds the interfaces connected to voice devices to the voiceVLAN through learning the source MAC address of the packets that the voice devices sendwhen being powered on. The S-switch controls the number of the interfaces in the voiceVLAN through the interface aging mechanism. When the aging time of the interfacesexpires, the interfaces that cannot update OUIs, that is, the interfaces that no voice datapasses through are automatically deleted from the voice VLAN.

l Manual modeInterfaces are manually added to or deleted from the voice VLAN through commands.

Modes of Voice VLANsNOTE

It is recommended that voice and data services should not be transmitted in the voice VLAN together. Ifthe voice and data services need to be transmitted together, ensure that the voice VLAN works in ordinarymode.

To meet customers' diversified requirements, interfaces enabled with the voice VLAN functioncan process packets in the following modes as shown in Table 6-2:l Security mode

l Ordinary mode

Table 6-2 Packet processing methods in various voice VLAN modes

Modes of VoiceVLANs

Packet Type Mode

Security mode Packets that are untagged Only the packets whose sourceMAC address contains anidentifiable OUI can betransmitted through the voiceVLAN.

Security mode Packets carrying voiceVLAN tags

Only the packets whose sourceMAC address contains anidentifiable OUI can betransmitted through the voiceVLAN.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 6 Voice VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

6-3

Page 134: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Modes of VoiceVLANs

Packet Type Mode

Security mode Packets carrying other typesof VLAN tags

Packets are forwarded if thespecified interface permitts thespecified VLAN tag, regardless ofthe voice VLAN mode.

Ordinary mode Packets that are untagged The source MAC address of thepackets is not checked. All packetscan be transmitted through thevoice VLAN.

Ordinary mode Packets carrying voiceVLAN tags

The source MAC address of thepackets is not checked. All packetscan be transmitted through thevoice VLAN.

Ordinary mode Packets carrying other typesof VLAN tags

Packets are forwarded if thespecified interface permitts thespecified VLAN tag, regardless ofthe voice VLAN mode.

6.1.3 Logical Relationships Between Configuration TasksIn this chapter, all configuration tasks are optional and are not listed in sequence. You canconfigure them as required

6.2 Configuring Voice VLANs of the Automatic ModeThis section describes how to configure voice VLANs of the automatic mode. To automaticallyadd interfaces connected to voice devices to a voice VLAN, you need to perform this task.

6.2.1 Establishing the Configuration Task

6.2.2 (Optional) Configuring Other Identifiable OUIs for the Voice VLAN

6.2.3 (Optional) Setting the Aging Time of a Voice VLAN

6.2.4 Enabling the Voice VLAN Function on an Interface

6.2.5 (Optional) Configuring the Device to Work in the Security Mode

6.2.6 Configuring a Voice VLAN to Work in Automatic Mode

6.2.7 Checking the Configuration

6.2.1 Establishing the Configuration Task

Applicable EnvironmentAfter the voice VLAN of the automatic mode is configured, interfaces connected to voice devicescan be added to or deleted from the voice VLAN automatically and voice flows are transmittedover this voice VLAN.

6 Voice VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

6-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 135: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Pre-configuration TasksBefore configuring the voice VLAN of the automatic mode, complete the following task:l 3.2 Configuring a VLAN

Data PreparationTo configure the voice VLAN of the automatic mode, you need the following data.

No. Data

1 OUI address and mask address

2 Aging time of a voice VLAN

3 Type and number of an interface enabled with the voice VLAN function

6.2.2 (Optional) Configuring Other Identifiable OUIs for the VoiceVLAN

ContextDo as follows on the S-switch that needs to be configured with voice VLANs of the automaticmode.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:voice-vlan mac-address mac-address mask oui-mask [ description text ]

An identifiable OUI is configured for the voice VLAN.

By default, the S-switch identifies voice flows according to default OUIs.

----End

6.2.3 (Optional) Setting the Aging Time of a Voice VLAN

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 6 Voice VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

6-5

Page 136: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

system-view

The system view is displayed.

Step 2 Run:voice-vlan aging-time minutes

The aging time of the voice VLAN is set.

By default, the aging time is 1440 minutes.

----End

6.2.4 Enabling the Voice VLAN Function on an Interface

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

The interface must be a trunk or hybrid interface.

Step 3 Run:voice-vlan vlan-id enable

The voice VLAN function is enabled on the interface.

By default, the voice VLAN function is disabled on interfaces.

----End

6.2.5 (Optional) Configuring the Device to Work in the SecurityMode

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

6 Voice VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

6-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 137: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:voice-vlan security enable

The S-switch is configured to work in the security mode.

By default, the S-switch works in security mode.

----End

6.2.6 Configuring a Voice VLAN to Work in Automatic Mode

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:voice-vlan mode auto

The voice VLAN is configured to work in automatic mode.

By default, a voice VLAN works in automatic mode.

----End

6.2.7 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check the OUIs, OUI masks, and descriptionsupported by the system.

display voice-vlan oui

Check the working mode, security mode, and agingtime of the current voice VLAN.

display voice-vlan [ vlan-id ] status

Run the display voice-vlan oui command to check whether the other identifiable OUIs of thevoice VLAN are correctly configured.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 6 Voice VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

6-7

Page 138: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

<Quidway> display voice-vlan oui--------------------------------------------------- OuiAddress Mask Description --------------------------------------------------- 0001-e300-0000 ffff-ff00-0000 Siemens phone 0003-6b00-0000 ffff-ff00-0000 Cisco phone 0004-0d00-0000 ffff-ff00-0000 Avaya phone 0060-b900-0000 ffff-ff00-0000 Philips/NEC phone 00d0-1e00-0000 ffff-ff00-0000 Pingtel phone 00e0-7500-0000 ffff-ff00-0000 Polycom phone 00e0-bb00-0000 ffff-ff00-0000 3come phone 0011-2200-0000 ffff-ff00-0000 huawei

Run the display voice-vlan [ vlan-id ] status command to check whether the working mode,security mode, and aging time of the voice VLAN are correctly configured.

<Quidway> display voice-vlan 2 statusVoice VLAN Configurations:---------------------------------------------------Voice VLAN status : EnableVoice VLAN ID : 2Voice VLAN aging time : 1440----------------------------------------------------------Port Information:-----------------------------------------------------------Port Add-Mode Security-Mode Legacy-----------------------------------------------------------Ethernet0/0/1 Auto Security Disable

6.3 Configuring Voice VLANs of the Manual ModeThis section describes how to configure voice VLANs of the manual mode. To manually addinterfaces connected to voice devices to a voice VLAN, you need to perform this task.

6.3.1 Establishing the Configuration Task

6.3.2 (Optional) Configuring Other Identifiable OUIs for the Voice VLAN

6.3.3 Enabling the Voice VLAN Function on an Interface

6.3.4 (Optional) Configuring the Device to Work in the Security Mode

6.3.5 Configuring a Voice VLAN to Work in Manual Mode

6.3.6 Adding Interfaces to the Voice VLAN

6.3.7 Checking the Configuration

6.3.1 Establishing the Configuration Task

Applicable EnvironmentAfter the voice VLAN of the manual mode is configured, interfaces connected to voice devicescan be added to or deleted from the voice VLAN manually and voice flows are transmitted overthis voice VLAN.

Pre-configuration TasksBefore configuring the voice VLAN of the manual mode, complete the following task:l 3.2 Configuring a VLAN

6 Voice VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

6-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 139: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Data PreparationTo configure the voice VLAN of the manual mode, you need the following data.

No. Data

1 OUI address and mask address

2 Aging time of a voice VLAN

3 Type and number of an interface enabled with the voice VLAN function

6.3.2 (Optional) Configuring Other Identifiable OUIs for the VoiceVLAN

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:voice-vlan mac-address mac-address mask oui-mask [ description text ]

The identifiable OUIs are configured for the voice VLAN.

By default, the S-switch judges voice flows according to default OUIs.

----End

6.3.3 Enabling the Voice VLAN Function on an Interface

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 6 Voice VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

6-9

Page 140: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The interface must be a trunk or hybrid interface.

Step 3 Run:voice-vlan vlan-id enable

The voice VLAN function is enabled on the interface.

By default, the voice VLAN function is disabled on interfaces.

----End

6.3.4 (Optional) Configuring the Device to Work in the SecurityMode

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:voice-vlan security enable

The S-switch is configured to work in the security mode.

By default, the S-switch works in the security mode.

----End

6.3.5 Configuring a Voice VLAN to Work in Manual Mode

ContextDo as follows on the S-switch.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

6 Voice VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

6-10 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 141: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The interface view is displayed.

Step 3 Run:undo voice-vlan mode auto

The voice VLAN is configured to work in manual mode.

By default, the voice VLAN works in automatic mode.

----End

6.3.6 Adding Interfaces to the Voice VLAN

ContextDo as follows on the S-switch

Procedure

Step 1 If the interface is of the access type, see "3.3.2 Adding Access Interfaces to a VLAN."

Step 2 If the interface is of the trunk type, see "3.3.3 (Optional) Adding Trunk Interfaces to aVLAN."

Step 3 If the interface is of the hybrid type, see "3.3.4 (Optional) Adding Hybrid Interfaces to aVLAN."

----End

6.3.7 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check the OUIs, OUI masks, and description supportedby the system.

display voice-vlan oui

Check the working mode, security mode, and aging timeof the current voice VLAN.

display voice-vlan [ vlan-id ]status

Run the display voice-vlan oui command to check whether the other identifiable OUIs of thevoice VLAN are correctly configured.

<Quidway> display voice-vlan oui--------------------------------------------------- OuiAddress Mask Description --------------------------------------------------- 0001-e300-0000 ffff-ff00-0000 Siemens phone 0003-6b00-0000 ffff-ff00-0000 Cisco phone 0004-0d00-0000 ffff-ff00-0000 Avaya phone 0060-b900-0000 ffff-ff00-0000 Philips/NEC phone 00d0-1e00-0000 ffff-ff00-0000 Pingtel phone 00e0-7500-0000 ffff-ff00-0000 Polycom phone 00e0-bb00-0000 ffff-ff00-0000 3come phone 0011-2200-0000 ffff-ff00-0000 huawei

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 6 Voice VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

6-11

Page 142: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Run the display voice-vlan [ vlan-id ] status command to check whether the working mode,security mode, and aging time of the voice VLAN are correctly configured.

<Quidway> display voice-vlan 2 statusVoice VLAN Configurations:---------------------------------------------------Voice VLAN status : EnableVoice VLAN ID : 2Voice VLAN aging time : 100----------------------------------------------------------Port Information:-----------------------------------------------------------Port Add-Mode Security-Mode Legacy-----------------------------------------------------------Ethernet0/0/1 Auto Security DisableEthernet0/0/2 Manual Normal Disable

6.4 Configuring an Interface to Interwork with Non-HuaweiVoice Devices

This section describes how to configure an Interface to Interwork with Non-Huawei VoiceDevices.

6.4.1 Enabling an Interface to Interwork with Non-Huawei Voice Devices

6.4.1 Enabling an Interface to Interwork with Non-Huawei VoiceDevices

ContextDo as follows on the S-switch on which an Interface to Interwork with Non-Huawei VoiceDevices

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

NOTE

You need to enable the voice VLAN function on an interface before using this command.

Step 3 Run:voice-vlan legacy enable

An interface is enabled to interwork with non-Huawei voice devices.

By default, an interface is disabled from interworking with non-Huawei voice devices.

----End

6 Voice VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

6-12 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 143: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

6.5 Configuration ExamplesThis section provides several examples for configuring voice VLANs.

6.5.1 Example for Configuring the Voice VLAN of the Automatic Mode

6.5.2 Example for Configuring the Voice VLAN of the Manual Mode

6.5.1 Example for Configuring the Voice VLAN of the AutomaticMode

Networking Requirements

As shown in Figure 6-1, On the S-switch, Ethernet 0/0/1 is connected to the IP phone; the IPphone applies for an IP address to the DHCP server through VLAN 6; voice streams aretransmitted in VLAN 2; the S-switch requires that Ethernet 0/0/1 automatically join or leaveVLAN 2.

Figure 6-1 Configuring voice VLANs of the automatic mode

S-switch

Internet

Ethernet0/0/1

DHCP Server

Configuration Roadmap

The configuration roadmap is as follows:

1. Create a voice VLAN.2. Configure other identifiable OUIs for the voice VLAN.3. Set the aging time of the voice VLAN.4. Configure the interface type.5. Configure the default VLAN of the interface.6. Enable the voice VLAN function on the interface.7. Configure the voice VLAN to work in automatic mode.8. Configure the security mode in the voice VLAN.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 6 Voice VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

6-13

Page 144: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Data PreparationTo complete the configuration, you need the following data:l Voice VLAN 2 and VLAN 6 through which the IP phone applies for an IP address

l OUI of 0011-2200-0000 and mask of ffff-ff00-0000

l Aging time of the voice VLAN, which is 100 minutes

l Default VLAN of Ethernet 0/0/1, which is VLAN 6

Configuration Procedure1. Create VLAN 2 and VLAN 6.

<S-switch> system-view[S-switch] vlan batch 2 6

2. Set the OUI to 0011-2200-0000; set the mask to ffff-ff00-0000; set the description tohuawei.[S-switch] voice-vlan mac-address 0011-2200-0000 mask ffff-ff00-0000 description huawei

3. Set the aging time of the voice VLAN to 100 minutes.[S-switch] voice-vlan aging-time 100

4. Set the type of Ethernet 0/0/1 to hybrid.[S-switch] interface ethernet 0/0/1[S-switch-Ethernet0/0/1] port link-type hybrid

5. Set the default VLAN of Ethernet 0/0/1 to VLAN 6.[S-switch-Ethernet0/0/1] port default vlan 6

6. Enable the voice VLAN function on Ethernet 0/0/1.[S-switch-Ethernet0/0/1] voice-vlan 2 enable

7. Configure the security mode in the voice VLAN.[S-switch-Ethernet0/0/1] voice-vlan security enable

8. Configure the voice VLAN to work in automatic mode.[S-switch-Ethernet0/0/1] voice-vlan mode auto[S-switch-Ethernet0/0/1] quit

9. Verify the configuration.Run the display voice-vlan oui command. You can view whether the identifiable OUIs ofthe voice VLAN are correctly configured.<Quidway> display voice-vlan oui--------------------------------------------------- OuiAddress Mask Description --------------------------------------------------- 0001-e300-0000 ffff-ff00-0000 Siemens phone 0003-6b00-0000 ffff-ff00-0000 Cisco phone 0004-0d00-0000 ffff-ff00-0000 Avaya phone 0060-b900-0000 ffff-ff00-0000 Philips/NEC phone 00d0-1e00-0000 ffff-ff00-0000 Pingtel phone 00e0-7500-0000 ffff-ff00-0000 Polycom phone 00e0-bb00-0000 ffff-ff00-0000 3come phone 0011-2200-0000 ffff-ff00-0000 huaweiRun the display voice-vlan status command. You can view whether the working mode,security mode, and aging time of the voice VLAN are correctly configured.<S-switch> display voice-vlan 2 statusVoice VLAN Configurations:-----------------------------------------Voice VLAN status : ENABLE

6 Voice VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

6-14 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 145: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Voice VLAN ID : 2Voice VLAN aging time : 100-----------------------------------------Port Information:-----------------------------------------------------------Port Add-Mode Security-Mode Legacy-----------------------------------------------------------Ethernet0/0/1 Auto Security Disable

Configuration Files#sysname S-switch# vlan batch 2 6#

voice-vlan aging-time 100# voice-vlan mac-address 0011-2200-0000 mask ffff-ff00-0000 description huawei#interface Ethernet0/0/1 port default vlan 6 voice-vlan 2 enable#return

6.5.2 Example for Configuring the Voice VLAN of the Manual Mode

Networking Requirements

As shown in Figure 6-2,On the S-switch, Ethernet 0/0/1 is connected to the IP phone; the IPphone applies for an IP address to the DHCP server through VLAN 6; voice streams aretransmitted in VLAN 2; the S-switch requires that Ethernet 0/0/1 be added to or deleted fromVLAN 2 manually.

Figure 6-2 Configuring voice VLANs of the manual mode

S-switch

Internet

Ethernet0/0/1

DHCP Server

Configuration Roadmap

The configuration roadmap is as follows:

1. Create a voice VLAN.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 6 Voice VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

6-15

Page 146: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

2. Configure other identifiable OUIs for the voice VLAN.3. Configure the type of interface to hybrid..4. Configure the default VLAN of the interface.5. Enable the voice VLAN function on the interface.6. Configure the security mode in the voice VLAN.7. Configure the voice VLAN to work in manual mode.

Data PreparationTo complete the configuration, you need the following data:l Voice VLAN 2 and VLAN 6 through which the IP phone applies for an IP address

l Interface accessing VoIP services, which is Ethernet 0/0/1

l OUI of 0011-2200-0000 and mask of ffff-ff00-0000

l Default VLAN of Ethernet 0/0/1, which is VLAN 6

Configuration Procedure1. # Create VLAN 2 and VLAN 6.

<S-switch> system-view[S-switch] vlan batch 2 6

2. Set the OUI to 0011-2200-0000; set the mask to ffff-ff00-0000; set the description tohuawei.[S-switch] voice-vlan mac-address 0011-2200-0000 mask ffff-ff00-0000 description huawei

3. Set the type of Ethernet 0/0/1 to hybrid.[S-switch] interface ethernet 0/0/1[S-switch-Ethernet0/0/1] port link-type hybrid

4. Set the voice VLAN as the default VLAN of Ethernet 0/0/1.[S-switch-Ethernet0/0/1] port default vlan 6

5. Enable the voice VLAN function on Ethernet 0/0/1.[S-switch-Ethernet0/0/1] voice-vlan 2 enable

6. Configure the security mode in the voice VLAN.[S-switch-Ethernet0/0/1] voice-vlan security enable

7. Configure the voice VLAN to work in manual mode.[S-switch-Ethernet0/0/1] undo voice-vlan mode auto[S-switch-Ethernet0/0/1] port trunk allow-pass vlan 2

8. Verify the configuration.Run the display voice-vlan oui command. You can view whether the other identifiableOUIs of the voice VLAN are correctly configured.<Quidway> display voice-vlan oui--------------------------------------------------- OuiAddress Mask Description --------------------------------------------------- 0001-e300-0000 ffff-ff00-0000 Siemens phone 0003-6b00-0000 ffff-ff00-0000 Cisco phone 0004-0d00-0000 ffff-ff00-0000 Avaya phone 0060-b900-0000 ffff-ff00-0000 Philips/NEC phone 00d0-1e00-0000 ffff-ff00-0000 Pingtel phone 00e0-7500-0000 ffff-ff00-0000 Polycom phone 00e0-bb00-0000 ffff-ff00-0000 3come phone 0011-2200-0000 ffff-ff00-0000 huawei

6 Voice VLAN ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

6-16 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 147: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Run the display voice-vlan status command. You can view whether the working mode,security mode, and aging time of the voice VLAN are correctly configured.<S-switch> display voice-vlan 2 statusVoice VLAN Configurations:-----------------------------------------Voice VLAN status : ENABLEVoice VLAN ID : 2Voice VLAN aging time : 1440-----------------------------------------Port Information:-----------------------------------------------------------Port Add-Mode Security-Mode Legacy-----------------------------------------------------------Ethernet0/0/1 Manual Security Disable

Configuration Files#sysname S-switch# vlan batch 2 6# voice-vlan mac-address 0011-2200-0000 mask ffff-ff00-0000 description huawei#interface Ethernet0/0/1 port default vlan 6 port trunk allow-pass vlan 2 voice-vlan 2 enable undo voice-vlan mode auto#return

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 6 Voice VLAN Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

6-17

Page 148: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]
Page 149: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

7 QinQ Configuration

About This Chapter

This chapter describes the basic concepts, and methods and examples for configuring QinQ.

7.1 IntroductionThis section describes the concepts of QinQ.

7.2 Configure QinQ InterfacesThis section describes how to configure QinQ interfaces.

7.3 Configuration ExamplesThis section provides several examples for configuring QinQ.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 7 QinQ Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

7-1

Page 150: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

7.1 IntroductionThis section describes the concepts of QinQ.

7.1.1 QinQ

7.1.2 References

7.1.3 Logical Relationships Between Configuration Tasks

7.1.1 QinQNOTE

S2300SI does not support QinQ.

The 802.1Q-in-802.1Q protocol is a Layer 2 tunnel protocol based on the IEEE 802.1Qtechnology. The frame transmitted in the public network has double 802.1Q tags. One tagidentifies a public network and the other identifies a private network. It is thus called the QinQprotocol.

The core concept of QinQ is to encapsulate a private VLAN tag in a public VLAN tag; Thus, apacket carrying double VLAN tags traverses the backbone network of the Internet serviceprovider (ISP). This provides a simpler Layer 2 Virtual Private Network (VPN) tunnel for users.

7.1.2 References

For detailed information about QinQ, refer to the Quidway S2300 Series Ethernet Switches -Feature Description.

7.1.3 Logical Relationships Between Configuration Tasks

The configuration of basic QinQ and that of selective QinQ are independent of each other.

7.2 Configure QinQ InterfacesThis section describes how to configure QinQ interfaces.

7.2.1 Establishing the Configuration Task

7.2.2 Setting the Interface Type

7.2.3 (Optional) Setting the TPID Etype Value in the Outer VLAN Tag

7.2.4 Setting the VLAN ID of the Outer VLAN Tag

7.2.5 Checking the Configuration

7.2.1 Establishing the Configuration Task

Applicable EnvironmentA Layer 2 network can support up to 4094 VLANs. This number of VLANs cannot meet therequirement in the actual application. QinQ interfaces provided by the S-switch can add double

7 QinQ ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

7-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 151: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

tags to a frame. With QinQ interfaces, you can transmit frames by using the private VLAN tagsin the internal networks such as the enterprise networks, and using the public VLAN tags in theexternal networks such as the ISP networks. In this manner, QinQ interfaces can support up to4094 x 4094 VLAN IDs. This meets the need of isolating a large number of users.

NOTE

S2300SI does not support QinQ.

Pre-configuration Tasks

None.

Data Preparation

To configure QinQ, you need the following data.

No. Data

1 Number of the QinQ interface

2 (Optional) TPID Etype value in the outer VLAN tag

3 VLAN ID of the outer VLAN tag

7.2.2 Setting the Interface Type

Context

Do as follows on the S-switch on which QinQ needs to be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Or run:

interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:port link-type dot1q-tunnel

An interface is set as the QinQ interface.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 7 QinQ Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

7-3

Page 152: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

By default, the interface type is hybrid.

----End

7.2.3 (Optional) Setting the TPID Etype Value in the Outer VLANTag

ContextDo as follows on the S-switch on which QinQ needs to be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 interface interface-type interface-number

The interface view is displayed.

Or run:

interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:qinq protocol protocol-id

The TPID Etype value in the outer VLAN tag is set.

By default, the TPID Etype value in the outer VLAN tag is 0x8100.

NOTE

When an interface receives a packet that has the different TPID Etype value in the outer VLAN tag fromthat set on the interface, the interface processes the packet as an untagged packet.

On an interface, the TPID Etype value in the outer VLAN tag needs to be identified by the devicedirectly connected to this interface.

----End

7.2.4 Setting the VLAN ID of the Outer VLAN Tag

ContextDo as follows on the S-switch on which QinQ needs to be configured.

Procedure

Step 1 Run:system-view

7 QinQ ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

7-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 153: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The system view is displayed.

Step 2 Run:vlan vlan-id

A VLAN is created and the VLAN view is displayed.

Step 3 Run:quit

Exit from the VLAN view.

Step 4 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Step 5 Run:port default vlan vlan-id

The VLAN ID of the outer VLAN tag is set. That is, the default VLAN is configured for aninterface.

----End

7.2.5 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check the QinQ configuration ofan interface.

display current-configuration interface [ interface-type [ interface-number ] ] [ | { begin | exclude |include } regular-expression ]

After the configuration succeeds, run the display current-configuration interface [ interface-type [ interface-number ] ] [ | { begin | exclude | include } regular-expression ] command tocheck the QinQ configuration of an interface. You can obtain the following results:

l The interface type is set correctly.

l The TPID Etype value in the outer VLAN tag is set correctly.

l The VLAN ID of the outer VLAN tag, that is, the default VLAN of an interface, is setcorrectly.

7.3 Configuration ExamplesThis section provides several examples for configuring QinQ.

7.3.1 Example for Configuring QinQ

7.3.2 Example for Setting the TPID Etype Value in the Outer VLAN Tags

7.3.1 Example for Configuring QinQ

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 7 QinQ Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

7-5

Page 154: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Networking RequirementsAs shown in Figure 7-1, a certain enterprise has two office locations. Each office location ofthe enterprise accesses S-switch-A or S-switch-B of the Internet Service Provider (ISP) network.VLANs with VLAN IDs ranging from 500 to 2500 are adopted on the network of the enterpriseso that office locations of the enterprise can communicate with each other through the ISPnetwork.

Figure 7-1 Networking diagram for configuring QinQ ports

VLAN2500

S-switch-A

Eth0/0/1

Eth0/0/1

VLAN1000 VLAN2000

Enterprise

.....

VLAN500

Enterprise

.....

S-switch-BEth0/0/2Eth0/0/2

Configuration RoadmapThe configuration roadmap is as follows:

l Create VLAN 10 on S-switch-A and S-switch-B.

l Configure Ethernet 0/0/1 to be a QinQ interface on S-switch-A and S-switch-B.

l Add Ethernet 0/0/2 on S-switch-A and S-switch-B to VLAN 10 in tag mode.

7 QinQ ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

7-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 155: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Data PreparationTo complete the configuration, you need the following data:

l The enterprise belongs to VLAN 10 on the ISP network.

Configuration Procedure1. Create a VLAN.

# Create VLAN 10 on S-switch-A.<Quidway> system-view[Quidway] sysname S-switch-A[S-switch-A] vlan 10# Create VLAN 10 on S-switch-B.<Quidway> system-view[Quidway] sysname S-switch-B[S-switch-B] vlan 10

2. # Configure a QinQ interface.# Configure Ethernet 0/0/1 on S-switch-A to be a QinQ interface.[S-switch-A] interface ethernet 0/0/1[S-switch-A-Ethernet0/0/1] port link-type dot1q-tunnel[S-switch-A-Ethernet0/0/1] port default vlan 10[S-switch-A-Ethernet0/0/1] quit# Configure Ethernet 0/0/1 on S-switch-B to be a QinQ interface.[S-switch-B] interface ethernet 0/0/1[S-switch-B-Ethernet0/0/1] port link-type dot1q-tunnel[S-switch-B-Ethernet0/0/1] port default vlan 10[S-switch-B-Ethernet0/0/1] quit

3. Add Ethernet 0/0/2 on S-switch-A and S-switch-B to VLAN 10 in tag mode.# Add Ethernet 0/0/2 on S-switch-A to VLAN 10 in tag mode.[S-switch-A] interface ethernet 0/0/2[S-switch-A-Ethernet0/0/2] port trunk allow-pass vlan 10[S-switch-A-Ethernet0/0/2] quit# Add Ethernet 0/0/2 on S-switch-B to VLAN 10 in tag mode.[S-switch-B] interface ethernet 0/0/2[S-switch-B-Ethernet0/0/2] port trunk allow-pass vlan 10[S-switch-B-Ethernet0/0/2] quit

4. Verify the configuration.From a host in one office location, ping a remote host in the same VLAN on the other officelocation. If the ping succeeds, it indicates that hosts on different locations can communicatewith each other.

Configuration Filesl Configuration file of S-switch-A

# sysname S-switch-A# vlan batch 10#interface Ethernet0/0/1port link-type dot1q-tunnelport default vlan 10#interface Ethernet0/0/2port trunk allow-pass vlan 10

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 7 QinQ Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

7-7

Page 156: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

#return

l Configuration file of S-switch-B# sysname S-switch-B# vlan batch 10#interface Ethernet0/0/1port link-type dot1q-tunnelport default vlan 10#interface Ethernet0/0/2port trunk allow-pass vlan 10#return

7.3.2 Example for Setting the TPID Etype Value in the Outer VLANTags

Networking RequirementsS-switch-A and S-switch-B are Huawei datacom devices using the Versatile Routing Platform(VRP). Router C and Switch A are non-Huawei devices. The networking and the TPID Etypevalue in the outer VLAN tag are shown in Figure 7-2. You can set the TPID Etype value on theinterfaces of S-switch-B. In this manner, the devices of different manufacturers can communicatewith each other.

Figure 7-2 Networking diagram of configuring the compatibility of the TPID Etype value inthe outer VLAN tags

S-switch-A S-switch-B

Router C

Switch A

0x81000x9100

0x9100

Eth0/0/1Eth0/0/2

IPcore

Device Name TPID Etype Value in the Outer VLANTag

Device Name TPID Etype Value in the Outer VLANTag

S-switch-A 0x8100 Router C 0x9100S-switch-B 0x8100 Switch A 0x9100

Configuration RoadmapThe configuration roadmap is as follows:

7 QinQ ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

7-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 157: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

l Set the TPID Etype value for the outer tag of Switch A on the physical interface on S-switch-B connected to Switch A.

l Set the TPID Etype value for the outer tag of Router C on the physical interface on S-switch-B connected to Router C.

Data PreparationTo complete the configuration, you need the following data:

l TPID Etype value in the outer VLAN tag added by the non-Huawei devices

l Names of the physical interfaces connecting the non-Huawei devices on S-switch-B

Configuration Procedure1. Set the TPID Etype value for the outer VLAN tag on the physical interfaces connecting the

non-Huawei devices on S-switch-B.<Quidway> system-view[Quidway] sysname S-switch-B[S-switch-B] interface ethernet 0/0/1[S-switch-B-Ethernet0/0/1] qinq protocol 9100[S-switch-B-Ethernet0/0/1] quit[S-switch-B] interface ethernet 0/0/2[S-switch-B-Ethernet0/0/2] qinq protocol 9100

Configuration FilesConfiguration file of S-switch-B

# sysname S-switch-B#interface Ethernet0/0/1 qinq protocol 9100#interface Ethernet0/0/2 qinq protocol 9100#return

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 7 QinQ Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

7-9

Page 158: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]
Page 159: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

8 MAC Table Configuration

About This Chapter

This chapter describes the basics, methods, and examples for configuring the Medium AccessControl (MAC) table.

8.1 IntroductionThis section describes the concepts of MAC table.

8.2 Configuring the MAC TableThis section describes how to configure the MAC table.

8.3 Restricting MAC Address LearningThis section describes how to configure the limit to the number of MAC entries learned by aninterface.

8.4 Configuring the S-switch to Discard Packets with Illegal MAC AddressesThis section describes how to configure the S-switch to discard packets with illegal MACaddresses.

8.5 Configuration ExamplesThis section provides examples for configuring the MAC address table.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 8 MAC Table Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

8-1

Page 160: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

8.1 IntroductionThis section describes the concepts of MAC table.

8.1.1 MAC Table

8.1.2 Capacity of a MAC Table and Limit to the Number of MAC Entries Learned by an Interface

8.1.3 References

8.1.4 Logical Relationships Between Configuration Tasks

8.1.1 MAC Table

The S-switch holds one MAC address table (MAC table for short). The MAC table records MACaddresses of all the devices connected to all the interfaces of the S-switch. When forwarding adata frame, the S-switch searches the MAC table for the outbound interface according to thedestination MAC address in the frame. This helps the S-switch reduce the broadcasting of frames.

8.1.2 Capacity of a MAC Table and Limit to the Number of MACEntries Learned by an Interface

Capacity of a MAC Table

The MAC table on the S-switch can hold a maximum of 8K entries.

Limit to the Number of MAC Entries Learned by an Interface

The capacity of a MAC table is limited; therefore, when hackers forge a large quantity of packetswith different source MAC addresses and send the packets to the S-switch, the MAC table ofthe S-switch may be filled to its full capacity. After the MAC table of the S-switch is crammedwith MAC entries, the system cannot learn the source MAC address in the normal packetsreceived by the interface any more.

The S-switch supports the limit to the number of MAC entries learned by an interface. That is,you can set the maximum number of dynamic MAC entries learned by the interface. After thisfunction is configured, the interface cannot learn new MAC entries if the interface has learnedthe maximum MAC entries. The interface can learn new MAC entries only when the previouslylearned MAC entries aged.

In most cases, the attack packets sent by a hacker enter the S-switch through the same interface.Thus, you can prevent the MAC table of the S-switch from being fully filled by configuring thelimit to the number of MAC entries learned by an interface.

8.1.3 References

For details on the principle of the MAC table technology, refer to the chapter "Ethernet andSwitching Technology" in the Quidway S2300 Series Ethernet Switches Feature Description.

8 MAC Table ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

8-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 161: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

8.1.4 Logical Relationships Between Configuration Tasks

Configuring the MAC table is the basis for configuring the capacity of the MAC table and limitto the amount of MAC entries learned by an interface. You are required to first configure theMAC table, and then choose to configure the capacity of the MAC table and limit to the numberof MAC entries learned by an interface as required.

8.2 Configuring the MAC TableThis section describes how to configure the MAC table.

The configuration procedures are optional and not listed in sequence.

8.2.1 Establishing the Configuration Task

8.2.2 (Optional) Configuring Static MAC Address Entries

8.2.3 (Optional) Configuring Blackhole MAC Address Entries

8.2.4 (Optional) Setting the Aging Time of Dynamic MAC Entries

8.2.5 Checking the Configuration

8.2.1 Establishing the Configuration Task

Applicable EnvironmentYou should manually add MAC entries or adjust the aging time of dynamic entries in the MACtable in the following situations to optimize the MAC table and meet different requirements:

l Sending the packets with a specified destination MAC address from a designated interface

l Discarding the packets with a specified source or destination MAC address

l Modifying the aging time of dynamic MAC entries

Pre-configuration TasksNone.

Data PreparationTo configure the MAC table, you need the following data.

No. Data

1 (Optional) Destination MAC address, number of the outbound interface, and ID ofthe VLAN

2 (Optional) Aging time of dynamic MAC entries

8.2.2 (Optional) Configuring Static MAC Address Entries

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 8 MAC Table Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

8-3

Page 162: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

ContextThe S-switch can learn 8K MAC addresses, among which the number of non-dynamic MACaddresses cannot exceed 1024.

When you configure static entries, you may meet either of the following cases if the MAC tableis full:

l If there are less than 1024 non-dynamic MAC entries, the system deletes a dynamic MACentry and adds a static MAC entry.

l If there are 1024 non-dynamic entries, the system prompts "The number of entries reachesthe limit.".

Do as follows on the S-switch where static MAC entries need to be added.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Or run:

interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:mac-address static mac-address interface-type interface-number vlan vlan-id

Static MAC address entries are configured.

NOTE

StepStep 2 is optional, whether you run the mac-address command in the system view or the interfaceview, the command output is the same.

----End

8.2.3 (Optional) Configuring Blackhole MAC Address Entries

ContextThe S-switch can learn 8K MAC addresses, among which the number of non-dynamic MACaddresses cannot exceed 1024.

When you configure blackhole entries, you may meet either of the following cases if the MACtable is full:

l If there are less than 1024 non-dynamic MAC entries, the system deletes a dynamic MACentry and adds a blackhole MAC entry.

8 MAC Table ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

8-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 163: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

l If there are 1024 non-dynamic entries, the system prompts "The number of entries reachesthe limit.".

Do as follows on the S-switch where blackhole MAC entries need to be added.

NOTE

S2300SI does not support blackhole MAC globally.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:vlan vlan-id

The VLAN view is displayed.

Step 3 Run:mac-address blackhole mac-address

Blackhole MAC address entries are configured.

When you configure a blackhole MAC address entry in the VLAN view, the S-switch discardsany frame whose source or destination MAC address is a blackhole MAC address in the VLAN.

NOTE

If Step 2 is not performed, the blackhole MAC address entry configured in the system view is not relatedto any VLAN. The S-switch discards any frame whose source or destination MAC address is a blackholeMAC address.

----End

8.2.4 (Optional) Setting the Aging Time of Dynamic MAC Entries

ContextDo as follows on the S-switch on which the aging time of dynamic MAC entries needs to beadjusted.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:mac-address aging-time aging-time

The aging time of dynamic MAC entries is set.

By default, the aging time of dynamic MAC entries is 300 seconds.

----End

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 8 MAC Table Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

8-5

Page 164: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

8.2.5 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check information aboutthe MAC table.

display mac-address [ mac-address vlan vlan-id | { blackhole| static } | dynamic [ interface-type interface-number | vlan vlan-id | unit unit-id ] | sticky [ interface-type interface-number ] |{ authen | guest } [ interface-type interface-number | vlan vlan-id ] ]

Check dynamic MACaddress entries learnt by aspecified stack.

display mac-address dynamic unit unit-id

Check information aboutsticky MAC addressentries.

display mac-address sticky [ interface-type interface-num ]

Check the aging time ofMAC address entries.

display mac-address aging-time

Run the preceding commands, and you can obtain the following information:

l The static and blackhole MAC entries are configured correctly.

l The dynamic MAC address entries learnt by a specified stack are configured correctly.

l The sticky MAC address entries are configured correctly.

l The aging time of MAC entries is set correctly.

NOTE

S2300SI does not support blackhole MAC.

8.3 Restricting MAC Address LearningThis section describes how to configure the limit to the number of MAC entries learned by aninterface.

8.3.1 Establishing the Configuration Task

8.3.2 Enabling Restriction of MAC Address Learning

8.3.3 (Optional) Configuring the Limit to the Amount of MAC Entries Learned by an Interface

8.3.4 Checking the Configuration

8 MAC Table ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

8-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 165: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

8.3.1 Establishing the Configuration Task

Applicable EnvironmentNOTE

S2300SI does not support restricting MAC address learning on GigabitEthernet interfaces.

You need to configure the limit to the number of MAC entries learned by an interface in thefollowing situations:

l To prevent the MAC table from being attacked through an interface, you can control themaximum number of dynamic MAC entries by setting the limit to the amount of MACentries learned by an interface.

Pre-configuration Tasks

None.

Data Preparation

To configure the limit to the amount of MAC entries learned by an interface on an interface, youneed the following data.

No. Data

1 (Optional) Maximum number of dynamic MAC entries learned by an interface

2 (Optional) The type and number of the interface

8.3.2 Enabling Restriction of MAC Address Learning

ContextDo as follows on the S-switch on which the limit to the number of MAC entries learned by aninterface need to be enabled.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:mac-address restrict

The limit to the number of MAC entries learned by an interface is enabled on the S-switch.

By default, the limit to the number of MAC entries learned by an interface on the S-switch.

----End

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 8 MAC Table Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

8-7

Page 166: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

8.3.3 (Optional) Configuring the Limit to the Amount of MACEntries Learned by an Interface

ContextDo as follows on the S-switch on which the limit to the amount of MAC entries learned by aninterface and packet forwarding restriction on an interface need to be enabled.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:mac-table limit interface-type interface-number limit-number

The limit to the number of MAC entries learned by an interface is configured.

By default, the number of MAC entries learned by an interface is not restricted.

----End

8.3.4 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check the limit to the amount of MACaddresses learned by an interface on aninterface.

display current-configuration [ | { begin |exclude | include } regular-expression ]

Run the preceding command, and you can obtain the following information:

l The limit to the amount of MAC addresses learned by an interface is configured correctly.

8.4 Configuring the S-switch to Discard Packets with IllegalMAC Addresses

This section describes how to configure the S-switch to discard packets with illegal MACaddresses.

8.4.1 Establishing the Configuration Task

8.4.2 Dropping Packets with Specified Illegal MAC Addresses

8.4.3 Clearing Alarms for the Dropping of Packets with Illegal MAC Addresses

8.4.4 Checking the Configuration

8 MAC Table ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

8-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 167: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

8.4.1 Establishing the Configuration Task

Applicable EnvironmentNOTE

S2300SI does not support tje function of discarding packets with an illegal MAC addres.

You need to configure the S-switch to discard packets with an illegal MAC address being all 0sif the situation is as follows:

l The S-switch receives packets with illegal source MAC addresses or illegal destinationMAC addresses.

Pre-configuration Tasks

None.

Data Preparation

None

8.4.2 Dropping Packets with Specified Illegal MAC Addresses

ContextDo as follows on the S-switch that is to be configured to drop packets with illegal MAC addresses.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:drop illegal-mac enable

The S-switch is configured to drop packets with illegal MAC addresses.

By default, the S-switch is not configured to drop packets with illegal MAC addresses.

----End

8.4.3 Clearing Alarms for the Dropping of Packets with Illegal MACAddresses

Context

Do as follows on the S-switch on which alarms for the dropping of packets with illegal MACaddresses are to be cleared.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 8 MAC Table Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

8-9

Page 168: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:drop illegal-mac alarm

Alarms for the dropping of packets with illegal MAC addresses are cleared.

By default, the alarming function is enabled.

----End

8.4.4 Checking the Configuration

Procedure

Step 1 Run the display current-configuration [ | { begin | exclude | include } regular-expression ]command to check whether the S-switch drops packets with illegal MAC addresses.

----End

ExampleRun the display current-configuration [ | { begin | exclude | include } regular-expression ]command to check whether the S-switch drops packets with illegal MAC addresses.

8.5 Configuration ExamplesThis section provides examples for configuring the MAC address table.

8.5.1 Example for Configuring the MAC Table

8.5.2 Example for Configuring the Limit to the Number of MAC Entries Learned by an Interface

8.5.1 Example for Configuring the MAC Table

Networking RequirementsThe MAC address of the PC is 0002-0002-0002 and the PC belongs to VLAN 2, and the interfaceconnecting the PC to the S-switch is Ethernet 0/0/8. To prevent MAC addresses from beingattacked, you need to add a static entry to the MAC address table for the PC on the S-switch,and set the aging time of dynamic MAC entries on the S-switch to 500 seconds.

Configuration RoadmapThe configuration roadmap is as follows:l Create a VLAN and add Ethernet 0/0/8 to the VLAN.

8 MAC Table ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

8-10 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 169: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

l Configure static MAC entries.

l Set the aging time of dynamic entries to 500 seconds.

Data Preparation

To complete the configuration, you need the following data:

l MAC address: 00-02-00-02-00-02

l VLAN to which the S-switch belongs: VLAN 2

l Interface connecting the PC and the S-switch being Ethernet 0/0/8

l Aging time of dynamic MAC entries on the S-switch being 500 seconds

Configuration Procedure1. Add static MAC entries.

# Create VLAN 2 and add Ethernet 0/0/8 to VLAN 2.<Quidway> system-view[Quidway] vlan 2[Quidway-vlan2] port ethernet 0/0/8[Quidway-vlan2] quit

# Configure static MAC entries.[Quidway] mac-address static 2-2-2 ethernet 0/0/8 vlan 2

2. Set the aging time of dynamic MAC entries.[Quidway] mac-address aging-time 500

3. Verify the configuration.

# Run the display mac-address command in any view to check whether the static entry isadded successfully.[Quidway] display mac-address 2-2-2 vlan 2MAC Address VLAN/ID Port Type Lsp----------------------------------------------------------------------0002-0002-0002 2 Ethernet0/0/8 static 0/- Total matching items displayed = 1

# Run the display mac-address aging-time command to check whether the aging time ofdynamic entries is set successfully.[Quidway] display mac-address aging-time Aging time: 500 seconds

Configuration Files# sysname Quidway# vlan batch 2# mac-address aging-time 500#interface Ethernet0/0/8 port default vlan 2 mac-address static 0002-0002-0002 Ethernet0/0/8 vlan 2#return

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 8 MAC Table Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

8-11

Page 170: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

8.5.2 Example for Configuring the Limit to the Number of MACEntries Learned by an Interface

Networking RequirementsAs the network shown in Figure 8-1, the host connected to GigabitEthernet 0/0/1 of S-switch-A may cause possible attacks to the MAC table of S-switch-A. You are required to prevent andreduce the danger resulting from such attacks.

Figure 8-1 Configuring the limit to the number of MAC entries learned by an interface on aninterface

VLAN2

S-switch-A

S-switch-B

GE0/0/3

GE0/0/1 GE0/0/2

Host10001-0001-0001

Configuration RoadmapThe configuration roadmap is as follows:

l Create a VLAN.

l Enable the limit to the number of MAC entries learned by an interface on an interface.

l Configure GigabitEthernet 0/0/1 of S-switch-A to learn a maximum of 1024 MAC entries.

Data PreparationTo complete the configuration, you need the following data:

l A maximum of 1024 MAC entries learned by GigabitEthernet 0/0/1 of S-switch-A

l VLAN 2 to which GigabitEthernet0/0/1 and GigabitEthernet0/0/2 of S-switch-A belong

Configuration Procedure1. Create a VLAN.

8 MAC Table ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

8-12 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 171: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The configuration details are not mentioned here.2. Enable the limit to the number of MAC entries learned by an interface.

# Enable the limitation to the number of MAC entries learned by an interface on S-switch-A.[S-switch-A] mac-address restrict

3. Configure the limit to the number of MAC entries learned by an interface.# Configure the limit to the number of MAC entries learned by GigabitEthernet 0/0/1 ofS-switch-A.[S-switch-A] mac-table limit GigabitEthernet 0/0/1 1024

Configuration FilesConfiguration file of S-switch-A

#sysname S-switch-A#vlan batch 2#mac-address restrict#mac-table limit GigabitEthernet0/0/1 1024#interface GigabitEthernet0/0/1 port default vlan 2#interface GigabitEthernet0/0/2 port default vlan 2#interface GigabitEthernet0/0/3 port trunk allow-pass vlan 2#return

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 8 MAC Table Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

8-13

Page 172: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]
Page 173: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

9 MSTP Configuration

About This Chapter

This chapter describes the basics, methods, and examples for configuring the Spanning TreeProtocol (STP), Rapid Spanning Tree Protocol (RSTP), and Multiple Spanning Tree Protocol(MSTP).

9.1 IntroductionThis section describes the basic knowledge you need to know before configuring MSTP.

9.2 Enabling Basic Functions of MSTP on the S-switchThis section describes how to enable basic functions of MSTP on the S-switch.

9.3 Adding an S-switch to a Specified MST RegionThis section describes how to add an S-switch to a specified multiple spanning tree (MST) region.

9.4 Configuring MSTP Parameters of the S-switchThis section describes how to configure MSTP parameters of the S-switch.

9.5 Configuring MSTP Protection on the S-switchThis section describes how to configure MSTP protection on the S-switch.

9.6 Maintaining MSTPThis section describes how to monitor MSTP, clear the MSTP statistics, and debug MSTP.

9.7 Configuration ExamplesThis section provides MSTP configuration examples.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-1

Page 174: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

9.1 IntroductionThis section describes the basic knowledge you need to know before configuring MSTP.

9.1.1 STP, RSTP, and MSTP

9.1.2 References

9.1.1 STP, RSTP, and MSTP

STP is used in the local area network (LAN) to eliminate loops. The S-switches running STPdiscover loops in the network by exchanging information with one another, and block certaininterfaces to eliminate loops. With the growing LAN scale, STP has become an importantprotocol.

RSTP is described in Institute of Electrical and Electronics Engineers (IEEE) 802.1w in detail.RSTP is based on and supplements STP. Nowadays, RSTP is employed in the actual networkinginstead of STP.

MSTP is a new spanning tree protocol defined in IEEE 802.1s and introduces concepts of regionand instance. Based on different requirements, MSTP divides a big network into regions wheremultiple spanning tree instances (MSTIs) are created. These MSTIs are mapped to virtual LANs(VLANs) and bridge protocol data units (BPDUs) are transmitted between network bridges.Network bridges determine regions to which they belong according to BPDUs. RSTP withmultiple instances are used within regions. Protocols which RSTP are compatible with are usedbetween regions.

MSTP is compatible with STP and RSTP. RSTP is compatible with STP.

NOTES2300SI does not support MSTP.

9.1.2 ReferencesFor details about the principles of STP, RSTP, and MSTP, refer to chapter "MSTP" in theQuidway S2300 Series Ethernet Switches Feature Description.

9.2 Enabling Basic Functions of MSTP on the S-switchThis section describes how to enable basic functions of MSTP on the S-switch.

9.2.1 Establishing the Configuration Task

9.2.2 (Optional) Enabling S-switch to Process BPDUs

9.2.3 Enabling MSTP

9.2.4 Checking the Configuration

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 175: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

9.2.1 Establishing the Configuration Task

Applicable EnvironmentMSTP functions are enabled on the S-switch.

Pre-configuration TasksNone.

Data PreparationNone.

9.2.2 (Optional) Enabling S-switch to Process BPDUs

ContextDo as follows on the .

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu enable

The S-switch is enabled to process BPDUs.

----End

9.2.3 Enabling MSTP

ContextDo as follows on the S-switch on which MSTP needs to be enabled.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp enable

The MSTP function is enabled on the S-switch.

By default, the MSTP function on the S-switch is disabled.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-3

Page 176: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

After you run the stp enable command, the system prompts "Are you sure to change global STP status?[Y/N]" for you to determine whether MSTP needs to be enabled.

When the MSTP function is enabled on the S-switch, the MSTP function is enabled on allinterfaces on the S-switch by default.

NOTE

If two or more interfaces on the S-switch enabled with MSTP need to be added to the Eth-Trunk, you mustdisable the interfaces before adding them to the Eth-Trunk. Then, you can enable these interfaces of theEth-Trunk. Otherwise, a temporary broadcast storm occurs.

----End

9.2.4 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check the STP configuration. display stp

Check whether an Ethernet or aGigabitEthernet interface is enabled toprocess BPDUs.

display current-configuration interface

9.3 Adding an S-switch to a Specified MST RegionThis section describes how to add an S-switch to a specified multiple spanning tree (MST) region.

9.3.1 Establishing the Configuration Task

9.3.2 Setting the MSTP Mode of the S-switch

9.3.3 Setting the MST Region

9.3.4 Activating the Configuration of an MST Region

9.3.5 (Optional) Setting the S-switch as the Root Switch or Secondary Root Switch

9.3.6 (Optional) Setting the Priority of the S-switch in a Specified MSTI

9.3.7 Checking the Configuration

9.3.1 Establishing the Configuration Task

Applicable EnvironmentAn S-switch that is not enabled with MSTP is added to an MST region. Or an S-switch is enabledwith MSTP and needs to be added to another MST region by modifying its MST region attributes.

Pre-configuration TasksBefore adding the S-switch to the specified MST region, complete the following tasks:

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 177: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

l Configuring physical attributes of the interface

l Configuring VLAN features of the interface

Data PreparationBefore adding the S-switch to the specified MST region, you need the following data.

No. Data

1 Name of the MST region that the S-switch belongs to

2 Mapping between MSTIs and VLANs

3 MSTP revision level of the MST region

4 (Optional) Priority of the S-switch in the specified MSTI

9.3.2 Setting the MSTP Mode of the S-switch

Context

CAUTIONWhen an S-switch is configured in multiple MSTIs, other MSTIs except MSTI 0 fail tocommunicate if the S-switch is switched to the STP mode. MSTI 0 refers to the internal spanningtree (IST).

Do as follows on each S-switch that needs to be added to the MST region.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp mode { mstp | stp }

The MSTP mode of the S-switch is set.

By default, an S-switch runs in MSTP mode.

NOTE

On the S-switch running MSTP, if an interface is connected to a device running STP, the interfaceautomatically switches to the STP compatible mode. If the device running STP is powered off or removed,the interface cannot automatically switch to the MSTP mode. In this case, you must run the stp mcheckcommand to manually switch the interface to the MSTP mode.

----End

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-5

Page 178: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

9.3.3 Setting the MST Region

ContextDo as follows on each S-switch that needs to be added to the MST region.

NOTE

The two S-switches belong to the same MST region when the following configurations are the same:

l MST region name

l Mapping between MSTIs and VLANs

l Revision level of the MST region

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp region-configuration

The MST region view is displayed.

Step 3 Run:region-name name

The name of the MST region is set.

By default, the name of an MST region is the MAC address of S-switch.

Step 4 Run:instance instance-id vlan { vlan-id [ to vlan-id ] }&<1-10>

The mapping between MSTIs and VLANs is set.

By default, all VLANs in an MST region are mapped to MSTI 0.

Step 5 Run:revision-level level

The MSTP revision level of the MST region is set.

By default, the revision level of the MST region is 0.

----End

9.3.4 Activating the Configuration of an MST Region

ContextNOTE

When you change parameter values of an MST region on the S-switch after enabling the MSTP feature,you can run the following commands to activate the configuration of the MST region.

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 179: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The change of related parameters (especially the VLAN mapping table) in an MST region causesrecalculation of spanning trees and route flapping in a network. You are recommended to runthe check region-configuration command to check the parameter settings of the current regionin the MST region view before activating them. If the parameter settings are correct, you canrun the active region-configuration command to activate them.

The activated configuration of the MST region by running the active region-configurationcommand includes:

l MST region name

l Revision level

l Mapping between VLANs and MSTIs

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp region-configuration

The MST region view is displayed.

Step 3 Run:check region-configuration

The configuration of parameters in the MST region is checked.

Step 4 Run:active region-configuration

The configuration of the MST region is activated.

----End

9.3.5 (Optional) Setting the S-switch as the Root Switch orSecondary Root Switch

Context

Root types of the S-switches in different MSTIs are independent of each other. The S-switchcan serve as the root switch or secondary root switch of any MSTI. However, the S-switch cannotserve as both the root switch and secondary root switch in the same MSTI.

It is not recommended that you specify two or more root switches for an MSTI. You can designatemultiple secondary root switches for an MSTI. In general, you are recommended to designateone root switch and multiple secondary root switches for an MSTI.

Do as follows on the S-switch that needs to join the MST region and to be the root switch orsecondary root switch.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-7

Page 180: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp [ instance instance-id ] root primary

The S-switch is configured as the root switch.

Or run:

stp [ instance instance-id ] root secondary

The S-switch is configured as the secondary root switch.

By default, the S-switch serves as neither the root switch nor the secondary root switch of thespanning tree.

This configuration procedure is optional. If you need to set the S-switch as the root switch orthe secondary root switch, perform this configuration procedure.

----End

9.3.6 (Optional) Setting the Priority of the S-switch in a SpecifiedMSTI

Context

CAUTIONIf the current S-switch has been configured as the root switch or secondary root switch, its prioritycannot be set. To set the priority of the current S-switch, you must first disable the root switchor secondary root switch function.

Do as follows on the S-switch whose priority in the specified MSTI needs to be set.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp [ instance instance-id ] priority priority

The priority of the S-switch is set in the specified MSTI.

The lower value of the priority, the higher the priority of the S-switch and the more the possibilityof the S-switch being selected as the root switch. The priority of the root switch or secondary

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 181: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

root switch must be higher than that of other S-switches. Otherwise, the root switch or thesecondary root switch may lose its position. By default, the priority of the S-switch is 32768.

----End

9.3.7 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check the MST region configuration thathas taken effect.

display stp region-configuration

After the configuration succeeds, the MST region of the S-switch is correctly configured whenyou run the display stp region-configuration command to view the configuration of the MSTregion of the S-switch.

9.4 Configuring MSTP Parameters of the S-switchThis section describes how to configure MSTP parameters of the S-switch.

9.4.1 Establishing the Configuration Task

9.4.2 (Optional) Configuring MSTP Network Parameters of the S-switch

9.4.3 (Optional) Configuring MSTP Parameters of an Interface

9.4.4 (Optional) Switching an Interface to the MSTP Mode

9.4.1 Establishing the Configuration Task

Applicable Environment

In some specific networks, it is necessary to adjust MSTP parameters of some S-switches tooptimize their performance.

Pre-configuration Tasks

Before adjusting MSTP parameters of the S-switch, you need to complete the following tasks:

l Configuring physical attributes of the interface

l Configuring VLAN features of the interface

l Adding an S-switch to a specified MST region

Data Preparation

Before adjusting MSTP parameters of the S-switch, you need the following data.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-9

Page 182: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

No. Data

1 (Optional) Value of Hello Time

2 (Optional) Value of Forward Delay

3 (Optional) Value of Max Age

4 (Optional) Priority of the S-switch in the specified MSTI

5 (Optional) Network diameter

6 (Optional) Maximum number of hops of the spanning tree in an MST region

7 (Optional) Number of the interface on which to enable or disable MSTP

8 (Optional) Priority of the interface in the specified MSTI

9 (Optional) Path cost of an interface

10 (Optional) Maximum transmission speed of an interface

9.4.2 (Optional) Configuring MSTP Network Parameters of the S-switch

ContextIt is not recommended to directly set the value of Hello Time, Forward Delay, or Max Age. Itis recommended to run the stp bridge-diameter command to set the network diameter. The S-switch automatically calculates optimum values of Hello Time, Forward Delay, and MaxAge according to the network diameter.

NOTE

To prevent frequent route flapping, values of Hello Time, Forward Delay, and Max Age must meet thefollowing conditions:

2 × (Forward Delay - 1.0 second) >= Max Age

Max Age >= 2 × (Hello Time + 1.0 second)

Do as follows on the S-switch where MSTP network parameters need to be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp bridge-diameter diameter

The network diameter is set.

By default, the value of the network diameter is 7.

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-10 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 183: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Step 3 Run:stp timer forward-delay forward-delay

The value of Forward Delay is set on the S-switch.

By default, the value of Forward Delay is 1500, in centiseconds, that is, 15, in seconds.

Step 4 Run:stp timer hello hello-time

The value of Hello Time is set on the S-switch.

By default, the value of Hello Time is 200, in centiseconds, that is, 2, in seconds.

Step 5 Run:stp timer max-age max-age

The value of Max Age is set on the S-switch.

By default, the value of Max Age is 2000, in centiseconds, that is, 20, in seconds.

Step 6 Run:stp max-hops hop

The maximum number of hops is set in an MST region.

By default, the maximum number of hops in an MST region is 20.

Step 7 Run:stp pathcost-standard { dot1d-1998 | dot1t | legacy }

The standard is specified to calculate the path cost of an interface.

By default, IEEE 802.1t standard method is used to calculate the default value of the path cost.It is recommended that you use the same standard to calculate path costs of interfaces on all S-switches in the same network.

NOTE

When you change the method to calculate the path cost of an interface, the path cost of the interface isrestored to the default value.

----End

9.4.3 (Optional) Configuring MSTP Parameters of an Interface

Context

CAUTIONWhen MSTP is disabled on an interface, a loop may occur.

Do as follows on the S-switch where MSTP parameters need to be set on an interface.

Step 4 and Step 9 are optional and not listed in sequence.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-11

Page 184: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

ProcedureStep 1 Run:

system-view

The system view is displayed.

Step 2 Run:stp interface { interface-type interface-number [ to interface-number ] }&<1-10> { enable | disable }

MSTP is enabled on an interface.

Step 3 Run:bpdu enable

The S-switch is enabled to process BPDUs.

Step 4 Run:stp interface { interface-type interface-number [ to interface-number ] }&<1-10> edged-port { enable | disable }

An interface is set to an edge interface.

The interface type can be Eth-Trunk, or Gigabit Ethernet (GE).

By default, an interface is a non-edge interface.

Step 5 Run:stp interface { interface-type interface-number [ to interface-number ] }&<1-10> point-to-point { auto | force-false | force- true }

The interface is connected to a point-to-point (P2P) link.

By default, an interface automatically identifies whether it is connected to a P2P link.

Step 6 Run:stp interface { interface-type interface-number [ to interface-number ] }&<1-10> instance instance-id port priority priority

The priority of an interface is set in the specified MSTI.

By default, the priority of an interface in the specified MSTI is 128.

Step 7 Run:stp interface { interface-type interface-number [ to interface-number ] }&<1-10> [ instance instance-id ] cost cost

The path cost of an interface is set in the specified MSTI.

By default, MSTP calculates the path cost of an interface.

Step 8 Run:stp interface { interface-type interface-number [ to interface-number ] }&<1-10> transmit-limit packet-number

The maximum number of BPDUs that an interface can send in a Hello Time is set.

By default, the maximum number of BPDUs that an interface can send in a Hello Time is 3.

Step 9 Run:stp converge { fast | normal }

The STP convergence mode of an interface is set.

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-12 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 185: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

By default, the STP convergence mode of an interface is fast.

----End

9.4.4 (Optional) Switching an Interface to the MSTP Mode

Switching One or More Interfaces to the MSTP Mode

ContextDo as follows on the S-switch where one or more interfaces need to be switched to the MSTPmode.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp interface interface-type interface-number [ to interface-number ] }&<1-10> mcheck

The MCheck operation is performed.

----End

Switching One Interface to the MSTP Mode

ContextDo as follows on the S-switch where one interface needs to be switched to the MSTP mode.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view

Or run:

interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:stp mcheck

The MCheck operation is performed.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-13

Page 186: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

The MCheck operation can be performed only if the S-switch runs MSTP. The MCheck operation is invalidwhen the S-switch runs in STP compatible mode.

----End

9.5 Configuring MSTP Protection on the S-switchThis section describes how to configure MSTP protection on the S-switch.

9.5.2 (Optional) Configuring BPDU Protection on the S-switch to 9.5.4 (Optional)Configuring Loop Protection on an Interface are optional and not listed in sequence.

9.5.1 Establishing the Configuration Task

9.5.2 (Optional) Configuring BPDU Protection on the S-switch

9.5.3 (Optional) Configuring Root Protection on an Interface

9.5.4 (Optional) Configuring Loop Protection on an Interface

9.5.5 Checking the Configuration

9.5.1 Establishing the Configuration Task

Applicable Environment

It is recommended to configure:

l BPDU protection on the S-switch with edge interfaces

l Root protection on the root switch

l Loop protection on the root interface and the alternate interface

NOTE

Each interface can be set with only one protection function. If you set BPDU protection on the S-switchand set root protection or loop protection on an interface of the S-switch, the interface cannot be set as anedge interface any longer. Thus, BPDU protection cannot take effect on the interface.

Pre-configuration Tasks

Before configuring MSTP protection on the S-switch, you need to complete the following tasks:

l Configuring physical attributes of the interface

l Configuring VLAN features of the interface

l Adding an S-switch to a specified MST region

l Setting the interface as an edge interface before configuring BPDU protection

Data Preparation

To configure MSTP protection on the S-switch, you need the following data.

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-14 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 187: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

No. Data

1 (Optional) Number of the interface on which root protection is to be enabled

2 (Optional) Number of the interface on which loop protection is to be enabled

9.5.2 (Optional) Configuring BPDU Protection on the S-switch

Context

Do as follows on the S-switch on which BPDU protection needs to be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp bpdu-protection

BPDU protection is configured on the S-switch.

----End

9.5.3 (Optional) Configuring Root Protection on an Interface

Configuring Root Protection on an Interface in the System View

Context

Do as follows on the S-switch on which root protection needs to be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp interface interface-type interface-number [ to interface-number ] }&<1-10> root-protection

Root protection is configured on an interface.

----End

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-15

Page 188: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Configuring Root Protection on an Interface in the Interface View

Context

Do as follows on the S-switch on which root protection needs to be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view is displayed.

Or run:

interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:stp root-protection

Root protection is configured on the S-switch.

NOTE

The interface to be configured with root protection must be a specified interface in all MSTIs.

----End

9.5.4 (Optional) Configuring Loop Protection on an Interface

Configuring Loop Protection on an Interface in the System View

Context

Do as follows on the S-switch on which loop protection needs to be configured.

Procedure

Step 1 Run the system-view command to enter the system view.

Step 2 Run the stp interface { interface-type interface-number [ to interface-number ] }&<1-10> loop-protection command to configure loop protection on the S-switch.

----End

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-16 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 189: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Configuring Loop Protection on an Interface in the Interface View

ContextDo as follows on the S-switch on which loop protection needs to be configured.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The Ethernet interface view or GE interface view is displayed.

Or run:

interface eth-trunk trunk-id

The Eth-Trunk interface view is displayed.

Step 3 Run:stp loop-protection

Loop protection is configured on the S-switch.

----End

9.5.5 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check the status of an interface inthe MSTI.

display stp [ instance instance-id ] [ slot slot-number |interface { interface-type interface-number [ tointerface-number ] }&<1-10> ] [ brief ]

If the configuration succeeds, you can find that the protection function of the interface is correctlyset.

9.6 Maintaining MSTPThis section describes how to monitor MSTP, clear the MSTP statistics, and debug MSTP.

9.6.1 Displaying MSTP Running Information

9.6.2 Clearing MSTP Statistics

9.6.3 Debugging MSTP

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-17

Page 190: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

9.6.1 Displaying MSTP Running Information

After the previous configurations are complete, run the following command in any view to checkMSTP running information and verify the configuration. For details on MSTP runninginformation, refer to the Quidway S2300 Series Ethernet Switches Command Reference.

Action Command

Display the status and statistics ofthe spanning tree.

display stp [ instance instance-id ] [ slot slot-number |interface { interface-type interface-number [ tointerface-number ] }&<1-10> ] [ brief ]

9.6.2 Clearing MSTP Statistics

CAUTIONMSTP statistics cannot be restored after you clear them. Therefore, confirm the action beforeyou use the command.

After you confirm that MSTP statistics need to be cleared, run the following command in theuser view.

Action Command

Clear MSTP statistics on thespanning tree.

reset stp [ interface { interface-type interface-number[ to interface-number ] }&<1-10> ] statistics

9.6.3 Debugging MSTP

CAUTIONEnabling debugging affects the system performance. Therefore, after debugging, run the undodebugging all command to disable debugging immediately.

When an MSTP fault occurs, run the following commands in the user view to debug MSTP,view debugging information, locate and analyze the fault. For how to enable debugging, referto the chapter "Monitoring and Debugging" in the Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Device Management. For descriptions of the debugging commands, referto the Quidway S2300 Series Ethernet Switches Command Reference.

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-18 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 191: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Action Command

Enable debugging of a specifiedMSTI.

debugging stp instance instance-id event

Enable MSTP debugging. debugging stp { all | global-event | global-error |msti { instance-id1 [ to instance-id2 }&<1-10> }

Enable BPDU and event debuggingon a specified interface.

debugging stp [ interface interface-type interface-number ] { event | packet { all | receive | send } }

9.7 Configuration ExamplesThis section provides MSTP configuration examples.

9.7.1 Example for Configuring MSTP

9.7.1 Example for Configuring MSTP

Networking RequirementsAs shown in Figure 9-1, S-switch-A and S-switch-C are configured to work in a region namedRG 1, and MSTI 1 is created. S-switch-B and S-switch-D are configured to work in anotherregion named RG 2 and MSTI 1 is created.

S-switch-C is configured to be the common and internal spanning tree (CIST) root. In regionRG 1, S-switch-C is the region root of CIST and the region root of MSTI 1. Root protection isapplied on Ethernet 0/0/2 and Ethernet 0/0/1 of S-switch-C. In region RG 2, S-switch-D is theregion root of CIST and S-switch-B is the region root of MSTI 1.

Both S-switch-A and S-switch-B are downstream attached with a L2 Switch through Ethernet0/0/1. Set Ethernet 0/0/1 as the edge interface and apply BPDU protection on S-switch-A andS-switch-B.

S-switch-A, S-switch-B, S-switch-C, and S-switch-D all use Huawei private algorithm forcalculating path costs.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-19

Page 192: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Figure 9-1 Networking diagram for configuring basic MSTP functions

Eth0/0/1

S-switch-A

S-switch-D

S-switch-B

S-switch-CRG1 RG2

Eth0/0/2 Eth0/0/2Eth0/0/1

Eth0/0/1Eth0/0/2

Eth0/0/3

Eth0/0/2Eth0/0/1

Eth0/0/3

Configuration RoadmapThe configuration roadmap is as follows:

l Configuring an MST region on S-switch-C, S-switch-D, S-switch-A and S-switch-B

l Setting priorities of S-switch-C, S-switch-D, and S-switch-B in MSTIs,to determine its rolein specified MSTIs.

l Configuring VLANs

l Configuring the protection function

l Configuring the S-switch to process BPDUs

l Enabling MSTP on S-switch-C, S-switch-D, S-switch-A and S-switch-B

Data PreparationTo complete the configuration, you need the following data:

l Names of two MST regions: RG1 and RG2.

l S-switch-A, S-switch-B, S-switch-C and S-switch-D all use Huawei legacy standard tocalculate the path cost of their interfaces

Configuration Procedure1. Configure S-switch-C.

# Configure the MST region on S-switch-C.<Quidway> system-view[Quidway] sysname S-switch-C[S-switch-C] stp region-configuration[S-switch-C-mst-region] region-name RG1[S-switch-C-mst-region] instance 1 vlan 1 to 10

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-20 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 193: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

# Activate the region configuration on S-switch-C.[S-switch-C-mst-region] active region-configuration[S-switch-C-mst-region] quit# Set the priority of S-switch-C in MSTI 0 to 0 to ensure that S-switch-C serves as the CISTroot.[S-switch-C] stp instance 0 priority 0# Set the priority of S-switch-C in MSTI 1 to 0 to ensure that S-switch-C serves as theregion root of MSTI 1.[S-switch-C] stp instance 1 priority 0# Configure the algorithm for calculating interface path costs to Huawei private algorithm.[S-switch-C] stp pathcost-standard legacy# Create VLAN 1 to VLAN 20.[S-switch-C] vlan batch 1 to 20# Add Ethernet 0/0/1 to the VLANs.[S-switch-C] interface ethernet 0/0/1[S-switch-C-Ethernet0/0/1] port trunk allow-pass vlan 1 to 20[S-switch-C-Ethernet0/0/1] quit# Add Ethernet 0/0/2 to the VLANs.[S-switch-C] interface ethernet 0/0/2[S-switch-C-Ethernet0/0/2] port trunk allow-pass vlan 1 to 20[S-switch-C-Ethernet0/0/2] quit# Enable root protection on Ethernet 0/0/1.[S-switch-C] interface ethernet 0/0/1[S-switch-C-Ethernet0/0/1] stp root-protection[S-switch-C-Ethernet0/0/1] quit# Enable root protection on Ethernet 0/0/2.[S-switch-C] interface ethernet 0/0/2[S-switch-C-Ethernet0/0/2] stp root-protection[S-switch-C-Ethernet0/0/2] quit# Configure the S-switch-C to process BPDUs.[S-switch-C] bpdu enable# Enable MSTP.[S-switch-C] stp enable

2. Configure S-switch-D.# Configure the MST region on S-switch-D.<Quidway> system-view[Quidway] sysname S-switch-D[S-switch-D] stp region-configuration[S-switch-D-mst-region] region-name RG2[S-switch-D-mst-region] instance 1 vlan 1 to 10# Activate the region configuration on S-switch-D.[S-switch-D-mst-region] active region-configuration[S-switch-D-mst-region] quit# Set the priority of S-switch-D in MSTI 0 to 4096 to ensure that S-switch-D serves as theregion root of MSTI 0 in RG 2.[S-switch-D] stp instance 0 priority 4096# Configure the algorithm for calculating interface path costs to Huawei private algorithm.[S-switch-D] stp pathcost-standard legacy# Create VLAN 1 to VLAN 20.[S-switch-D] vlan batch 1 to 20

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-21

Page 194: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

# Add Ethernet 0/0/1 to the VLANs.[S-switch-D] interface ethernet 0/0/1[S-switch-D-Ethernet0/0/1] port trunk allow-pass vlan 1 to 20[S-switch-D-Ethernet0/0/1] quit# Add Ethernet 0/0/2 to the VLANs.[S-switch-D] interface ethernet 0/0/2[S-switch-D-Ethernet0/0/2] port trunk allow-pass vlan 1 to 20[S-switch-D-Ethernet0/0/2] quit# Configure the S-switch-D to process BPDUs.[S-switch-D] bpdu enable# Enable MSTP.[S-switch-D] stp enable

3. Configure S-switch-A.# Configure the MST region on S-switch-A.<Quidway> system-view[Quidway] sysname S-switch-A[S-switch-A] stp region-configuration[S-switch-A-mst-region] region-name RG1[S-switch-A-mst-region] instance 1 vlan 1 to 10# Activate the region configuration on S-switch-A.[S-switch-A-mst-region] active region-configuration[S-switch-A-mst-region] quit# Configure the algorithm for calculating interface path costs to Huawei private algorithm.[S-switch-A] stp pathcost-standard legacy# Enable BPDU protection.[S-switch-A] stp bpdu-protection# Create VLAN 1 to VLAN 20.[S-switch-A] vlan batch 1 to 20# Add Ethernet 0/0/2 to the VLANs.[S-switch-A] interface ethernet 0/0/2[S-switch-A-Ethernet0/0/2] port trunk allow-pass vlan 1 to 20[S-switch-A-Ethernet0/0/2] quit# Add Ethernet 0/0/3 to the VLANs.[S-switch-A] interface ethernet 0/0/3[S-switch-A-Ethernet0/0/3] port trunk allow-pass vlan 1 to 20[S-switch-A-Ethernet0/0/3] quit# Set Ethernet 0/0/1 as the edge interface.[S-switch-A] interface ethernet 0/0/1[S-switch-A-Ethernet0/0/1] stp edged-port enable[S-switch-A-Ethernet0/0/1] quit# Configure the S-switch-A to process BPDUs.[S-switch-A] bpdu enable# Enable MSTP.[S-switch-A] stp enable

4. Configure S-switch-B.# Configure the MST region on S-switch-B.<Quidway> system-view[Quidway] sysname S-switch-B[S-switch-B] stp region-configuration[S-switch-B-mst-region] region-name RG2[S-switch-B-mst-region] instance 1 vlan 1 to 10# Activate the region configuration on S-switch-B.

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-22 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 195: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

[S-switch-B-mst-region] active region-configuration[S-switch-B-mst-region] quit# Set the priority of S-switch-B in MSTI 1 to 0 to ensure that S-switch-B serves as theregion root of MSTI 1.[S-switch-B] stp instance 1 priority 0# Configure the algorithm for calculating interface path costs to Huawei private algorithm.[S-switch-B] stp pathcost-standard legacy# Enable BPDU protection.[S-switch-B] stp bpdu-protection# Create VLAN 1 to VLAN 20.[S-switch-B] vlan batch 1 to 20# Add Ethernet 0/0/1 to the VLANs.[S-switch-B] interface ethernet 0/0/1[S-switch-B-Ethernet0/0/1] port trunk allow-pass vlan 1 to 20[S-switch-B-Ethernet0/0/1] quit# Add Ethernet 0/0/2 to the VLANs.[S-switch-B] interface ethernet 0/0/2[S-switch-B-Ethernet0/0/2] port trunk allow-pass vlan 1 to 20[S-switch-B-Ethernet0/0/2] quit# Add Ethernet 0/0/3 to the VLANs.[S-switch-B] interface ethernet 0/0/3[S-switch-B-Ethernet0/0/3] port trunk allow-pass vlan 1 to 20[S-switch-B-Ethernet0/0/3] quit# Set Ethernet 0/0/1 as the edge interface.[S-switch-B] interface ethernet 0/0/1[S-switch-B-Ethernet0/0/1] stp edged-port enable[S-switch-B-Ethernet0/0/1] quit# Configure S-switch-B to process BPDUs.[S-switch-B] bpdu enable# Enable MSTP.[S-switch-B] stp enable

5. Verify the configuration.After the pevious configurations are complete, run the following commands to verify theconfiguration:# Run the display stp brief command on S-switch-C to view the interface status andprotection type. The displayed information is as follows:<S-switch-C> display stp briefMSTID Port Role STP State Protection0 Ethernet0/0/2 DESI FORWARDING ROOT0 Ethernet0/0/1 DESI FORWARDING ROOT1 Ethernet0/0/2 DESI FORWARDING ROOT1 Ethernet0/0/1 DESI FORWARDING ROOTThe priority of S-switch-C is the highest in CIST. Therefore, S-switch-C serves as both theCIST root and the region root of RG 1. Ethernet 0/0/1 and Ethernet 0/0/2 on S-switch-Care specified interfaces in CIST.The priority of S-switch-C is the highest in MSTI 1 in region RG 1. Therefore, S-switch-C serves as the region root of MSTI 1. Ethernet 0/0/1 and Ethernet 0/0/2 serve as specifiedinterfaces in MSTI 1.# Run the display stp interface brief command on S-switch-A. The displayed informationis as follows:<S-switch-A> display stp interface ethernet 0/0/3 brief

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-23

Page 196: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

MSTID Port Role STP State Protection0 Ethernet0/0/3 ROOT FORWARDING NONE1 Ethernet0/0/3 ROOT FORWARDING NONE<S-switch-A> display stp interface gigabitethernet 0/0/2 briefMSTID Port Role STP State Protection0 Ethernet0/0/2 DESI FORWARDING NONE1 Ethernet0/0/2 DESI FORWARDING NONEEthernet 0/0/3 of S-switch-A is the root interface in CIST and MSTI 1. Ethernet 0/0/2 ofS-switch-A is the specified interface of CIST and that of MSTI 1.# Run the display stp brief command on S-switch-D. The displayed information is asfollows:<S-switch-D> display stp briefMSTID Port Role STP State Protection0 Ethernet0/0/2 ROOT FORWARDING NONE0 Ethernet0/0/1 DESI FORWARDING NONE1 Ethernet0/0/2 MAST FORWARDING NONE1 Ethernet0/0/1 ROOT FORWARDING NONEThe priority of S-switch-D in CIST is lower than that of S-switch-C. Therefore, Ethernet0/0/2 serves as the root interface in CIST. Meanwhile, S-switch-C and S-switch-D belongto different regions. Therefore, Ethernet 0/0/2 serves as the Master interface in MSTI 1.In MSTI 1, the priority of S-switch-D is lower than that of S-switch-B. Therefore, Ethernet0/0/1 serves as the root interface. The priority of S-switch-D in CIST is higher than that ofS-switch-B. Therefore, Ethernet 0/0/1 serves as the specified interface in CIST.# Run the display stp interface brief command on S-switch-B. The displayed informationis as follows:<S-switch-B> display stp interface ethernet 0/0/3 briefMSTID Port Role STP State Protection0 Ethernet0/0/3 ROOT FORWARDING NONE1 Ethernet0/0/3 DESI FORWARDING NONE<S-switch-B> display stp interface ethernet 0/0/2 briefMSTID Port Role STP State Protection0 Ethernet0/0/2 ALTE DISCARDING NONE1 Ethernet0/0/2 ALTE DISCARDING NONEOn S-switch-B, Ethernet 0/0/2 serves as the alternate interface in CIST. Meanwhile, S-switch-B and S-switch-A are in different regions. Therefore, Ethernet 0/0/2 also serves asthe alternate interface in MSTI 1. Ethernet 0/0/3 serves as the root interface in CIST. Thepriority of S-switch-B in MSTI 1 is higher than that of S-switch-D in MSTI 1. Therefore,Ethernet 0/0/3 serves as the specified interface in MSTI 1.

Configuration Filesl Configuration file of S-switch-A

# sysname S-switch-Avlan batch 1 to 20## bpdu enable#stp bpdu-protectionstp pathcost-standard legacystp enablestp region-configuration region-name RG1 instance 1 vlan 1 to 10 active region-configuration#interface Ethernet0/0/1 stp edged-port enable#

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-24 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 197: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

interface Ethernet0/0/2 port trunk allow-pass vlan 1 to 20#interface Ethernet0/0/3 port trunk allow-pass vlan 1 to 20#return

l Configuration file of S-switch-B# sysname S-switch-B# bpdu enable#vlan batch 1 to 20#stp instance 1 priority 0stp bpdu-protectionstp pathcost-standard legacystp enablestp region-configuration region-name RG2 instance 1 vlan 1 to 10 active region-configuration#interface Ethernet0/0/1 stp edged-port enable#interface Ethernet0/0/2 port trunk allow-pass vlan 1 to 20# interface Ethernet0/0/3 port trunk allow-pass vlan 1 to 20#return

l Configuration file of S-switch-C# sysname S-switch-C# bpdu enable# vlan batch 1 to 20#stp instance 0 priority 0stp instance 1 priority 0 stp pathcost-standard legacystp enablestp region-configuration region-name RG1 instance 1 vlan 1 to 10 active region-configuration#interface Ethernet0/0/1 port trunk allow-pass vlan 1 to 20 stp root-protection#interface Ethernet0/0/2 port trunk allow-pass vlan 1 to 20 stp root-protection#return

l Configuration file of S-switch-D# sysname S-switch-D# bpdu enable# vlan batch 1 to 20

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 9 MSTP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

9-25

Page 198: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

#stp instance 0 priority 4096stp pathcost-standard legacystp enablestp region-configuration region-name RG2 instance 1 vlan 1 to 10active region-configuration#interface Ethernet0/0/1 port trunk allow-pass vlan 1 to 20#interface Ethernet0/0/2 port trunk allow-pass vlan 1 to 20#return

9 MSTP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

9-26 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 199: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10 BPDU Tunneling and Partitioned STPConfiguration

About This Chapter

This chapter describes the basics, methods, and examples for configuring Bridge Protocol DataUnit (BPDU) tunneling and partitioned Spanning Tree Protocol (STP).

10.1 IntroductionThis section describes basic concepts of BPDU tunneling and partitioned STP.

10.2 Configuring Interface-based Transparent Transmission of BPDUs from the Same CustomerNetworkThis section describes the procedure for configuring interface-based transparent transmission ofBPDUs from the same customer network.

10.3 Configuring Interface-based Transparent Transmission of BPDUs from Different CustomerNetworksThis section describes the procedure for configuring interface-based transparent transmission ofBPDUs from different customer networks.

10.4 Configuring VLAN-based BPDU TunnelingThis section describes the procedure for configuring VLAN-based BPDU tunneling.

10.5 Configuring Partitioned STPThis section describes the procedure for configuring partitioned STP.

10.6 MaintainingThis section describes how to set the bandwidth consumed by BPDUs sent to the queues on theCPU and how to check and clear statistics about discarded BPDUs.

10.7 Configuration ExamplesThis section provides examples for configuring the Multiple Spanning Tree Protocol (MSTP),BPDU tunneling, and partitioned STP.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-1

Page 200: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10.1 IntroductionThis section describes basic concepts of BPDU tunneling and partitioned STP.

10.1.1 BPDU Tunneling

10.1.2 Partitioned STP

10.1.3 Logic Relationships Between Configuration Tasks

10.1.1 BPDU Tunneling

NOTE

S2300SI does not support BPDU Tunneling.

The S-switch can forward tagged BPDUs as common Layer 2 data frames in the VLAN to whichthe BPDUs belong without sending them to the local STP module for processing. Thistechnology is known as BPDU tunneling.

To transparently transmit BPDUs across a provider network, the following conditions must bemet:

l Every branch of a customer network must be able to receive the BPDUs sent by the customernetwork.

l The BPDUs of a customer network should not be processed by the central processing unit(CPU) of the provider network.

l BPDUs of different customer networks are isolated and do not affect each other.

10.1.2 Partitioned STP

With the partitioned STP technology, users of the same customer network but in different areascan transparently transmit BPDUs across the provider network, and spanning trees can becalculated uniformly in the customer network. In addition, the spanning tree of the customernetwork and that of the provider network are irrelevant to each other.

The partitioned STP technology is the extension of the BPDU tunneling technology, whichbrings the following advantages:

l Link switching is implemented locally to confine the effect of a link change as much aspossible to the local node.

l Service switching speeds up. When services are switched between the links of the localnode, other nodes are informed to update the related entries. In this manner, services canbe quickly recovered.

10.1.3 Logic Relationships Between Configuration TasksThe features of partitioned STP, with the convergence function added and link switching speededup, are the extensions and improvements of the BPDU tunneling technology. Therefore, BPDUtunneling must be enabled before the configuration of partitioned STP.

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-2 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 201: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10.2 Configuring Interface-based TransparentTransmission of BPDUs from the Same Customer Network

This section describes the procedure for configuring interface-based transparent transmission ofBPDUs from the same customer network.

10.2.1 Establishing the Configuration Task

10.2.2 Enabling STP and Enabling the BPDU Function on CEs

10.2.3 Configuring the Provider Mode for UPEs

10.2.4 Enabling UPEs to Process BPDUs

10.2.5 Checking the Configuration

10.2.1 Establishing the Configuration Task

Applicable Environment

Each branch of a customer network has the STP function enabled and is connected to aUnderlayer Provider Edge (UPE) which connects no other customer networks. BPDUs from thecustomer network need to be transparently transmitted over the provider network.

You need to specify the Customer Edges (CEs) and the UPEs so that BPDUs from the customernetwork can be transparently transmitted across the provider network without being sent to theCPUs of the UPEs for processing. BPDUs from the customer network are processed by the CPUson the CEs and then forwarded across the provider network.

NOTE

If the provider network across which BPDUs are transparently transmitted is simple in structure and alldevices on the middle link are S-switchs, you can enable all these devices to process BPDUs.

Pre-configuration Tasks

Before configuring interface-based transparent transmission of BPDUs from the same customernetwork, complete the following task:

l Configuring the basic functions of the customer network and the provider network

Data Preparation

To configure interface-based transparent transmission of BPDUs from the same customernetwork, you need the following data.

No. Data

1 Numbers of the UPE interfaces at the CE side.

2 Numbers of the CE interfaces at the network side.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-3

Page 202: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10.2.2 Enabling STP and Enabling the BPDU Function on CEs

ContextDo as follows on the CEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp enable

STP is enabled.

Step 3 Run:bpdu enable

The CE is enabled to process BPDUs.

----End

10.2.3 Configuring the Provider Mode for UPEs

ContextDo as follows on the UPEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu-tunnel stp bridge role provider

The provider mode is configured.

NOTE

The destination MAC address of BPDUs is fixed and does not vary with devices.

When a UPE runs in provider mode, it transmits only STP BPDUs with MAC address 01-80-c2-00-00-08.

When a UPE runs in customer mode, it transmits only STP BPDUs with MAC address 01-80-c2-00-00-00.

By default, S-switch is in customer mode.

----End

10.2.4 Enabling UPEs to Process BPDUs

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-4 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 203: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Context

CAUTIONEnable the UPE to process BPDUs before configuring BPDU tunneling; otherwise, BPDUs arediscarded.

Do as follows on UPEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu enable

The UPE is enabled to process BPDUs.

----End

10.2.5 Checking the ConfigurationRun the following command to check the previous configuration.

Action Command

Check the global configuration of BPDUTunnel.

display bpdu-tunnel global config

NOTE

The display bpdu-tunnel global config command is valid only in the system view.

Run the display bpdu-tunnel global config command on a UPE, and you can view the role ofthe UPE and the multicast MAC address of STP BPDUs.

10.3 Configuring Interface-based TransparentTransmission of BPDUs from Different CustomerNetworks

This section describes the procedure for configuring interface-based transparent transmission ofBPDUs from different customer networks.

10.3.1 Establishing the Configuration Task

10.3.2 Enabling STP and Enabling the BPDU Function on CEs

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-5

Page 204: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10.3.3 Enabling UPEs to Process BPDUs

10.3.4 Adding the UPE Interfaces to the Specified VLAN in Untagged Mode

10.3.5 (Optional) Replacing the MAC Address of BPDUs with a Multicast MAC Address onthe UPEs

10.3.6 Enabling BPDU Tunneling on the UPEs

10.3.7 Checking the Configuration

10.3.1 Establishing the Configuration Task

Applicable EnvironmentA UPE interface at the CE side is connected to only one customer network. BPDUs fromcustomer networks are untagged. You need to configure interface-based BPDU tunneling totransparently transmit BPDUs from different customer networks across a provider network ofLayer 2 to the destinations. In this manner, the STP function can be implemented.

NOTE

If the provider network across which BPDUs are transparently transmitted is complicated in structure,configure a multicast MAC address for BPDUs on the UPEs. Then, the provider network can automaticallysupport the traversing of BPDUs from the customer networks.

Pre-configuration TasksBefore configuring interface-based transparent transmission of BPDUs from different customernetworks, complete the following tasks:

l Configuring the basic functions of the customer networks and the provider network

Data PreparationTo configure interface-based transparent transmission of BPDUs from different customernetworks, you need the following data.

No. Data

1 Numbers of the UPE interfaces connected to the CEs.

2 Multicast MAC address to be used to replace the destination MAC address of BPDUs

3 IDs of the VLANs that the UPE interfaces connected to the CEs belong to

4 Numbers of the CE interfaces connected to the UPEs

10.3.2 Enabling STP and Enabling the BPDU Function on CEs

ContextDo as follows on the CEs.

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-6 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 205: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp enable

STP is enabled.

Step 3 Run:bpdu enable

The CE is enabled to process BPDUs.

----End

10.3.3 Enabling UPEs to Process BPDUs

ContextDo as follows on the UPEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu enable

The UPE interface at the CE side is enabled to process BPDUs.

----End

10.3.4 Adding the UPE Interfaces to the Specified VLAN inUntagged Mode

ContextDo as follows on the UPE interfaces connected to the CEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:vlan vlan-id

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-7

Page 206: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

A VLAN is created and the VLAN view is displayed.

Step 3 Run:port interface-type { interface-number1 [ to interface-number2 ] } &<1-10>

The UPE interface at the CE side is added to the specified VLAN.

NOTE

You can also run the port default vlan vlanid command on the UPE interfaces connected to the CEs toadd the interfaces to the specified VLAN in untagged mode.

The UPE interfaces at the network side and all the devices in the provider network allow the BPDUs ofthe specified VLAN to pass through.

----End

10.3.5 (Optional) Replacing the MAC Address of BPDUs with aMulticast MAC Address on the UPEs

ContextDo as follows on the UPEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu-tunnel stp group-mac group-mac

The destination MAC address of BPDUs is replaced with a multicast MAC address.

NOTE

By default, the multicast MAC address is 0100-0ccd-cdd0, which can be used for communication with thedevices of other vendors.

----End

10.3.6 Enabling BPDU Tunneling on the UPEs

ContextDo as follows on the UPE interfaces connected to the CEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-8 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 207: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Step 2 Run:interface interface-type interface-number

The interface view is displayed.

Step 3 Run:bpdu-tunnel enable

BPDU tunneling is enabled.

NOTE

After being enabled with BPDU tunneling, a UPE interface at the CE side transparently transmits thereceived BPDUs in the specified VLAN as data frames, without sending them to the CPU of the UPE forspanning tree calculation.

----End

10.3.7 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check the configuration of BPDUtunneling in the interface view.

display bpdu-tunnel interface config

Check the global configuration of BPDUtunneling.

display bpdu-tunnel global config

NOTE

The display bpdu-tunnel global config command is valid only in the system view.The display bpdu-tunnel interface config command is valid only in the interface view.

Run the display bpdu-tunnel global config command on a UPE, and you can view the role ofthe UPE and the multicast MAC address of STP BPDUs.

Run the display bpdu-tunnel interface config command, and you can view the BPDUconfiguration on the UPE interface including:

l Whether BPDUs sent from the interface are tagged

l Whether BPDU tunneling is configured on the interface

l Whether the interface allows tagged BPDUs to pass through

l Ethernet encapsulation type value of the outer tag

l Tag value of BPDUs sent from the interface

l Tag value of the BPDUs that the interface allows to pass through

10.4 Configuring VLAN-based BPDU TunnelingThis section describes the procedure for configuring VLAN-based BPDU tunneling.

10.4.1 Establishing the Configuration Task

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-9

Page 208: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10.4.2 Enabling STP and Enabling the BPDU Function on CEs

10.4.3 Enabling UPEs to Process BPDUs

10.4.4 Setting VLAN ID of the BPDUs that CE Interfaces Allow to Pass Trough

10.4.5 Tagging BPDUs on the CEs

10.4.6 (Optional) Replacing the MAC Address of BPDUs with a Multicast MAC Address onthe UPEs

10.4.7 Configuring Tagged BPDUs to Pass Through the BPDU Tunnel on UPEs

10.4.8 Checking the Configuration

10.4.1 Establishing the Configuration Task

Applicable Environment

When a UPE interface is connected to multiple customer networks, BPDUs from the CEs mustbe tagged to identify different users.

To transparently transmit BPDUs from the customer networks across the provider network, youneed to configure BPDU tunneling and replace the destination MAC address of BPDUs with amulticast MAC address on the UPEs.

Pre-configuration Tasks

Before configuring VLAN-based BPDU tunneling, complete the following tasks:

l Configuring the basic functions of the customer networks and the provider network

Data Preparation

To configure VLAN-based BPDU tunneling, you need the following data.

No. Data

1 Numbers of the UPE interfaces connected to the CEs.

2 Numbers of the CE interfaces connected to the UPEs

3 VLAN IDs of the BPDUs that the CE interfaces allow to pass through

4 Multicast MAC address to be used to replace the destination MAC address of BPDUs

10.4.2 Enabling STP and Enabling the BPDU Function on CEs

Context

Do as follows on the CEs.

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-10 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 209: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp enable

STP is enabled.

Step 3 Run:bpdu enable

The CE is enabled to process BPDUs.

----End

10.4.3 Enabling UPEs to Process BPDUs

ContextDo as follows on the UPEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu enable

The UPE interface at the CE side is enabled to process BPDUs.

----End

10.4.4 Setting VLAN ID of the BPDUs that CE Interfaces Allow toPass Trough

ContextDo as follows on the CE interfaces connected to the UPEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-11

Page 210: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

The view of the CE interface at the network side is displayed.

Step 3 Run:port trunk allow-pass vlan { { vlan-id1 [ to vlan-id2 ] } & <1-10> | all }

The VLAN ID of the BPDUs that the CE interface allows to pass through is set.

----End

10.4.5 Tagging BPDUs on the CEs

Context

Do as follows on the CE interfaces connected to the UPEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The view of the CE interface at the network side is displayed.

Step 3 Run:stp bpdu vlan vlan-id

The BPDUs to be sent to the UPE are tagged with the VLAN ID.

----End

10.4.6 (Optional) Replacing the MAC Address of BPDUs with aMulticast MAC Address on the UPEs

Context

Do as follows on the UPEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu-tunnel stp group-mac group-mac

The MAC address of BPDUs is replaced with a multicast MAC address.

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-12 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 211: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

By default, the UPE replaces the destination MAC address of Spanning Tree Protocol (STP) packets withthe multicast MAC address 0100-0ccd-cdd0, after BPDU tunneling is enabled. You can run the bpdu-tunnel stp group-mac command to replace the MAC address of BPDUs with a multicast MAC address.

The new MAC address of BPDUs must be a multicast address with the first two bits as 0x01 and must bewithin the range of 0100-0000-0000 to 01FF-FFFF-FFFE with 0180-c200-0000 to 0180-c200-002fexcluded.

----End

10.4.7 Configuring Tagged BPDUs to Pass Through the BPDUTunnel on UPEs

Context

Do as follows on the inbound UPE interfaces connected to the CEs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The view of the UPE interface at the CE side is displayed.

Step 3 Run:port trunk allow-pass vlan { { vlan-id1 [ to vlan-id2 ] } & <1-10> | all }

The VLAN ID of the BPDUs that the UPE interface allows to pass through is set.

Step 4 Run:bpdu-tunnel stp vlan vlan-id1 [ to vlan-id2 ]

The UPE is configured to transmit BPDUs with the specified tag value.

The VLAN ID is the tag value set for BPDUs on the CE connected to the UPE. Only BPDUswith the specified tag value can pass the UPE and travel through the BPDU tunnel.

NOTE

The UPE interface at the CE side must be added in the VLAN for transparent transmission through theport trunk allow-pass vlan command. Otherwise, the UPE interface at the CE side discards the receivedBPDUs.

Do not use the bpdu-tunnel stp vlan and bpdu-tunnel enable commands on the same interface. Otherwise,the system prompts "Exist bpdu tunnel collision config."

----End

10.4.8 Checking the ConfigurationRun the following commands to check the previous configuration.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-13

Page 212: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Action Command

Check the configuration of BPDU Tunnelin the interface view.

display bpdu-tunnel interface config

Check the global configuration of BPDUTunnel in the system view.

display bpdu-tunnel global config

NOTE

The display bpdu-tunnel global config command is valid only in the system view.

The display bpdu-tunnel interface config command is valid only in the interface view.

Run the display bpdu-tunnel global config command on a UPE, and you can view the role ofthe UPE and the multicast MAC address of BPDUs.

Run the display bpdu-tunnel interface config command, and you can view the BPDUconfiguration on the interface including:

l Whether the BPDUs sent from the interface are tagged

l Whether BPDU tunneling is configured on the interface

l Whether the interface allows tagged BPDUs to pass through

l Ethernet encapsulation type of the outer tag

l Tag value of the BPDUs sent from the interface

l Tag value of the BPDUs that the interface allows to pass through

10.5 Configuring Partitioned STPThis section describes the procedure for configuring partitioned STP.

10.5.1 Establishing the Configuration Task

10.5.2 Enabling STP and Enabling the BPDU Function

10.5.3 Enabling Interfaces Connected to the MAN to Tag BPDUs

10.5.4 Setting VLAN IDs of the BPDUs That the Interface at the Network Side Allows to PassThrough

10.5.5 Configuring the S-switch to Accept Tagged BPDUs

10.5.6 Configuring BPDU Tunneling

10.5.7 Enabling STP Snooping

10.5.8 Checking the Configuration

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-14 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 213: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10.5.1 Establishing the Configuration Task

Applicable Environment

When devices access a Metropolitan Area Network (MAN) in dual-homed mode, partitionedSTP helps in avoiding loops, limiting the size of the STP network, and speeding up theconvergence of the STP network.

NOTE

In this configuration task, unless otherwise stated:

l "S-switchs outside the MAN" refer to the devices that access the MAN in dual-homed mode, forexample, S-switch-C shown in Figure 10-1.

l "S-switchs at the edge of the MAN" refer to the devices through which the outside devices accessthe MAN in dual-homing mode, for example, S-switch-A and S-switch-B shown in Figure 10-1.

Figure 10-1 Networking of partitioned STP

Intranet......

S-switch-CS-switch-A

S-switch-B

......Metropolitan

AreaNetwork(MAN)

......

GE0/0/1 GE0/0/2

GE0/0/2GE0/0/2GE0/0/1

GE0/0/1

Pre-configuration Tasks

None

Data Preparation

To configure partitioned STP, you need the following data.

No. Data

1 VLAN IDs used in the partitioned STP network

2 Names of the UPE interfaces at the user side

3 Names of the CE interfaces at the network side

4 Multicast MAC address to be used to replace the destination MAC address of BPDUs

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-15

Page 214: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10.5.2 Enabling STP and Enabling the BPDU Function

ContextDo as follows on the S-switch-C outside the MAN.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp enable

MSTP is enabled.

By default, the MSTP function is disabled.

NOTE

When the MSTP function is enabled, the MSTP function is enabled on all interfaces by default.

Step 3 Run:bpdu enable

The S-switch is enabled to process BPDUs.

----End

10.5.3 Enabling Interfaces Connected to the MAN to Tag BPDUs

ContextDo as follows on the S-switch-C outside the MAN.

vlan-id, that is, the VLAN ID used in the partitioned STP network, in Step 2 and Step 5 shouldbe the same.

Perform Step 4 to Step 5 on the two interfaces connected to the MAN respectively to enablethem to tag BPDUs.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:vlan vlan-id

A VLAN is created and the VLAN view is displayed.

Step 3 Run:

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-16 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 215: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

quit

Exit from the VLAN view.

Step 4 Run:interface interface-type interface-number

The view of the interface connected to the MAN is displayed.

Step 5 Run:stp bpdu vlan vlan-id

The interface is enabled to tag BPDUs.

By default, an interface does not tag BPDUs.

----End

10.5.4 Setting VLAN IDs of the BPDUs That the Interface at theNetwork Side Allows to Pass Through

Context

Do as follows on S-switch-C outside the MAN.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:interface interface-type interface-number

The interface view of S-switch-C is displayed.

Step 3 Run:port trunk allow-pass vlan { { vlan-id1 [ to vlan-id2 ] } & <1-10> | all }

The VLAN IDs of the BPDUs that the network-side interface of S-switch-C allows to passthrough are set.

The VLAN IDs are those in the tags added by S-switch-C to the BPDUs. Only BPDUs fromspecified VLANs can be forwarded by the network-side interface of S-switch-C to the two S-switches at the edge of the MAN.

----End

10.5.5 Configuring the S-switch to Accept Tagged BPDUs

Context

Do as follows on the S-switch-A and S-switch-B at the edge of the MAN.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-17

Page 216: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu enable

The S-switch is enabled to process BPDUs.

Step 3 Run:interface interface-type interface-number

The interface view is displayed.

Step 4 Run:port trunk allow-pass vlan { { vlan-id1 [ to vlan-id2 ] }&<1-10> | all }

The interface is added to the specified VLAN.

The values of vlan-id1 and vlan-id2 are the VLAN IDs used in the partitioned STP network.

Step 5 Run:bpdu-tunnel stp vlan vlan-id1 [ to vlan-id2 ]

The BPDUs tagged with vlan-id1 or with the VLAN ID ranging from vlan-id1 to vlan-id2 areallowed to pass through the interface.

NOTE

You must use the port trunk allow-pass vlan command to add the interface to the VLAN where the BPDUtunnel is configured. Otherwise, BPDUs are discarded on the inbound interface.

The bpdu-tunnel stp vlan command and the bpdu-tunnel enable command cannot be configured on thesame interface. Otherwise, the system prompts the configuration collision by "Exist bpdu tunnel collisionconfig".

----End

10.5.6 Configuring BPDU Tunneling

Context

Do as follows on the S-switch-A and S-switch-B at the edge of the MAN.

NOTE

BPDUs can be transparently transmitted only based on their destination MAC address. Whether this MACaddress is a multicast MAC address cannot be identified. Therefore this MAC address must be dedicatedto this special use.

Do not use the port hybrid untagged vlan command to add the interfaces to the VLAN used for transparenttransmission of BPDUs. Otherwise, BPDU tunneling configured on the interfaces will be affected.

Step 2 is optional, without which the destination MAC address of BPDUs will be replaced withmulticast MAC address 0100-0ccd-cdd0.

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-18 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 217: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:bpdu-tunnel stp group-mac group-mac

The destination MAC address of BPDUs is replaced with a multicast MAC address.

Step 3 Run:interface interface-type interface-number or interface eth-trunk trunk-id

The view of the interface connected to the other S-switch at the edge of the MAN is displayed.

Step 4 Run:port trunk allow-pass vlan vlan-id

The interface connected to the other S-switch at the edge of the MAN is added to the VLAN.

----End

10.5.7 Enabling STP Snooping

Context

Do as follows on the two S-switchs at the edge of the MAN.

Procedure

Step 1 Run:system-view

The system view is displayed.

Step 2 Run:stp-snooping enable

STP snooping is enabled.

By default, STP snooping is disabled.

----End

10.5.8 Checking the ConfigurationRun the following commands to check the previous configuration.

Action Command

Check the configuration of the S-switch outside the MAN.

display current-configuration configuration system

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-19

Page 218: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Action Command

Check the configurations of theinterfaces connected to the MANon the S-switch outside the MAN.

display current-configuration interface interface-typeinterface-number

Check the configurations of theinbound interfaces on the S-switchs at the edge of the MAN.

display current-configuration interface interface-typeinterface-number

Check the configurations of theinterfaces through which theS-switchs at the edge of the MANare connected.

display current-configuration interface interface-typeinterface-number

Check the configurations of theS-switchs at the edge of the MAN.

display current-configuration configuration system

If the configurations succeed, you can view the following information by running the precedingcommands:

l MSTP is enabled on the S-switch outside the MAN.

l BPDUs are tagged correctly on the interfaces connected to the MAN on the S-switch outsidethe MAN.

l The VLAN ID and BPDU tunneling are configured correctly on the inbound interfaces onthe S-switchs at the edge of the MAN.

l The VLAN ID is set correctly on the interfaces through which the S-switchs at the edge ofthe MAN are connected.

l STP snooping is enabled on the S-switchs at the edge of the MAN.

10.6 MaintainingThis section describes how to set the bandwidth consumed by BPDUs sent to the queues on theCPU and how to check and clear statistics about discarded BPDUs.

10.6.1 Setting the Bandwidth Consumed by BPDUs Sent to the Queues on the CPU

10.6.2 Clearing Statistics about Discarded BPDUs

10.6.3 Checking Statistics About Discarded BPDUs

10.6.1 Setting the Bandwidth Consumed by BPDUs Sent to theQueues on the CPU

If packet loss occurs, you can run the cpu queue bpdu command to set the bandwidth consumedby BPDUs sent to the queues on the CPU.

You need to reduce the bandwidth consumed by BPDUs sent to the queues on the CPU untilpacket loss does not occur.

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-20 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 219: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTEIf no packet is lost, you can keep enlarging the bandwidth to make full use of system resources as long aspacket loss does not occur.

Action Command

Set the bandwidth consumed byBPDUs sent to the queues on theCPU.

cpu queue bpdu cir cir pir pir

10.6.2 Clearing Statistics about Discarded BPDUs

CAUTIONStatistics about discarded BPDUs cannot be restored after you clear it. So, confirm the actionbefore you use the command.

To clear statistics about discarded BPDUs, run the following command in the system view.

Action Command

Clear statistics about discardedBPDUs.

reset bpdu dropped-packet statistics

10.6.3 Checking Statistics About Discarded BPDUs

You can run the display bpdu dropped-packet statistics command to check statistics aboutdiscarded BPDUs. If any BPDU is lost, it indicates that the bandwidth of the queue to whichBPDUs are sent is too great for the software to process. Then, you can run the cpu queuebpdu command to set the bandwidth of the queue. In this manner, packet loss can be controlled.

After the preceding configuration, run the following command in system view to check statisticsabout discarded BPDUs.

Action Command

Check statistics about discardedBPDUs.

display bpdu dropped-packet statistics

10.7 Configuration ExamplesThis section provides examples for configuring the Multiple Spanning Tree Protocol (MSTP),BPDU tunneling, and partitioned STP.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-21

Page 220: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

10.7.1 Example for Configuring Interface-based BPDU Tunneling of the Same Customer

10.7.2 Example for Configuring Interface-based BPDU Tunnel of Different Customer

10.7.3 Example for Configuring VLAN-based BPDU Tunneling

10.7.4 Example for Configuring Partitioned STP

10.7.1 Example for Configuring Interface-based BPDU Tunnelingof the Same Customer

Networking Requirements

As shown in Figure 10-2, the CEs are connected to the provider network through the UPEs. TheUPEs are in provider mode. All devices on the link between the two UPEs are the S-switchs thatcan process BPDUs. In addition, the provider mode needs to be set for the devices between thetwo UPEs. In this scenario, the devices on the link for transparent transmission of BPDUs donot use BPDUs for STP calculation. Instead, they directly transmit BPDUs to the opposite UPE.

The UPEs broadcast BPDUs from the CEs to the entire provider network. In this manner, theprovider network automatically supports the traversing of BPDUs from the customer network.

Figure 10-2 Networking for configuring interface-based transparent transmission of BPDUsfrom the same customer network

MetropolitanArea

Network

CE-A UPE-A UPE-B CE-B

Eth0/0/1 Eth0/0/1

Eth0/0/1 Eth0/0/1

Configuration Roadmap

The configuration roadmap is as follows:

l Enable STP on the CEs, and enable the CEs to process BPDUs.

l Set the provider mode for UPE-A and UPE-B.

l Enable UPE-A and UPE-B to process BPDUs.

Data Preparation

To complete the configuration, you need the following data:

l Names of the CE interfaces connected to the UPEs

l Names of the UPE interfaces connected to the CEs

l Names of the interfaces on the link between the two UPEs

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-22 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 221: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Configuration Procedure1. Enable STP on the CEs, and enable the CEs to process BPDUs.

# Configure CE-A.<Quidway> system-view[Quidway] sysname CE-A[CE-A] stp enable[CE-A] bpdu enable# Configure CE-B.<Quidway> system-view[Quidway] sysname CE-B[CE-B] stp enable[CE-B] bpdu enable

2. Set the provider mode for the UPEs.# Configure UPE-A.<Quidway> system-view[Quidway] sysname UPE-A[UPE-A] bpdu-tunnel stp bridge role provider# Configure UPE-B.<Quidway> system-view[Quidway] sysname UPE-B[UPE-B] bpdu-tunnel stp bridge role provider

NOTEThe provider mode needs to be set for the devices between UPE-A and UPE-B. Otherwise, the deviceson the link for transparent transmission of BPDUs use BPDUs for STP calculation, and thus theBPDUs cannot be transmitted to the opposite UPEs. The configurations of the devices between thetwo UPEs are the same as those of the UPEs. Thus, it is not described in detail.

3. Enable the UPEs to process BPDUs.# Configure UPE-A.<UPE-A> system-view[UPE-A] bpdu enable# Configure UPE-B.<UPE-B> system-view[UPE-B] bpdu enable

4. Verify the configuration.# Check the global BPDU configuration.[UPE-A] display bpdu-tunnel global configBridgeRole providerMode BpduMac Multicastmac-------------------------------------------------------stp 0180-c200-0008 0100-0ccd-cdd0# Check the STP configuration on CE-A and CE-B to check that BPDU tunneling isconfigured successfully.[CE-A] display stp briefMSTID Port Role STP State Protection0 Ethernet0/0/1 ROOT FORWARDING NONE [CE-B] display stp briefMSTID Port Role STP State Protection0 Ethernet0/0/1 DESI FORWARDING NONE

Configuration Filesl Configuration file of CE-A

#

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-23

Page 222: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

sysname CE-A# stp enable#bpdu enable#return

l Configuration file of CE-B# sysname CE-B# stp enable#bpdu enable#return

l Configuration file of UPE-A# sysname UPE-A#bpdu enable# bpdu-tunnel stp bridge role provider#return

l Configuration file of UPE-B# sysname UPE-B#bpdu enable# bpdu-tunnel stp bridge role provider##return

10.7.2 Example for Configuring Interface-based BPDU Tunnel ofDifferent Customer

Networking RequirementsAs shown in Figure 10-3, Customer network 1 has STP enabled and connects the Ethernet 0/0/2interfaces on UPE-A and UPE-B; Customer network 2 also has STP enabled and connects theEthernet 0/0/1 interfaces on UPE-A and UPE-B.

By configuring interface-based transparent transmission of BPDUs from different customernetworks, you can obtain the following results:

l All the devices that belong to Customer network 1 work together to form a spanning tree.

l All the devices that belong to Customer network 2 work together to form a spanning tree.

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-24 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 223: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Figure 10-3 Networking for configuring interface-based transparent transmission of BPDUsfrom different customer networks

Eth0/0/2

Eth0/0/1

MAN

UPE-A UPE-B

Customernetwork 1

CE-B

CE-D

CE-A

CE-C

Customernetwork 2

Eth0/0/3 Eth0/0/3Customernetwork 1

Customernetwork 2

Eth0/0/1

Eth0/0/1 Eth0/0/1

Eth0/0/1

Eth0/0/2

Eth0/0/1BPDU Tunnel

Configuration RoadmapThe configuration roadmap is as follows:

l Enable STP on the CEs, and enable the CEs to process BPDUs.

l Enable the UPEs to process BPDUs.

l Add the Ethernet 0/0/2 interfaces connected to Customer network 1 on the UPEs to VLAN100 in untagged mode.

l Add the Ethernet 0/0/1 interfaces connected to Customer network 2 on the UPEs to VLAN200 in untagged mode.

l Allow BPDUs from VLAN 100 and VLAN 200 to pass the Ethernet 0/0/3 interfaces onthe UPEs.

l Replace the destination MAC address of BPDUs with a multicast MAC address.

l Enable BPDU tunneling on the Ethernet 0/0/2 and Ethernet 0/0/1 interfaces on the UPEs.

Data PreparationTo complete the configuration, you need the following data:

l Names of the CE interfaces connected to the UPEs

l Names of the UPE interfaces connected to the CEs

l Names of the interfaces on the link between the two UPEs

l IDs of the VLANs to which the UPEs connected with Customer network 1 and Customernetwork 2 belong

l Multicast MAC address to be used to replace the destination MAC address of BPDUs

Configuration Procedure1. Enable STP on the CEs, and enable the CEs to process BPDUs.

# Configure CE-A.<Quidway> system-view

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-25

Page 224: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

[Quidway] sysname CE-A[CE-A] stp enable[CE-A] bpdu enable# Configure CE-B.<Quidway> system-view[Quidway] sysname CE-B[CE-B] stp enable[CE-B] bpdu enable# Configure CE-C.<Quidway> system-view[Quidway] sysname CE-C[CE-C] stp enable[CE-C] bpdu enable# Configure CE-D.<Quidway> system-view[Quidway] sysname CE-D[CE-D] stp enable[CE-D] bpdu enable

2. Enable the UPEs to process BPDUs.<Quidway> system-view[Quidway] sysname UPE-A[UPE-A] bpdu enable# Configure UPE-B.<Quidway> system-view[Quidway] sysname UPE-B[UPE-B] bpdu enable

3. On the UPEs, add the Ethernet 0/0/2 interfaces to VLAN 100 in untagged mode.# Configure UPE-A.[UPE-A] vlan batch 100[UPE-A] interface ethernet 0/0/2[UPE-A-Ethernet0/0/2] port default vlan 100[UPE-A-Ethernet0/0/2] quit# Configure UPE-B.[UPE-B] vlan batch 100 [UPE-B] interface ethernet 0/0/2[UPE-B-Ethernet0/0/2] port default vlan 100[UPE-B-Ethernet0/0/2] quit

4. On the UPEs, add the Ethernet 0/0/1 interfaces to VLAN 200 in untagged mode.# Configure UPE-A.[UPE-A] vlan batch 200[UPE-A] interface ethernet 0/0/1[UPE-A-Ethernet0/0/1] port default vlan 200[UPE-A-Ethernet0/0/1] quit# Configure UPE-B.[UPE-B] vlan batch 200[UPE-B] interface ethernet 0/0/1[UPE-B-Ethernet0/0/1] port default vlan 200[UPE-B-Ethernet0/0/1] quit

5. On the UPEs, allow BPDUs from VLAN 100 and VLAN 200 to pass the Ethernet 0/0/3interfaces.# Configure UPE-A.[UPE-A] interface ethernet 0/0/3[UPE-A-Ethernet0/0/3] port trunk allow-pass vlan 100 200# Configure UPE-B.[UPE-B] interface ethernet 0/0/3

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-26 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 225: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

[UPE-B-Ethernet0/0/3] port trunk allow-pass vlan 100 200

6. Replace the destination MAC address of BPDUs with a multicast MAC address.# Configure UPE-A.[UPE-A] bpdu-tunnel stp group-mac 0100-5e00-0011

# Configure UPE-B.[UPE-B] bpdu-tunnel stp group-mac 0100-5e00-0011

NOTE

This step is optional. By default, the multicast MAC address is 0100-0ccd-cdd0.

7. On the UPEs, enable BPDU tunneling on the Ethernet 0/0/1 and Ethernet 0/0/2 interfaces.# Configure UPE-A.[UPE-A] interface ethernet 0/0/2[UPE-A-Ethernet0/0/2] bpdu-tunnel enable[UPE-A-Ethernet0/0/2] quit[UPE-A] interface ethernet 0/0/1[UPE-A-Ethernet0/0/1] bpdu-tunnel enable[UPE-A-Ethernet0/0/1] quit

# Configure UPE-B.[UPE-B] interface ethernet 0/0/2[UPE-B-Ethernet0/0/2] bpdu-tunnel enable[UPE-B-Ethernet0/0/2] quit[UPE-B] interface ethernet 0/0/1[UPE-B-Ethernet0/0/1] bpdu-tunnel enable[UPE-B-Ethernet0/0/1] quit

8. Verify the configuration.# Check the configuration of UPE-A.[UPE-A] interfaceethernet 0/0/1[UPE-A-Ethernet0/0/1] display bpdu-tunnel interface configBpduDot1qStatus disableBpduOneQStatus enableBpduTwoQStatus disableEtherType 8100Dot1qVlanTwoQList [UPE-A] interface ethernet 0/0/2[UPE-A-Ethernet0/0/2] display bpdu-tunnel interface configBpduDot1qStatus disableBpduOneQStatus enableBpduTwoQStatus disableEtherType 8100Dot1qVlanTwoQList

# Check the configuration of UPE-B.Omitted. The verification on UPE-B is same as that on UPE-A and is not mentioned here.If the UPEs are correctly configured, BPDUs sent from CEs can reach the peer CEs torealize the STP calculation, and interfaces obtain corresponding roles correctly.

Configuration Filesl Configuration file of CE-A

# sysname CE-A# stp enable#bpdu enable#

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-27

Page 226: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

return

l Configuration file of CE-B# sysname CE-B# stp enable#bpdu enable#return

l Configuration file of CE-C# sysname CE-C# stp enable#BPDU enable#return

l Configuration file of CE-D# sysname CE-D# stp enable#BPDU enable#return

l Configuration file of UPE-A#sysname UPE-A#vlan batch 100 200#bpdu enable#bpdu-tunnel stp group-mac 0100-5e00-0011#interface Ethernet0/0/1 port default vlan 200 bpdu-tunnel enable#interface Ethernet0/0/2 port default vlan 100 bpdu-tunnel enable#interface Ethernet0/0/3 port trunk allow-pass vlan 100 200#return

l Configuration file of UPE-B#sysname UPE-B#vlan batch 100 200#bpdu enable#bpdu-tunnel stp group-mac 0100-5e00-0011#interface Ethernet0/0/1 port default vlan 200 bpdu-tunnel enable#

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-28 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 227: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

interface Ethernet0/0/2 port default vlan 100 bpdu-tunnel enable#interface Ethernet0/0/3 port trunk allow-pass vlan 100 200#return

10.7.3 Example for Configuring VLAN-based BPDU Tunneling

Networking RequirementsAs shown in Figure 10-4, Customer network 1 belongs to VLAN 10 and connects the Ethernet0/0/1 interfaces on UPE-A and UPE-B through CE-A and CE-B; Customer network 2 belongsto VLAN 20 and connects the Ethernet 0/0/2 interfaces on UPE-A and UPE-B through CE-Cand CE-D.

By configuring VLAN-based BPDU tunneling, you can obtain the following results:

l The Ethernet 0/0/1 interfaces on CE-A and CE-B allow BPDUs from VLAN 10 to passand tag the BPDUs to the UPEs with VLAN ID 10.

l The Ethernet 0/0/1 interfaces on CE-C and CE-D allow BPDUs from VLAN 20 to passand tag the BPDUs to the UPEs with VLAN ID 20.

l All the devices that belong to VLAN 10 work together to form a spanning tree.

l All the devices that belong to VLAN 20 work together to form a spanning tree.

The UPE interfaces connected to the CEs converge multiple user VLANs. Therefore, BPDUsfrom CEs must be tagged to identify different users.

To transmit BPDUs transparently across the provider network, you should enable BPDUtunneling and replace the destination MAC address of the BPDUs on the UPEs.

Figure 10-4 Networking for configuring VLAN-based BPDU tunneling

MAN

UPE-A UPE-B

VLAN20

VLAN10

CE-A

CE-D

CE-B

CE-C

VLAN10

VLAN20

Eth0/0/1

Eth0/0/2

Eth0/0/1

Eth0/0/1

Eth0/0/2

Eth0/0/1

Eth0/0/1

Eth0/0/1

CustomerNetwork 1

CustomerNetwork 2

CustomerNetwork 1

CustomerNetwork 2

BPDU Tunnel 10

BPDU Tunnel 20

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-29

Page 228: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Configuration RoadmapThe configuration roadmap is as follows:

l Enable STP on the CEs, and enable the CEs to process BPDUs.

l Tag the BPDUs sent from the CEs to the UPEs.

l Allow the tagged BPDUs to pass the UPE interfaces connected to the CEs.

l Configure the UPEs to replace the destination MAC address of BPDUs with a multicastMAC address.

l Configure the UPEs to set up the BPDU tunnel according to the tag value in BPDUs andenable BPDU tunneling.

Data PreparationTo complete the configuration, you need the following data:

l BPDUs from CE-A and CE-B to the UPEs belonging to VLAN 10

l BPDUs from CE-C and CE-D to the UPEs belonging to VLAN 20

l Numbers of the UPE interfaces connected to the CEs

l Multicast MAC address to be used to replace the destination MAC address of BPDUs

Configuration Procedure1. Enable STP on the CEs, and enable the CEs to process BPDUs.

# Configure CE-A.<Quidway> system-view[Quidway] sysname CE-A[CE-A] stp enable[CE-A] bpdu enable# Configure CE-B.<Quidway> system-view[Quidway] sysname CE-B[CE-B] stp enable[CE-B] bpdu enable# Configure CE-C.<Quidway> system-view[Quidway] sysname CE-C[CE-C] stp enable[CE-C] bpdu enable# Configure CE-D.<Quidway> system-view[Quidway] sysname CE-D[CE-D] stp enable[CE-D] bpdu enable

2. Configure CEs to allow BPDUs from the specified VLANs to pass the Ethernet 0/0/1interfaces.# Configure CE-A.[CE-A] vlan 10[CE-A-vlan10] quit[CE-A] interface ethernet 0/0/1[CE-A-Ethernet0/0/1] port trunk allow-pass vlan 10[CE-A-Ethernet0/0/1] quit# Configure CE-B.

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-30 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 229: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

[CE-B] vlan 10[CE-B-vlan10] quit[CE-B] interface ethernet 0/0/1[CE-B-Ethernet0/0/1] port trunk allow-pass vlan 10[CE-B-Ethernet0/0/1] quit

# Configure CE-C.[CE-C] vlan 20[CE-C-vlan10] quit[CE-C] interface ethernet 0/0/1[CE-C-Ethernet0/0/1] port trunk allow-pass vlan 20[CE-C-Ethernet0/0/1] quit

# Configure CE-D.[CE-D] vlan 20[CE-D-vlan10] quit[CE-D] interface ethernet 0/0/1[CE-D-Ethernet0/0/1] port trunk allow-pass vlan 20[CE-D-Ethernet0/0/1] quit

3. Configure CE-A and CE-B to tag BPDUs to be sent to the UPEs with VLAN ID 10.<CE-A> system-view[CE-A] interface ethernet 0/0/1[CE-A-Ethernet0/0/1] stp bpdu vlan 10[CE-A-Ethernet0/0/1] quit

# Configure CE-B.<CE-B> system-view[CE-B] interface ethernet 0/0/1[CE-B-Ethernet0/0/1] stp bpdu vlan 10[CE-B-Ethernet0/0/1] quit

4. Configure CE-C and CE-D to tag BPDUs to be sent to the UPEs with VLAN ID 20.

# Configure CE-C.<CE-C> system-view[CE-C] interface ethernet 0/0/1[CE-C-Ethernet0/0/1] stp bpdu vlan 20[CE-C-Ethernet0/0/1] quit

# Configure CE-D.<CE-D> system-view[CE-D] interface ethernet 0/0/1[CE-D-Ethernet0/0/1] stp bpdu vlan 20[CE-D-Ethernet0/0/1] quit

5. Enable the UPEs to process BPDUs.

# Configure UPE-A.<Quidway> system-view[Quidway] sysname UPE-A[UPE-A] bpdu enable

# Configure UPE-B.<Quidway> system-view[Quidway] sysname UPE-B[UPE-B] bpdu enable

6. Configure the UPEs to replace the destination MAC address of BPDUs with a multicastMAC address.

# Configure UPE-A.[UPE-A] bpdu-tunnel stp group-mac 0100-5e00-0011

# Configure UPE-B.[UPE-B] bpdu-tunnel stp group-mac 0100-5e00-0011

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-31

Page 230: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

NOTE

The multicast MAC address configured on UPE-A is the same as that on UPE-B.

7. Configure the UPEs to transmit the BPDUs from VLAN 10 and VLAN 20 through theBPDU tunnel.# Configure UPE-A.[UPE-A] interface ethernet 0/0/1[UPE-A-Ethernet0/0/1] port trunk allow-pass vlan 10 [UPE-A-Ethernet0/0/1] bpdu-tunnel stp vlan 10[UPE-A-Ethernet0/0/1] quit[UPE-A] interface ethernet 0/0/2[UPE-A-Ethernet0/0/2] bpdu-tunnel stp vlan 20[UPE-A-Ethernet0/0/2] port trunk allow-pass vlan 20[UPE-A-Ethernet0/0/2] quit# Configure UPE-B.[UPE-B] interface ethernet 0/0/1[UPE-B-Ethernet0/0/1] port trunk allow-pass vlan 10[UPE-B-Ethernet0/0/1] bpdu-tunnel stp vlan 10[UPE-B-Ethernet0/0/1] quit[UPE-B] interface ethernet 0/0/2[UPE-B-Ethernet0/0/1] port trunk allow-pass vlan 20[UPE-B-Ethernet0/0/2] bpdu-tunnel stp vlan 20[UPE-B-Ethernet0/0/2] quit

8. Verify the configuration.Run the display bpdu-tunnel interface config command and you can view VLAN IDsand TPIDs configured on the interfaces.# Take CE-A as an example.[CE-A-Ethernet0/0/1] display bpdu-tunnel interface configBpduDot1qStatus enableBpduOneQStatus disableBpduTwoQStatus disableEtherType 8100Dot1qVlan 10TwoQList# Take UPE-A as an example.[UPE-A-Ethernet0/0/1] display bpdu-tunnel interface configBpduDot1qStatus disableBpduOneQStatus disableBpduTwoQStatus enableEtherType 8100Dot1qVlanTwoQList 10# Run the display stp brief command to check the STP calculation result on the CEs.[CE-A] display stp briefMSTID Port Role STP State Protection0 Ethernet0/0/1 ROOT FORWARDING NONE[CE-B] display stp briefMSTID Port Role STP State Protection0 Ethernet0/0/1 DESI FORWARDING NONE

Configuration Filesl Configuration file of CE-A

# sysname CE-A# vlan batch 10# bpdu enable#

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-32 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 231: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

stp enable#interface ethernet 0/0/1 port trunk allow-pass vlan 10 stp bpdu vlan 10#return

l Configuration file of CE-B, the same as that of CE-A

l Configuration file of CE-C# sysname CE-C# vlan batch 20# bpdu enable# stp enable#interface ethernet 0/0/1 port trunk allow-pass vlan 20 stp bpdu vlan 20#return

l Configuration file of CE-D, the same as that of CE-C

l Configuration file of UPE-A# sysname UPE-A# vlan batch 10 20# bpdu enable# bpdu-tunnel stp group-mac 0100-5e00-0011#interface ethernet 0/0/1 port trunk allow-pass vlan 10 bpdu-tunnel stp vlan 10#interface ethernet 0/0/2 port trunk allow-pass vlan 20 bpdu-tunnel stp vlan 20#return

l Configuration file of UPE-B, the same as that of UPE-A

10.7.4 Example for Configuring Partitioned STP

Networking RequirementsAs shown in Figure 10-5, the intranet accesses the MAN through two Ethernet interfaces on theS-switch which connects two S-switchs in the MAN for the sake of high availability. It is requiredthat no loop occur between the intranet and the MAN when partitioned STP is enabled.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-33

Page 232: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

Figure 10-5 Networking for configuring partitioned STP

Intranet......

S-switch-C

S-switch-A

S-switch-B

......Metropolitan

AreaNetwork(MAN)

......

Eth0/0/1 Eth0/0/2

Eth0/0/2Eth0/0/2Eth0/0/1

Eth0/0/1

Configuration RoadmapThe configuration roadmap is as follows:

l Enable MSTP on S-switch-C, and enable S-switch-C to process BPDUs.

l Create VLAN 10 on S-switch-C. Enable the Ethernet 0/0/1 and Ethernet 0/0/2 interfacesto tag

l Create VLAN 10 on S-switch-A. Enable BPDU tunneling on Ethernet 0/0/1. Allow BPDUsfrom VLAN 10 to pass Ethernet 0/0/2.Enable the S-switch-A to process BPDUs.

l Create VLAN 10 on S-switch-B. Enable BPDU tunneling on Ethernet 0/0/1. Allow BPDUsfrom VLAN 10 to pass Ethernet 0/0/2.Enable the S-switch-B to process BPDUs.

l Enable STP snooping on S-switch-A and S-switch-B.

l (Optional)Replace the destination MAC address of received BPDUs with a multicast MACaddress on S-switch-A and S-switch-B.

Data PreparationTo complete the configuration, you need the following data:

l VLAN ID 10 to be used in the partitioned STP network

l Numbers of the interfaces through which the S-switchs are directly connected

l Multicast MAC address to be used to replace the destination MAC address of BPDUs.

Configuration Procedure1. Enable MSTP and BPDU on S-switch-C, and enable S-switch-C to process BPDUs.

<Quidway> system-view[Quidway] sysname S-switch-C[S-switch-C] stp enable[S-switch-C] bpdu enable

2. On S-switch-C, configure the interfaces to tag BPDUs.# Create VLAN 10.[S-switch-C] vlan 10[S-switch-C-vlan10] quit

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-34 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 233: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

# Configure Ethernet 0/0/1 and Ethernet 0/0/2 to tag BPDUs.[S-switch-C] interface ethernet 0/0/1[S-switch-C-Ethernet0/0/1] port trunk allow-pass vlan 10[S-switch-C-Ethernet0/0/1] stp bpdu vlan 10[S-switch-C-Ethernet0/0/1] quit[S-switch-C] interface ethernet 0/0/2[S-switch-C-Ethernet0/0/2] port trunk allow-pass vlan 10[S-switch-C-Ethernet0/0/2] stp bpdu vlan 10[S-switch-C-Ethernet0/0/2] quit

3. Enable BPDU tunneling on S-switch-A.# Create VLAN 10.<Quidway> system-view[Quidway] sysname S-switch-A[S-switch-A] vlan 10[S-switch-A-vlan10] quit

# Configure S-switch-A to process BPDUs.[S-switch-A] bpdu enable

# Enable BPDU tunneling on Ethernet 0/0/1.[S-switch-A] interface ethernet 0/0/1[S-switch-A-Ethernet0/0/1] bpdu-tunnel stp vlan 10

# Allow BPDUs from VLAN 10 to pass Ethernet 0/0/1.[S-switch-A-Ethernet0/0/1] port trunk allow-pass vlan 10[S-switch-A-Ethernet0/0/1] quit

# Allow BPDUs from VLAN 10 to pass Ethernet 0/0/2.[S-switch-A] interface ethernet 0/0/2[S-switch-A-Ethernet0/0/2] port trunk allow-pass vlan 10

4. Enable BPDU tunneling on S-switch-B.# Create VLAN 10.<Quidway> system-view[Quidway] sysname S-switch-B[S-switch-B] vlan 10[S-switch-B-vlan10] quit

# Configure S-switch-B to process BPDUs.[S-switch-B] bpdu enable

# Enable BPDU tunneling on Ethernet 0/0/1.[S-switch-B] interface ethernet 0/0/1[S-switch-B-Ethernet0/0/1] bpdu-tunnel stp vlan 10

# Allow BPDUs from VLAN 10 to pass Ethernet 0/0/1.[S-switch-B-Ethernet0/0/1] port trunk allow-pass vlan 10[S-switch-B-Ethernet0/0/1] quit

# Allow BPDUs from VLAN 10 to pass Ethernet 0/0/2.[S-switch-B] interface ethernet 0/0/2[S-switch-B-Ethernet0/0/2] port trunk allow-pass vlan 10

5. Enable STP snooping on S-switch-A and S-switch-B.# Enable STP snooping on S-switch-A.[S-switch-A] stp-snooping enable

# Enable STP snooping on S-switch-B.[S-switch-B] stp-snooping enable

6. Replace the destination MAC address of BPDUs with a multicast MAC address on S-switch-A and S-switch-B.# Replace the MAC address of BPDUs.

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-35

Page 234: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

[S-switch-A] bpdu-tunnel stp group-mac 0100-5e00-0011

# Replace the MAC address of BPDUs.[S-switch-B] bpdu-tunnel stp group-mac 0100-5e00-0011

7. Verify the configuration.# Check the configuration of S-switch-C.<S-switch-C> display stp brief MSTID Port Role STP State Protection 0 Ethernet0/0/1 DESI FORWARDING NONE 0 Ethernet0/0/2 BACK DISCARDING NONE

You can view that the STP calculation on S-switch-C is correct, Ethernet 0/0/2 is in theDiscarding state, and no loop is formed between S-switch-C, S-switch-A, and S-switch-B.# Check the configuration of S-switch-A.[S-switch-A] interface ethernet0/0/1[S-switch-A-Ethernet0/0/1] display bpdu-tunnel interface configBpduDot1qStatus disableBpduOneQStatus disableBpduTwoQStatus enableEtherType 8100Dot1qVlanTwoQList 10

The "BpduTwoQStatus enable" field indicates that Ethernet 0/0/1 allows the tagged BPDUsto pass.

Configuration Filesl Configuration file of S-switch-A

# sysname S-switch-A# vlan batch 10# bpdu enable# stp-snooping enable# bpdu-tunnel stp group-mac 0100-5e00-0011#interface Ethernet0/0/1 port trunk allow-pass vlan 10 bpdu-tunnel stp vlan 10#interface Ethernet0/0/2 port trunk allow-pass vlan 10#return

l Configuration file of S-switch-B# sysname S-switch-B# vlan batch 10# bpdu enable# stp-snooping enable#bpdu-tunnel stp group-mac 0100-5e00-0011#interface Ethernet0/0/1 port trunk allow-pass vlan 10 bpdu-tunnel stp vlan 10#

10 BPDU Tunneling and Partitioned STP ConfigurationQuidway S2300 Series Ethernet Switches

Configuration Guide - Ethernet

10-36 Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

Issue 03 (2009-11-25)

Page 235: Quidway S2300 Configuration Guide - Ethernet(V100R003C00 03)[1]

interface Ethernet0/0/2 port trunk allow-pass vlan 10#return

l Configuration file of S-switch-C# sysname S-switch-C# vlan batch 10# bpdu enable# stp enable#interface Ethernet0/0/1 port trunk allow-pass vlan 10 stp bpdu vlan 10#interface Ethernet0/0/2 port trunk allow-pass vlan 10 stp bpdu vlan 10#return

Quidway S2300 Series Ethernet SwitchesConfiguration Guide - Ethernet 10 BPDU Tunneling and Partitioned STP Configuration

Issue 03 (2009-11-25) Huawei Proprietary and ConfidentialCopyright © Huawei Technologies Co., Ltd.

10-37