Configuring a Port-Based VLAN
79
Configuring a
Port-Based VLAN
Configuring a
Port-Based VLAN
Configuration prerequisites
Create a VLAN before configuring a port-based VLAN.
Configuration procedure
c
CAUTION:
The commands above are effective for access ports only. If you want to
add trunk ports or hybrid ports to a VLAN, you need to use the
port trunk permit
vlan
command or the
port hybrid vlan
command in Ethernet port view. For the
configuration procedure, refer to “Ethernet Port Configuration” on page 96.
Port-Based VLAN
Configuration Example
Network requirements
■
As shown in Figure 32, Switch A and Switch B each connect to a server and a
workstation (PC).
■
For data security concerns, the two servers are assigned to VLAN 101 with the
descriptive string being "DMZ", and the PCs are assigned to VLAN 201.
■
The devices within each VLAN can communicate with each other but that in
different VLANs cannot communicate with each other directly.
Network diagram
Figure 32
Network diagram for VLAN configuration
Table 45
Configure a port-based VLAN
Operation
Command
Description
Enter system view
system-view
-
Enter VLAN view
vlan
vlan-id
-
Add Ethernet ports to
the specific VLAN
port
interface-list
Required
By default, all the ports belong to
the default VLAN (VLAN 1).
Switch A
VLAN 101
VLAN 201
Switch B
Server
Server
PC
PC
Eth1/0/1
Eth1/0/2
Eth1/0/10
Eth1/0/3
Eth1/0/12
Eth1/0/11
Summary of Contents for Switch 4210 9-Port
Page 22: ...20 CHAPTER 1 CLI CONFIGURATION ...
Page 74: ...72 CHAPTER 3 CONFIGURATION FILE MANAGEMENT ...
Page 84: ...82 CHAPTER 5 VLAN CONFIGURATION ...
Page 96: ...94 CHAPTER 8 IP PERFORMANCE CONFIGURATION ...
Page 108: ...106 CHAPTER 9 PORT BASIC CONFIGURATION ...
Page 122: ...120 CHAPTER 11 PORT ISOLATION CONFIGURATION ...
Page 140: ...138 CHAPTER 13 MAC ADDRESS TABLE MANAGEMENT ...
Page 234: ...232 CHAPTER 17 802 1X CONFIGURATION ...
Page 246: ...244 CHAPTER 20 AAA OVERVIEW ...
Page 270: ...268 CHAPTER 21 AAA CONFIGURATION ...
Page 292: ...290 CHAPTER 26 DHCP BOOTP CLIENT CONFIGURATION ...
Page 318: ...316 CHAPTER 29 MIRRORING CONFIGURATION ...
Page 340: ...338 CHAPTER 30 CLUSTER ...
Page 362: ...360 CHAPTER 33 SNMP CONFIGURATION ...
Page 368: ...366 CHAPTER 34 RMON CONFIGURATION ...
Page 450: ...448 CHAPTER 39 TFTP CONFIGURATION ...
Page 451: ......
Page 452: ...450 CHAPTER 39 TFTP CONFIGURATION ...
Page 470: ...468 CHAPTER 40 INFORMATION CENTER ...
Page 496: ...494 CHAPTER 44 DEVICE MANAGEMENT ...