Week 5 · Lesson 13

VLAN Configuration and Access Ports

Knowing what a VLAN is earns you a concept; knowing how to create one earns you marks. This lesson turns the theory into IOS commands — creating a VLAN, naming it, and assigning a port to it as an access port — plus the one command that separates voice from data on a single cable.

CCNA 200-301 Domain 2.0 Network Access Verified 2026-10-11
Learning objectives
Part 1

Step 1 — create and name the VLAN

VLANs are created from global configuration mode with the vlan command. The number enters the normal range unless you specify the extended keyword. A name is optional but strongly recommended — “Students” is much easier to read in a troubleshooting log than “VLAN 10”.

S1# configure terminal
S1(config)# vlan 10
S1(config-vlan)# name Students
S1(config-vlan)# exit
S1(config)# vlan 20
S1(config-vlan)# name Staff
S1(config-vlan)# exit

Two details matter for the exam. First, the command is vlan 10 and then name Students — the name is always a separate command inside the config-vlan submenu. Second, the VLAN does not actually carry traffic anywhere until you assign ports: creating VLAN 10 and stopping is an empty shell.

Note On Cisco IOS, normal-range VLANs are stored in the VLAN database file (vlan.dat, which lives in flash), not in running-config. That is why show vlan brief and show running-config tell two different stories, and why write memory alone may not save a VLAN. The classic mistake is creating the VLAN and rebooting, only to find it gone.
In this lesson · select a part to jump

Key ideas & exam traps · select one

Part 2

Step 2 — assign ports as access ports

Now tell the switch which ports belong to which VLAN. The interface is entered, placed in access mode, and joined to the VLAN:

S1(config)# interface gigabitethernet 0/1
S1(config-if)# switchport mode access
S1(config-if)# switchport access vlan 10
S1(config-if)# exit

S1(config)# interface gigabitethernet 0/2
S1(config-if)# switchport mode access
S1(config-if)# switchport access vlan 20
S1(config-if)# end

Three commands, in this exact rhythm, and the port now belongs to the VLAN. The mode command first makes the port an access port; the access vlan command then says which VLAN it serves. If you type switchport access vlan 10 without first setting switchport mode access, IOS may still accept it — but a port that has never been given the mode access command stays in dynamic desirable/auto trunk negotiation, which is almost never what you want on a host-facing port.

Exam tip The one-liner the exam keeps testing: an access port belongs to a single VLAN (its access VLAN) and sends frames untagged. The two commands to remember are switchport mode access and switchport access vlan <id> — in that order. Reversing the order still works in most IOS versions, but the memorised sequence is mode first, VLAN second.
Part 3

Step 3 — verify with show commands

Two show commands answer almost every VLAN verification question:

S1# show vlan brief
VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
1    default                          active    Gi0/3, Gi0/4, Gi0/5, Gi0/6
10   Students                         active    Gi0/1
20   Staff                            active    Gi0/2
1002 fddi-default                     act/unsup
1003 token-ring-default               act/unsup
1004 fddinet-default                  act/unsup
1005 trnet-default                    act/unsup

show vlan brief shows the VLAN, its name, its state, and — crucially — which ports are assigned to it. Note two things: the default untagged ports still sit in VLAN 1, and VLANs 1002–1005 appear by default in the act/unsup state because the switch does not support Token Ring or FDDI. show vlan id 10 is the targeted version:

S1# show vlan id 10
VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
10   Students                         active    Gi0/1
Watch out The port list in show vlan brief is your fastest diagnostic. If a PC in VLAN 10 cannot reach its server and show vlan brief lists the server’s port under VLAN 1, the problem is not routing, not cables, not IP — it is that the access VLAN was never configured on that interface. Always read the port column before you pull a cable.
Part 4

What an access port really is

An access port is a switch port configured to carry exactly one VLAN’s traffic, and it tags nothing. Frames leaving an access port are plain, untagged Ethernet frames — the receiving device (a PC, a printer, an IP phone’s network port) never even sees a VLAN tag and has no idea one exists. If the access port’s VLAN changes, the same physical link suddenly carries a different virtual LAN; the host never notices because none of this appears in Layer 3.

This is the crucial contrast for the syllabus: access ports connect to end devices and carry one untagged VLAN, while trunk ports connect switches together and carry many VLANs, tagging all except the native VLAN. You will configure trunks properly in Lesson 14; the exam wants you to already recognise the dividing line: host-facing access, switch-to-switch trunk.

Access port Gi0/1 carries two VLANs Switch S1 Gi0/1 access vlan 10 + 20 IP Phone voice = VLAN 20 PC data = VLAN 10 VLAN 10 untagged VLAN 20 (voice) untagged data The phone marks voice frames (for example 802.1p / DSCP EF) and re-tags them into the voice VLAN.
One access port, two VLANs: the data VLAN rides the link untagged, the voice VLAN is tagged between the switch and the phone. The PC’s data arrives at the switch in VLAN 10; the phone’s audio arrives in VLAN 20.
Part 5

The voice VLAN on an access port

The configuration that brings the figure to life has two halves. The port must carry the PC’s data VLAN as its access VLAN and announce a separate voice VLAN to the phone. Cisco phones learn which VLAN to use through CDP, which is why CDP must be running on the port (Lesson 16):

S1(config)# interface gigabitethernet 0/1
S1(config-if)# switchport mode access
S1(config-if)# switchport access vlan 10
S1(config-if)# switchport voice vlan 20
S1(config-if)# end

switchport voice vlan 20 tells the switch: frames arriving from the phone in the voice VLAN should be accepted, and the phone should place its own traffic in VLAN 20. The switch then applies both VLANs to the same access interface: VLAN 10 untagged for the PC<>phone data path, VLAN 20 for the phone’s audio. Traffic separation remains intact while the cabling stays a single cable — the phone has a built-in three-port switch that separates PC and phone frames internally.

Definition — voice VLAN The voice VLAN is the VLAN dedicated to IP phone traffic on an access port. It is configured with switchport voice vlan <id> and lets one physical port serve both a PC’s data VLAN and the phone’s voice VLAN, keeping the two traffic classes isolated and letting QoS prioritise the voice.
Part 6

Access versus trunk at a glance

CharacteristicAccess portTrunk port
Connects toEnd devices (PC, printer, phone)Other switches, routers, Layer 3 switches
VLANs carriedOne (its access VLAN, plus an optional voice VLAN)Many VLANs, typically all in the native + allowed list
TaggingNone — frames leave untaggedTagged with 802.1Q, except the native VLAN
Key commandsswitchport mode access, switchport access vlan, switchport voice vlanswitchport mode trunk, switchport trunk native vlan, switchport trunk allowed vlan (Lesson 14)
Reference table · select a row

Part 7

Configuration traps and best practice

Three mistakes account for nearly every real-world VLAN misconfiguration, and each one appears in exam scenarios:

  1. Creating the VLAN but never assigning a port. The VLAN exists, the name is set, but no interface says switchport access vlan, so the devices stay in VLAN 1. show vlan brief shows an empty port list.
  2. Assigning the port to a VLAN that does not exist. IOS creates the VLAN implicitly on most modern switches, which hides the error — but the host ends up in a VLAN you never intended. Check show vlan brief after, not just before.
  3. Forgetting which VLAN is native. On an access port there is no native concept; on a trunk it exists and defaults to VLAN 1. Mixing the two ideas is a favourite distractor (Lesson 14).
Best practice Name every VLAN, keep a documented numbering plan (10 = data, 20 = voice, 30 = management, and so on), assign access ports with switchport mode access before switchport access vlan, and verify with show vlan brief. Predictable configuration is reviewable configuration — and the exam rewards reviewable habits.
Key terms

The vocabulary you need

Every term below appears in the lesson text above. Select one to read its definition, then use the quiz at the end to check what stuck.

Key terms · select a term

Part 8 · Your turn

Review

Check what you have learned with these review questions.

Review · 5 questions

Sources

Sources & references

  1. Cisco. CCNA (200-301) Exam Topics. cisco.com.
  2. IETF. Request for Comments (RFCs). rfc-editor.org.
  3. IANA. Internet Assigned Numbers Authority registries. iana.org.

Target exams: CCNA 200-301 v1.1 · CyberOps Associate 200-201. Last content verification: 2026-10-11.