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


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


Configuration Guide - Ethernet Switching

CloudEngine 8800, 7800, 6800, and 5800 V200R003C00

This document describes the configuration of Ethernet services, including configuring MAC address table, link aggregation, VLANs, MUX VLAN, Voice VLAN, VLAN mapping, QinQ, GVRP, VCMP, STP/RSTP/MSTP, VBST, SEP, RRPP, ERPS, LBDT, and Layer 2 protocol transparent transmission.
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).
Dividing a LAN into VLANs Based on IP Subnets

Dividing a LAN into VLANs Based on IP Subnets



The CE6810LI does not support IP subnet-based VLAN assignment.

The switch enabled with IP subnet-based VLAN assignment cannot process protocol packets sent to the CPU, and it is recommended that IP subnet-based VLAN assignment be used in Layer 2 transparent transmission scenarios.

IP subnet-based assignment allows users to easily join a VLAN, transfer from one VLAN to another, and exit from a VLAN. IP subnet-based VLAN assignment is applicable to networks that have traveling users and require simple management.

The switch enabled with IP subnet-based VLAN assignment processes only untagged frames. After receiving untagged frames, the switch determines the VLANs to which the frames belong based on their source IP addresses and network segment addresses before sending them to corresponding VLANs.


  1. Run system-view

    The system view is displayed.

  2. (Optional) Run vlan assign global { vlan-id1 [ to vlan-id2 ] } &<1-5>

    VLANs that can be globally assigned are specified.


    Only the CE8800 series switches, CE7800 series switches, CE6875EI, CE6870EI, CE6860EI, CE6850U-HI, CE6851HI, CE6850HI, CE6856HI, and CE6855HI support this configuration.

    After VLANs are assigned, the VLANs created using the vlan vlan-id command must be within the assignable VLAN range.

  3. (Optional) Run vlan reserved vlan-id

    A reserved VLAN is configured.

    By default, the reserved VLAN ID ranges from 4064 to 4094. After vlan-id is specified, the VLAN specified by vlan-id to the VLAN specified by vlan-id plus 30 are configured as reserved VLANs.

    CE6880EI does not support this step.

  4. Run vlan vlan-id

    A VLAN is created, and the VLAN view is displayed. If the specified VLAN has been created, the VLAN view is directly displayed.

    The VLAN ID ranges from 1 to 4094 (excluding reserved VLANs). If VLANs need to be created in batches, run the vlan batch { vlan-id1 [ to vlan-id2 ] } &<1-10> command to create VLANs in batches, and then run the vlan vlan-id command to enter the view of a specified VLAN.


    If the switch is configured with multiple VLANs, configuring names for these VLANs is recommended:

    Run the name vlan-name command in the VLAN view. After a VLAN name is configured, you can run the vlan vlan-name vlan-name command in the system view to enter the corresponding VLAN view.

  5. Run ip-subnet-vlan [ ip-subnet-index ] ip ip-address { mask | mask-length } [ priority priority ]

    An IP subnet is associated with the VLAN.

    • ip-subnet-index specifies the IP subnet index. The subnet index can be specified by a user or automatically generated by the system.

    • ip-address specifies the source IP address or network address based on which a VLAN is configured. The value is in dotted decimal notation.

    • priority specifies the 802.1p priority value related to the VLAN configured based on the IP address or network address. The value ranges from 0 to 7. The greater the value, the higher the priority. The default value is 0. After the 802.1p priority value is specified, frames with high priorities are first forwarded when traffic is congested. The CE6870EI and CE6875EI do not support this parameter.

    The CE5810EI and CE5855EI support 256 subnets, the CE6870EI and CE6875EI support 16 subnets, and other models support 512 subnets. The IP subnet or the IP address associated with a VLAN cannot be a multicast network segment or multicast address.

  6. Run quit

    The system view is displayed.

  7. Configure attributes for Ethernet interfaces.

    1. Run the interface interface-type interface-number command to enter the view of the Ethernet interface configured with IP subnet-based VLAN assignment.
    2. Run the port link-type hybrid command to set the link type of the interface to hybrid.

      IP subnet-based VLAN assignment must be configured on the hybrid interface.

      By default, the link type is access.

    3. Run the port hybrid untagged vlan { { vlan-id1 [ to vlan-id2 ] } &<1-10> | all } command to add the hybrid interface to the IP subnet-based VLAN.

  8. (Optional) Run vlan precedence ip-subnet-vlan

    IP subnet-based VLAN assignment is configured with a higher priority.

    By default, MAC address-based VLAN assignment is used.


    The CE6810LI, CE6870EI, CE6875EI, CE6880EI do not support this step.

  9. Run ip-subnet-vlan enable

    IP subnet-based VLAN assignment is enabled.

    By default, IP subnet-based VLAN assignment is disabled.

  10. Run commit

    The configuration is committed.

Updated: 2019-05-08

Document ID: EDOC1100004351

Views: 128837

Downloads: 297

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