No relevant resource is found in the selected language.

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

Reminder

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

upgrade

S2700, S3700, S5700, S6700, S7700, and S9700 Series Switches Typical Configuration Examples

This document provides examples for configuring features in typical usage scenarios.
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Example for Configuring Interface-based Rate Limiting on a Fixed Switch

Example for Configuring Interface-based Rate Limiting on a Fixed Switch

Overview

Interface-based rate limiting is easy to configure and limits the rate of all packets sent or received on an interface regardless of packet type. An interface enabled with this function can be assigned fixed bandwidth.

Interface-based rate limiting in the inbound and outbound directions can be configured simultaneously or separately.

Configuration Notes

For applicable product models and versions, see Applicable Product Models and Versions.

NOTE:
For details about software mappings, visit Hardware Query Tool and search for the desired product model.

Networking Requirements

In Figure 16-2, the Switch connects to the router through GE0/0/3, and departments 1 and 2 are connected to the Switch through GE0/0/1 and GE0/0/2 respectively and access the Internet through the Switch and router.

Services are singular, and therefore do not need to be differentiated. With finite network bandwidth, bandwidth of each department needs to be limited. Department 1 requires the CIR of 8 Mbit/s in the outbound direction, and department 2 requires the CIR of 5 Mbit/s in the outbound direction.

Figure 16-2  Networking of interface-based rate limiting

Configuration Roadmap

The configuration roadmap is as follows:
  1. Configure interfaces of the Switch so that users can access the Internet.
  2. Configure interface-based rate limiting on GE0/0/1 and GE0/0/2 of the Switch in the inbound direction.

Procedure

  1. Create VLANs and configure interfaces of the Switch.

    # Create VLAN 100, VLAN 200, and VLAN 300.

    <HUAWEI> system-view
    [HUAWEI] sysname Switch
    [Switch] vlan batch 100 200 300
    

    # Configure GE0/0/1, GE0/0/2, and GE0/0/3 as trunk interfaces, and configure GE0/0/1 to allow VLAN 100, GE0/0/2 to allow VLAN 200, and GE0/0/3 to allow VLAN 100, VLAN 200, and VLAN 300.

    [Switch] interface gigabitethernet 0/0/1
    [Switch-GigabitEthernet0/0/1] port link-type trunk  //Set the link type of the interface to trunk. The default link type of the interface is not trunk.
    [Switch-GigabitEthernet0/0/1] port trunk allow-pass vlan 100
    [Switch-GigabitEthernet0/0/1] quit
    [Switch] interface gigabitethernet 0/0/2
    [Switch-GigabitEthernet0/0/2] port link-type trunk
    [Switch-GigabitEthernet0/0/2] port trunk allow-pass vlan 200
    [Switch-GigabitEthernet0/0/2] quit
    [Switch] interface gigabitethernet 0/0/3
    [Switch-GigabitEthernet0/0/3] port link-type trunk
    [Switch-GigabitEthernet0/0/3] port trunk allow-pass vlan 100 200 300
    [Switch-GigabitEthernet0/0/3] quit

    # Create VLANIF 300 and set its IP address to 192.168.1.1/24.

    [Switch] interface vlanif 300
    [Switch-Vlanif300] ip address 192.168.1.1 24
    [Switch-Vlanif300] quit
    NOTE:

    On the router, set the IP address of the interface connected to the Switch to 192.168.1.2/24, and configure sub-interfaces on the interface to terminate VLANs.

  2. Configure interface-based rate limiting.

    # Configure rate limiting on GE0/0/1 in the inbound direction and set the CIR to 8192 kbit/s.

    [Switch] interface gigabitethernet 0/0/1
    [Switch-GigabitEthernet0/0/1] qos lr inbound cir 8192  //Set the CIR of department 1 in the outbound direction to 8 Mbit/s.
    [Switch-GigabitEthernet0/0/1] quit
    

    # Configure rate limiting on GE0/0/2 in the inbound direction and set the CIR to 5120 kbit/s.

    [Switch] interface gigabitethernet 0/0/2
    [Switch-GigabitEthernet0/0/2] qos lr inbound cir 5120  //Set the CIR of department 2 in the outbound direction to 5 Mbit/s.
    [Switch-GigabitEthernet0/0/2] quit
    

  3. Verify the configuration.

    # Check the interface-based rate limiting configuration.

    [Switch] display qos lr inbound interface gigabitethernet 0/0/1
     GigabitEthernet0/0/1 lr inbound:
      cir: 8192 Kbps, cbs: 1024000 Byte  
    
    [Switch] display qos lr inbound interface gigabitethernet 0/0/2
     GigabitEthernet0/0/2 lr inbound:
      cir: 5120 Kbps, cbs: 640000 Byte  
    

    # GE0/0/1 is used as an example. When the rate of traffic on the interface in the inbound direction is larger than 8 Mbit/s, packet loss occurs. The traffic rate is limited within 8 Mbit/s.

    [Switch] display qos statistics interface gigabitethernet 0/0/1 inbound
    ---------------------------------------------------------
      Item                                          Value
    ---------------------------------------------------------
      Passed packets                               30,715
      Passed bytes                                      -
      Dropped packets                              16,555
      Dropped bytes                                     -
    ---------------------------------------------------------
    

Configuration Files

Switch configuration file

#
sysname Switch
#
vlan batch 100 200 300
#
interface Vlanif300
 ip address 192.168.1.1 255.255.255.0
#
interface GigabitEthernet0/0/1
 port link-type trunk
 port trunk allow-pass vlan 100
 qos lr inbound cir 8192 cbs 1024000
#
interface GigabitEthernet0/0/2
 port link-type trunk
 port trunk allow-pass vlan 200
 qos lr inbound cir 5120 cbs 640000
#
interface GigabitEthernet0/0/3
 port link-type trunk
 port trunk allow-pass vlan 100 200 300
#
return

Applicable Product Models and Versions

Table 16-2  Applicable product models and versions

Product

Product Model

Software Version

S2700

S2752EI

V100R006C05

S2720EI

V200R006C10, V200R009C00, V200R010C00, V200R011C10, V200R012C00, V200R013C00

S2750EI

V200R003C00, V200R005C00SPC300, V200R006C00, V200R007C00, V200R008C00, V200R009C00, V200R010C00, V200R011C00, V200R011C10, V200R012C00

S3700

S3700SI and S3700EI

V100R006C05

S3700HI

V200R001C00

S5700

S5700LI

V200R001C00, V200R002C00, V200R003(C00&C02&C10), V200R005C00SPC300, V200R006C00, V200R007C00, V200R008C00, V200R009C00, V200R010C00, V200R011C00, V200R011C10, V200R012C00

S5700S-LI

V200R001C00, V200R002C00, V200R003C00, V200R005C00SPC300, V200R006C00, V200R007C00, V200R008C00, V200R009C00, V200R010C00, V200R011C00, V200R011C10, V200R012C00

S5700SI

V200R001C00, V200R002C00, V200R003C00, V200R005C00

S5700EI

V200R001(C00&C01), V200R002C00, V200R003C00, V200R005(C00&C01&C02&C03)

S5700HI

V200R001(C00&C01), V200R002C00, V200R003C00, V200R005(C00SPC500&C01&C02)

S5710-C-LI

V200R001C00

S5710-X-LI

V200R008C00, V200R009C00, V200R010C00, V200R011C00, V200R011C10, V200R012C00

S5710EI

V200R001C00, V200R002C00, V200R003C00, V200R005(C00&C02)

S5710HI

V200R003C00, V200R005(C00&C02&C03)

S5720LI and S5720S-LI

V200R010C00, V200R011C00, V200R011C10, V200R012(C00&C20), V200R013C00

S5720SI and S5720S-SI

V200R008C00, V200R009C00, V200R010C00, V200R011C00, V200R011C10, V200R012C00, V200R013C00

S5720I-SI

V200R012C00, V200R013C00

S5720EI

V200R007C00, V200R008C00, V200R009C00, V200R010C00, V200R011C00, V200R011C10, V200R012C00, V200R013C00

S5720HI

V200R006C00, V200R007(C00&C10), V200R008C00, V200R009C00, V200R010C00, V200R011C00, V200R011C10, V200R012C00, V200R013C00

S5730HI

V200R012C00, V200R013C00

S5730SI

V200R011C10, V200R012C00, V200R013C00

S5730S-EI

V200R011C10, V200R012C00, V200R013C00

S6700

S6700EI

V200R001(C00&C01), V200R002C00, V200R003C00, V200R005(C00&C01&C02)

S6720LI and S6720S-LI

V200R011C00, V200R011C10, V200R012C00, V200R013C00

S6720SI and S6720S-SI

V200R011C00, V200R011C10, V200R012C00, V200R013C00

S6720EI

V200R008C00, V200R009C00, V200R010C00, V200R011C00, V200R011C10, V200R012C00, V200R013C00

S6720S-EI

V200R009C00, V200R010C00, V200R011C00, V200R011C10, V200R012C00, V200R013C00

S6720HI

V200R012C00, V200R013C00

Download
Updated: 2019-04-20

Document ID: EDOC1000069520

Views: 693194

Downloads: 30178

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