VLANs
Normal-range VLANs, data and voice access ports, the default VLAN, and how VLANs segment a switch into broadcast domains.
VLANs and broadcast domains
A VLAN (virtual LAN) is a logical broadcast domain on a switch: ports in different VLANs cannot exchange Layer 2 frames without a router. The normal range is 1–1005 (1002–1005 are legacy reserved), with user VLANs commonly numbered 2–1001; VLAN 1 is the factory default — every port starts there.
VLAN ranges
| Range | Numbers | Use |
|---|---|---|
| Default | 1 | Factory default; often left for management — know it's the default |
| Normal | 2–1001 | Standard user/data VLANs |
| Reserved | 1002–1005 | Token Ring/FDDI legacy defaults |
| Extended | 1006–4094 | Extended range — stored in running config only, not in VLAN.dat or VTP v1/2 |
Data and voice access ports
An access port carries exactly one data VLAN — the host attached sees ordinary untagged frames. A voice VLAN is a second VLAN assigned alongside the data VLAN: the switch tells the IP phone (via CDP/LLDP) to tag its traffic into the voice VLAN while the PC behind the phone stays untagged in the data VLAN.
Access port assignments
| Setting | Command | Effect |
|---|---|---|
| Data VLAN | switchport access vlan 20 | Port joins VLAN 20 for untagged host traffic |
| Voice VLAN | switchport voice vlan 30 | Phone tags into VLAN 30; PC stays in data VLAN |
| Mode | switchport mode access | Pins the port as an edge port, never a trunk |
- Requirements
- PCs + phones on every desk, printers, management of the switches themselves
- Separate broadcast domains per function: VLAN 20 data, 30 voice, 40 printers, 99 management.
- Every desk port:
switchport access vlan 20+switchport voice vlan 30. - Printer-only ports: access VLAN 40. Switch management SVIs live on VLAN 99.
One access VLAN + one voice VLAN per desk port — trunks carry the rest between switches.
Configuration and verification
Create a data and voice VLAN and wire a PC+phone port — Privileged EXEC → Global + interface configuration
Cisco IOS / IOS XE
configure terminal vlan 20 name SALES exit vlan 30 name VOICE exit interface gigabitethernet1/0/1 switchport mode access switchport access vlan 20 switchport voice vlan 30 end
show vlan brief show interfaces gi1/0/1 switchport
show vlan brieflists the VLAN with the port in its membership column.- switchport output shows Access Mode VLAN 20 and Voice VLAN 30.
- VLANs persist in vlan.dat — deleting the VLAN removes it, but saved config alone does not recreate it on some platforms.
Changes device configuration.
VLAN Name Status PortsOne line per VLAN.1 default active Gi1/0/10VLAN 1 always exists; ports not reassigned stay here.20 SALES active Gi1/0/1, Gi1/0/2Members of the data VLAN.30 VOICE active Voice VLAN shows no port here — check switchport output for voice assignment.Common mistakes
- Expecting access ports to carry multiple data VLANs — only trunks do; access ports carry one data VLAN (plus a voice VLAN).
- Using VLAN 1 for user traffic as a habit — it's the default and often targeted by attacks; put users on a real VLAN.
- Deleting the VLAN thinking the port config cleans itself up — orphaned access ports end up in a nonexistent VLAN and stop forwarding.
- Assuming VLANs route between themselves — you always need a Layer 3 device.
Observation: Two PCs in VLAN 20 cannot reach each other across two switches.
- VLAN 20 not created on the second switch
- The inter-switch link does not carry VLAN 20
- Ports assigned to different VLANs
| Check | Indicates |
|---|---|
show vlan brief on both switches | VLAN absent on switch 2 → it never traverses. |
show interfaces trunk | VLAN 20 missing from 'allowed and active' list blocks it at the trunk. |
show run interface on each access port | Confirms the actual assigned VLAN. |
Correction: Create the VLAN where missing and allow it on the trunk.
show vlan brief shows both ports in VLAN 20 on both switches and pings pass.
Related resources
Sources
- Cisco CCNA 200-301 v1.1 Exam Topics (official PDF) — reviewed 2026-11-02
- Cisco — LAN Switching Command Reference — reviewed 2026-11-02
Targets CCNA 200-301 v1.1 objectives. Supplemental blocks are labeled beyond exam scope.