01-06 VLAN Aggregation Configuration
01-06 VLAN Aggregation Configuration
Switches
Configuration Guide - Ethernet Switching 6 VLAN Aggregation Configuration
Definition
VLAN aggregation, also called super-VLAN, partitions a broadcast domain into
multiple VLANs (sub-VLANs) on a physical network and aggregates the sub-
VLANs into a single logical VLAN (super-VLAN). The sub-VLANs use the same IP
subnet and default gateway address, so the number of IP addresses used is
reduced.
Purpose
VLAN technology is commonly used on packet switching networks because it can
flexibly control broadcast domains and is easy to deploy. Usually, a Layer 3 switch
uses a Layer 3 logical interface in each VLAN to allow hosts in different broadcast
domains to communicate. This wastes IP addresses. On a subnet corresponding to
a VLAN, the subnet ID, directed broadcast address, and subnet default gateway
address all cannot be used as IP addresses of hosts in the VLAN. In addition, IP
addresses available in a subnet may exceed the number of hosts. These excess IP
addresses cannot be used by other VLANs.
In Figure 6-1, VLAN 2 requires 10 host addresses. The subnet 10.1.1.0/28 with a
28-bit mask is assigned to VLAN 2, where 10.1.1.0 is the subnet ID, 10.1.1.15 is the
directed broadcast address, and 10.1.1.1 is the default gateway address. Hosts
cannot use these three addresses, but the other 13 addresses ranging from
10.1.1.2 to 10.1.1.14 are available to them.
At least three IP addresses are wasted for VLAN 2, and at least nine IP addresses
are wasted for three VLANs. Although VLAN 2 requires only 10 IP addresses, the
remaining 3 IP addresses cannot be used by other VLANs and are wasted. If more
VLANs are added, the problem is exacerbated.
VLANIF 3:10.1.1.17
Sub-VLANs share one gateway address to reduce the number of subnet IDs,
subnet default gateway addresses, and directed broadcast IP addresses used is
reduced. The switch assigns IP addresses to hosts in sub-VLANs according to the
number of hosts. This ensures that each sub-VLAN acts as an independent
broadcast domain, conserves IP addresses, and implements flexible addressing.
Implementation
VLAN aggregation defines the super-VLAN and sub-VLAN. A sub-VLAN is an
independent broadcast domain that contains only physical interfaces. A super-
VLAN contains no physical interface and is used for creating a Layer 3 VLANIF
interface. By mapping a super-VLAN to sub-VLANs, VLAN aggregation associates
the Layer 3 VLANIF interface with physical interfaces so that all sub-VLANs share
one gateway to communicate with an external network. In addition, proxy ARP
can be used to implement Layer 3 connectivity between sub-VLANs. The super-
VLAN and sub-VLAN are different from common VLANs that contain a Layer 3
logical interface and multiple physical interfaces.
● Sub-VLAN: contains only physical interfaces, and is used to isolate broadcast
domains. A sub-VLAN cannot be used to create a Layer 3 VLANIF interface.
Hosts in each sub-VLAN use the VLANIF interface of the associated super-
VLAN to communicate with external devices over Layer 3.
● Super-VLAN: is only used for creating a Layer 3 VLANIF interface and contains
no physical interfaces. Its IP address is used as the subnet gateway. A VLANIF
interface in a super-VLAN is Up as long as a physical interface in any
associated sub-VLAN is Up. This is unlike a VLANIF interface, which is Up as
long as a physical interface is Up.
A super-VLAN can contain one or more sub-VLANs. A sub-VLAN does not occupy
an independent subnet. In a super-VLAN, the IP address of a host is the same
subnet segment as the super-VLAN regardless of which sub-VLAN belongs to.
Therefore, sub-VLANs share the same gateway.
Sub-VLANs share one gateway address to reduce the number of subnet IDs,
subnet default gateway addresses, and directed broadcast IP addresses used. This
allows different broadcast domains to use the same subnet address, allows for
flexible addressing, and conserves IP addresses.
6.1 Overview of VLAN Aggregation shows an example network topology. VLAN
10 is configured as the super-VLAN and assigned the subnet address 10.1.1.0/24.
VLAN 2, VLAN 3, and VLAN 4 are configured as sub-VLANs of super-VLAN 10.
NOTE
For details about proxy ARP, see Proxy ARP in "ARP Configuration" in the S1720, S2700,
S5700, and S6720 V200R011C10 Configuration Guide - IP Services.
Figure 6-3 Using proxy ARP to implement Layer 3 communication between sub-
VLANs
Super-VLAN10
L3 Switch VLANIF10:10.1.1.1/24
Proxy ARP
Host_1 Host_2
Sub-VLAN2 Sub-VLAN3
10.1.1.2/24 10.1.1.12/24
VLANIF 10. Switch_1 determines the outbound interface according to the ARP
entry and MAC address entry, and sends the packet to Switch_2.
5. Switch_2 sends the packet to the server through Layer 3 forwarding.
After receiving the packet from Host_1, the server sends a response packet with
the destination IP address of 10.1.1.2 and the MAC address of VLANIF 20 on
Switch_2 as the destination MAC address. Then the following process occurs:
1. The response packet reaches Switch_1 through Layer 3 forwarding. When the
response packet reaches Switch_1, the destination MAC address is changed to
the MAC address of VLANIF 10 on Switch_1.
2. After receiving the packet, Switch_1 determines that the packet should be
forwarded at Layer 3 according to the destination MAC address. Switch_1
searches its Layer 3 forwarding table for a matching entry, but no entry is
found. Switch_1 sends the packet to the CPU, and the CPU searches its routing
table and obtains the next-hop address of 10.1.1.2 and the outbound interface
of VLANIF 4. Switch_1 searches the mapping between the super-VLAN and
sub-VLANs and determines that the packet should be sent to Host_1 from an
interface in sub-VLAN 2 according to the ARP entry and MAC address entry.
3. The response packet reaches Host_1.
Internet
Switch_2
Trunk IF_1
Allowed VLAN=2,3
IF_3
Super-VLAN4
Switch_1 VLANIF4
10.1.1.1/24
IF_1 IF_2
Host_1 Host_2
Sub-VLAN2 Sub-VLAN3
10.1.1.2/24 10.1.1.12/24
A tag with VLAN 2 is added to packets sent from Host_1 to Switch_1. Although
sub-VLAN 2 belongs to super-VLAN 4, Switch_1 does not change the tag with
VLAN 2 to a tag with VLAN 4 in packets. Therefore, packets sent from IF_3 of
Switch_1 still carry VLAN 2.
Switch_1 does not send packets from VLAN 4. When another device sends packets
from VLAN 4 to Switch_1, Switch_1 discards the packets because there is no
physical interface corresponding to super-VLAN 4 on Switch_1. IF_3 on Switch_1
does not allow packets from super-VLAN 4. For other devices, only sub-VLAN 2
and sub-VLAN 3 are valid.
Internet
Switch
Proxy ARP
Therefore, VLAN aggregation allows all departments to access the Internet access
and conserves IP addresses.
Licensing Requirements
VLAN aggregation, also called super-VLAN, is a basic feature of a switch and is not
under license control.
Version Requirements
S5730SI V200R011C10
S5730S-EI V200R011C10
NOTE
To know details about software mappings, see Hardware Query Tool.
Feature Limitations
● VLAN 1 cannot be configured as a super-VLAN.
● A physical interface cannot be added to a VLAN configured as a super-VLAN.
● A VLAN that has been configured as a guest VLAN cannot be configured as a
super-VLAN.
● A traffic policy takes effect in a super-VLAN only after the traffic policy is
configured in all sub-VLANs of the super-VLAN.
● When the dot1q termination vid or qinq termination pe-vid ce-vid
command is used to configure a VLAN for the VLAN termination sub-
interface, the VLAN cannot be configured as the super-VLA or sub-VLAN.
Context
In VLAN aggregation, physical interfaces can be added to a sub-VLAN but a
VLANIF interface cannot be created for the sub-VLAN. All the interfaces in a sub-
VLAN use the same IP address of the VLANIF interface associated with the super-
VLAN. VLAN aggregation reduces subnet IDs, subnet default gateway addresses,
and directed broadcast IP addresses, and allows the switch to assign IP addresses
to hosts in sub-VLANs according to the number of hosts.
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
If a device 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.
The vlan configuration command completes the VLAN configuration when the VLAN is not
created.
----End
Context
A super-VLAN consists of several sub-VLANs. No physical interface can be added
to a super-VLAN, but a VLANIF interface can be configured for the super-VLAN
and an IP address can be assigned to the VLANIF interface.
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.
The VLAN ID of a super-VLAN must be different from each sub-VLAN ID.
Step 3 Run aggregate-vlan
A super-VLAN is created.
A super-VLAN cannot contain any physical interfaces.
VLAN 1 cannot be configured as a super-VLAN.
Step 4 Run access-vlan { vlan-id1 [ to vlan-id2 ] } &<1-10>
A sub-VLAN is added to a super-VLAN.
Before adding any sub-VLANs to a super-VLAN, ensure that they are not
configured with VLANIF interfaces.
----End
Context
The IP address of the VLANIF interface associated with a super-VLAN must contain
the subnets that users in sub-VLANs belong to. All the sub-VLANs will use that IP
address to conserve IP addresses.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run interface vlanif vlan-id
A VLANIF interface is created for a super-VLAN, and the view of the VLANIF
interface is displayed.
Step 3 Run either of the following commands as needed:
● Run ip address ip-address { mask | mask-length }
An IPv4 address is assigned to the VLANIF interface.
● Run ipv6 address { ipv6-address prefix-length | ipv6-address/prefix-length
An IPv6 address is assigned to the VLANIF interface.
----End
Context
VLAN aggregation allows sub-VLANs to use the same subnet address, but prevents
PCs in different sub-VLANs from communicating with each other over Layer 3.
PCs in common VLANs can communicate with each other over Layer 3 using
different gateway addresses. VLAN aggregation enables PCs in a super-VLAN to
use the same subnet address and gateway address. Because PCs in different sub-
VLANs belong to one subnet, they can only communicate with PCs in their sub-
VLAN. PCs in different sub-VLANs cannot communicate with each other.
Proxy ARP is required to enable PCs in a sub-VLAN to communicate with PCs in
another sub-VLAN or PCs on other networks. After a super-VLAN and its VLANIF
interface are created, proxy ARP must be enabled to allow the super-VLAN to
forward or process ARP Request and Reply packets.
NOTE
After proxy ARP is enabled on the VLANIF interface corresponding to a super-VLAN, PCs in
all sub-VLANs of the super-VLAN can communicate. If PCs in some sub-VLANs of the super-
VLAN need to communicate, see 6.8.1 How Do I Implement Communication Between
Specific Sub-VLANs in a Super-VLAN.
VLAN aggregation simplifies configurations for networks where many VLANs are
configured and PCs in different VLANs need to communicate with each other.
Procedure
Step 1 Run system-view
The system view is displayed.
Step 2 Run interface vlanif vlan-id
The view of the VLANIF interface corresponding to the super-VLAN is displayed.
Step 3 Run arp-proxy inter-sub-vlan-proxy enable
Proxy ARP is enabled between sub-VLANs.
----End
----End
Internet
Router
GE0/0/1
VLAN10
SwitchB Super-VLAN 4
GE0/0/5
GE0/0/5
SwitchA
GE0/0/1 GE0/0/4
GE0/0/2 GE0/0/3
VLAN2 VLAN3
Configuration Roadmap
Configure VLAN aggregation on SwitchB to add VLANs of different departments
to a super-VLAN so that PCs in different departments can access the Internet
using the super-VLAN. Deploy proxy ARP in the super-VLAN so that PCs in
different departments can communicate with each other. The configuration
roadmap is as follows:
1. Configure VLANs and interfaces on SwitchA and SwitchB, add PCs from
different departments to different VLANs, and configure interfaces to
transparently transmit packets from VLANs to SwitchB.
2. Configure a super-VLAN, a VLANIF interface, and a static route on SwitchB so
that PCs in different departments can access the Internet.
Procedure
Step 1 Configure VLANs and interfaces on SwitchA and SwitchB, add PCs from different
departments to different VLANs, and configure interfaces to transparently transmit
packets from VLANs to SwitchB.
1. Configure SwitchA.
# Configure GE0/0/1 as an access interface. The configurations of GE0/0/2,
GE0/0/3, and GE0/0/4 are similar to the configuration of GE0/0/1, and are not
mentioned here.
<HUAWEI> system-view
[HUAWEI] sysname SwitchA
[SwitchA] interface gigabitethernet 0/0/1
[SwitchA-GigabitEthernet0/0/1] port link-type access
[SwitchA-GigabitEthernet0/0/1] quit
2. Configure SwitchB.
# Create VLAN 2, VLAN 3, VLAN 4, and VLAN 10 and configure the interface
of SwitchB connected to SwitchA to transparently transmit packets from VLAN
2 and VLAN 3 to SwitchB.
<HUAWEI> system-view
[HUAWEI] sysname SwitchB
[SwitchB] vlan batch 2 3 4 10
[SwitchB] interface gigabitethernet 0/0/5
[SwitchB-GigabitEthernet0/0/5] port link-type trunk
[SwitchB-GigabitEthernet0/0/5] port trunk allow-pass vlan 2 3
[SwitchB-GigabitEthernet0/0/5] quit
# Create and configure VLANIF 4 so that PCs in different departments can access
the Internet using super-VLAN 4.
# Create and configure VLANIF 10 and specify the IP address of VLANIF 10 as the
IP address for connecting SwitchB and the router (egress gateway).
[SwitchB] interface vlanif 10
[SwitchB-Vlanif10] ip address 10.10.1.1 255.255.255.0
[SwitchB-Vlanif10] quit
# Configure a static route to the router on SwitchB so that PCs can access the
Internet.
[SwitchB] ip route-static 0.0.0.0 0.0.0.0 10.10.1.2
NOTE
Configure the router interface connected to SwitchB and assign the IP address of 10.10.1.2
to the router interface. See the router configuration manual.
----End
Configuration Files
● SwitchA configuration file
#
sysname SwitchA
#
vlan batch 2 to 3
#
interface GigabitEthernet0/0/1
port link-type access