6-14
IP Subnet-Based VLAN Configuration
Introduction
In this approach, packets are assigned to VLANs based on their source IP addresses and subnet
masks. A port configured with IP subnet-based VLANs assigns a received untagged packet to a VLAN
based on the source address of the packet.
This feature is used to assign packets from the specified network segment or IP address to a specific
VLAN.
Configuring an IP Subnet-Based VLAN
This feature is only applicable on hybrid ports.
Follow these steps to configure an IP subnet-based VLAN:
To do…
Use the command…
Remarks
Enter system view
system-view
—
Enter VLAN view
vlan
vlan-id
—
Associate an IP subnet with the
current VLAN
ip-subnet-vlan
[
ip-subnet-index
]
ip
ip-address
[
mask
]
Required
The IP network segment or IP
address to be associated with
a VLAN cannot be a multicast
network segment or a
multicast address.
Return to system view
quit
—
Enter Ethernet
interface view
interface interface-type
interface-number
Enter Layer-2
aggregate
interface view
interface
bridge-aggregation
interface-number
Enter interface
view or port
group view
Enter port group
view
port-group manual
port-group-name
Required
Use either command.
z
In Ethernet interface view,
the subsequent
configurations apply to the
current port.
z
In port group view, the
subsequent configurations
apply to all ports in the port
group.
z
In Layer-2 aggregate
interface view, the
subsequent configurations
apply to the Layer-2
aggregate interface and all
its member ports.
Configure port link type as hybrid
port link-type
hybrid
Required
Configure the hybrid port(s) to
permit the specified IP
subnet-based VLANs to pass
through
port hybrid
vlan
vlan-id-list
{
tagged
|
untagged
}
Required