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

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).
Example for Assigning VLANs Based on IP Subnets

Example for Assigning VLANs Based on IP Subnets

Networking Requirements

A data center network has multiple services, including office services, production services, and disaster recovery services. Each service uses a unique IP subnet. To facilitate management, packets of the same service must be transmitted in the same VLAN, and packets of different services be transmitted in different VLANs.

In Figure 5-24, the switch connects to the office server, production server, and disaster recovery server on different network segments. Different services need to be assigned to different VLANs and distributed to different remote networks.

NOTE:

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

Figure 5-24 Networking diagram for assigning VLANs based on IP subnets

Configuration Roadmap

  1. Create VLANs and determine which VLAN each service belongs to.
  2. Associate IP subnets with VLANs so that VLANs of packets can be determined based on the source IP addresses or specified network segments.

  3. Add interfaces to VLANs so that packets of the IP subnet-based VLANs can pass through the interfaces.
  4. Enable IP subnet-based VLAN assignment.

Procedure

  1. Create VLANs.

    # Create VLAN 100, VLAN 200, and VLAN 300 on the Switch.

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

  2. Configure interfaces.

    # Set the link type of 10GE1/0/5, 10GE1/0/6, and 10GE1/0/7 to hybrid and add it to VLAN 100, VLAN 200, and VLAN 300 respectively in untagged mode. And enable IP subnet-based VLAN assignment on 10GE1/0/5, 10GE1/0/6, and 10GE1/0/7.

    [~Switch] interface 10ge 1/0/5
    [~Switch-10GE1/0/5] port link-type hybrid
    [*Switch-10GE1/0/5] port hybrid untagged vlan 100
    [*Switch-10GE1/0/5] ip-subnet-vlan enable
    [*Switch-10GE1/0/5] quit
    [*Switch] interface 10ge 1/0/6
    [*Switch-10GE1/0/6] port link-type hybrid
    [*Switch-10GE1/0/6] port hybrid untagged vlan 200
    [*Switch-10GE1/0/6] ip-subnet-vlan enable
    [*Switch-10GE1/0/6] quit
    [*Switch] interface 10ge 1/0/7
    [*Switch-10GE1/0/7] port link-type hybrid
    [*Switch-10GE1/0/7] port hybrid untagged vlan 300
    [*Switch-10GE1/0/7] ip-subnet-vlan enable
    [*Switch-10GE1/0/7] quit
    [*Switch] commit

    # Add 10GE1/0/2 of the Switch to VLAN 100.

    [~Switch] interface 10ge 1/0/2
    [~Switch-10GE1/0/2] port link-type trunk
    [*Switch-10GE1/0/2] port trunk allow-pass vlan 100
    [*Switch-10GE1/0/2] quit
    [*Switch] commit
    

    # Add 10GE1/0/3 of the Switch to VLAN 200.

    [~Switch] interface 10ge 1/0/3
    [~Switch-10GE1/0/3] port link-type trunk
    [*Switch-10GE1/0/3] port trunk allow-pass vlan 200
    [*Switch-10GE1/0/3] quit
    [*Switch] commit

    # Add 10GE1/0/4 of the Switch to VLAN 300.

    [~Switch] interface 10ge 1/0/4
    [~Switch-10GE1/0/4] port link-type trunk
    [*Switch-10GE1/0/4] port trunk allow-pass vlan 300
    [*Switch-10GE1/0/4] quit
    [*Switch] commit

  3. Configure IP subnet-based VLAN assignment.

    # Associate IP subnet 192.168.1.2/24 with VLAN 100.

    [~Switch] vlan 100
    [~Switch-vlan100] ip-subnet-vlan 1 ip 192.168.1.2 24
    [*Switch-vlan100] quit

    # Associate IP subnet 192.168.2.2/24 with VLAN 200.

    [*Switch] vlan 200
    [*Switch-vlan200] ip-subnet-vlan 1 ip 192.168.2.2 24
    [*Switch-vlan200] quit
    

    # Associate IP subnet 192.168.3.2/24 with VLAN 300.

    [*Switch] vlan 300
    [*Switch-vlan300] ip-subnet-vlan 1 ip 192.168.3.2 24
    [*Switch-vlan300] quit
    [*Switch] commit
    

  4. Verify the configuration.

    Run the display ip-subnet-vlan vlan all command on the Switch. The following information is displayed:

    [~Switch] display ip-subnet-vlan vlan all
     IP-subnet-VLAN count: 3                  total count: 3
     ----------------------------------------------------------------
     VLAN    Index  IpAddress            SubnetMask          Priority
     ----------------------------------------------------------------
     100         1  192.168.1.2          255.255.255.0              0
     200         1  192.168.2.2          255.255.255.0              0
     300         1  192.168.3.2          255.255.255.0              0
     ----------------------------------------------------------------

    The product service, office service, and disaster recovery service can only be transmitted in the production center, campus office network, and disaster recovery data center respectively.

Configuration Files

Configuration file of the Switch

#
sysname Switch
#
vlan batch 100 200 300
#
vlan 100
 ip-subnet-vlan 1 ip 192.168.1.2 255.255.255.0
#
vlan 200
 ip-subnet-vlan 1 ip 192.168.2.2 255.255.255.0
#
vlan 300
 ip-subnet-vlan 1 ip 192.168.3.2 255.255.255.0
#
interface 10GE1/0/2
 port link-type trunk
 port trunk allow-pass vlan 100
 device transceiver 10GBASE-COPPER
#
interface 10GE1/0/3 
 port link-type trunk
 port trunk allow-pass vlan 200
 device transceiver 10GBASE-COPPER
#
interface 10GE1/0/4 
 port link-type trunk
 port trunk allow-pass vlan 300
 device transceiver 10GBASE-COPPER
#
interface 10GE1/0/5
 port link-type hybrid
 port hybrid untagged vlan 100
 ip-subnet-vlan enable
 device transceiver 10GBASE-COPPER
#
interface 10GE1/0/6
 port link-type hybrid
 port hybrid untagged vlan 200
 ip-subnet-vlan enable
 device transceiver 10GBASE-COPPER
#
interface 10GE1/0/7
 port link-type hybrid
 port hybrid untagged vlan 300
 ip-subnet-vlan enable
 device transceiver 10GBASE-COPPER
#
return
Translation
Download
Updated: 2019-05-08

Document ID: EDOC1100004351

Views: 128624

Downloads: 296

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