162
{
Configure a downlink port, for example, the port connecting Device B to a host in
, to
operate in host mode. The downlink port can be automatically assigned to the secondary VLAN
and its associated primary VLAN.
{
If a downlink port allows multiple secondary VLANs, configure the port to operate in trunk
secondary mode. The downlink port can be automatically assigned to the secondary VLANs
and their associated primary VLANs.
For more information about promiscuous mode, trunk promiscuous mode, host mode, and trunk
secondary mode, see
Layer 2—LAN Switching Command Reference
.
4.
Associate the secondary VLANs with the primary VLAN.
5.
(Optional.) Configure Layer 3 communication between the specified secondary VLANs that are
associated with the primary VLAN.
Configuration restrictions and guidelines
When you configure the private VLAN feature, follow these restrictions and guidelines:
•
After you complete the private VLAN configurations, perform the following tasks:
{
For a port operating in promiscuous mode, make sure the following requirements are met:
−
The primary VLAN is the PVID of the port.
−
The port is an untagged member of the primary VLAN and secondary VLANs.
{
For a port operating in host mode, make sure the following requirements are met:
−
The PVID of the port is a secondary VLAN.
−
The port is an untagged member of the primary VLAN and secondary VLANs.
{
For a port operating in trunk promiscuous or trunk secondary mode, make sure the port is a
tagged member of the primary VLAN and the secondary VLANs.
•
VLAN 1 (system default VLAN) does not support the private VLAN configuration.
Configuration procedure
To configure the private VLAN feature:
Step Command
Remarks
1.
Enter system view.
system-view
N/A
2.
Create a VLAN and enter
VLAN view.
vlan
vlan-id
N/A
3.
Configure the VLAN as a
primary VLAN.
private-vlan primary
By default, a VLAN is not a primary
VLAN.
4.
Return to system view.
quit
N/A
5.
Create one or multiple
secondary VLANs.
vlan
{
vlan-id1
[
to
vlan-id2
]
|
all
} N/A