175
•
Secondary VLANs 11 and 12 are associated with primary VLAN 10.
•
Secondary VLANs 21 and 22 are associated with primary VLAN 20.
Secondary VLAN Layer 3 communication configuration
example
Network requirements
As shown in
:
•
Primary VLAN 10 on Device B is associated with secondary VLANs 2 and 3.
•
The uplink port Ten-GigabitEthernet 1/0/1 is in VLAN 10.
•
The IP address of VLAN-interface 10 is 192.168.1.1/24.
•
The ports Ten-GigabitEthernet 1/0/2 and Ten-GigabitEthernet 1/0/3 are in VLAN 2 and VLAN 3,
respectively.
Configure secondary VLANs to be isolated at Layer 2 but interoperable at Layer 3.
Figure 48
Network diagram
Configuration procedure
# Create VLAN 2 and VLAN 3.
<DeviceB> system-view
[DeviceB] vlan 2 to 3
# Configure VLAN 10 as a primary VLAN, and associate VLAN 2 and VLAN 3 with primary VLAN 10
as secondary VLANs.
[DeviceB] vlan 10
[DeviceB-vlan10] private-vlan primary
[DeviceB-vlan10] private-vlan secondary 2 3
[DeviceB-vlan10] quit
# Configure the uplink port Ten-GigabitEthernet 1/0/1 to operate in promiscuous mode.
[DeviceB] interface ten-gigabitethernet 1/0/1
[DeviceB-Ten-GigabitEthernet1/0/1] port private-vlan 10 promiscuous
[DeviceB-Ten-GigabitEthernet1/0/1] quit
# Assign the downlink port Ten-GigabitEthernet 1/0/2 to VLAN 2, and configure the port to operate in
host mode.