3.3.12 Packet Tracer - Vlan Configuration

7 min read

Configuring VLANs in Cisco Packet Tracer: A Step‑by‑Step Guide (Version 3.3.12)

When you first encounter VLANs (Virtual Local Area Networks) in a networking lab, the idea of subdividing a single physical switch into multiple logical networks can feel daunting. Here's the thing — 12 offers a practical, hands‑on way to master this concept without the need for expensive hardware. That's why cisco Packet Tracer version 3. Still, 3. In this article we walk through the entire process—from creating VLANs on a switch to assigning ports, configuring trunk links, and verifying connectivity—all while keeping the language clear and the steps easy to follow.

This is where a lot of people lose the thread.


Introduction

VLANs let you segment a LAN into isolated broadcast domains, improving security, reducing congestion, and simplifying network management. Consider this: in Packet Tracer, the process mirrors real‑world Cisco IOS commands, giving you a realistic feel for how switches behave. Whether you’re a student preparing for the CCNA exam or a hobbyist curious about network design, this guide will help you understand both the why and the how of VLAN configuration Small thing, real impact. Nothing fancy..


1. Setting the Stage: The Lab Topology

Before we dive into commands, let’s outline a simple topology that illustrates both access and trunk links:

[PC‑A] -- 10/100   -- [Switch‑1] -- 10/100   -- [PC‑B]
                               |
                               | 10/100  (trunk)
                               |
                          [Switch‑2] -- 10/100   -- [PC‑C]
  • Switch‑1 and Switch‑2 are cisco2960 models (the default switch type in Packet Tracer 3.3.12).
  • PC‑A and PC‑B belong to VLAN 10 (e.g., Sales).
  • PC‑C belongs to VLAN 20 (e.g., Engineering).
  • The link between Switch‑1 and Switch‑2 is a trunk that carries both VLAN 10 and VLAN 20.

With this topology, we’ll:

  1. Create VLAN 10 and VLAN 20 on both switches.
  2. Assign ports on Switch‑1 to VLAN 10 and Switch‑2 to VLAN 20.
  3. Configure the inter‑switch link as a trunk.
  4. Verify connectivity and VLAN membership.

2. Accessing the Switch CLI

  1. Open Packet Tracer and build the topology described above.
  2. Click on Switch‑1CLI tab.
  3. When prompted, press Enter to enter the default mode and then type enable to access privileged EXEC mode.
  4. Enter configure terminal to switch to global configuration mode.

3. Creating VLANs

In global configuration mode, create the two VLANs:

Switch# configure terminal
Switch(config)# vlan 10
Switch(config-vlan)# name Sales
Switch(config-vlan)# exit
Switch(config)# vlan 20
Switch(config-vlan)# name Engineering
Switch(config-vlan)# exit

Tip: Naming VLANs improves readability. In Packet Tracer, the name appears in the VLAN table, helping you keep track of which VLAN serves which purpose But it adds up..

Repeat the same steps on Switch‑2 to ensure both switches recognize VLAN 10 and VLAN 20.


4. Assigning Ports to VLANs

4.1 Switch‑1 (Access Ports)

  1. Enter the interface configuration mode for the port connected to PC‑A (assume it’s FastEthernet0/1):
Switch(config)# interface FastEthernet0/1
Switch(config-if)# switchport mode access
Switch(config-if)# switchport access vlan 10
Switch(config-if)# exit
  1. Repeat for the port connected to PC‑B (FastEthernet0/2):
Switch(config)# interface FastEthernet0/2
Switch(config-if)# switchport mode access
Switch(config-if)# switchport access vlan 10
Switch(config-if)# exit

4.2 Switch‑2 (Access Port)

Assign the port connected to PC‑C (FastEthernet0/1) to VLAN 20:

Switch(config)# interface FastEthernet0/1
Switch(config-if)# switchport mode access
Switch(config-if)# switchport access vlan 20
Switch(config-if)# exit

5. Configuring the Trunk Link

The trunk link must carry traffic for both VLAN 10 and VLAN 20. Which means by default, Cisco switches use IEEE 802. 1Q encapsulation for trunks.

  1. On Switch‑1, configure the port connected to Switch‑2 (assume FastEthernet0/24):
Switch(config)# interface FastEthernet0/24
Switch(config-if)# switchport mode trunk
Switch(config-if)# switchport trunk allowed vlan 10,20
Switch(config-if)# exit
  1. On Switch‑2, configure the corresponding port (FastEthernet0/24) similarly:
Switch(config)# interface FastEthernet0/24
Switch(config-if)# switchport mode trunk
Switch(config-if)# switchport trunk allowed vlan 10,20
Switch(config-if)# exit

Why limit the VLANs? In a real deployment you’d restrict the trunk to only the VLANs that need to traverse it, reducing unnecessary broadcast traffic.


6. Verifying the Configuration

6.1 Check VLAN Membership

Switch# show vlan brief

You should see:

VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
10   Sales                             active    Fa0/1, Fa0/2
20   Engineering                       active    Fa0/1
...

6.2 Inspect Trunk Status

Switch# show interfaces trunk

The output should list the trunk port, the encapsulation type (IEEE 802.1Q), and the allowed VLANs Less friction, more output..

6.3 Test Connectivity

Assign IP addresses to the PCs (e.20.10.Now, 168. 11/24, PC‑C: 192., PC‑A: 192.10/24, PC‑B: 192.Even so, g. 10.Still, 168. Think about it: 168. 10/24).

  • PC‑A pinging PC‑B → Success (same VLAN).
  • PC‑A pinging PC‑C → Failure (different VLAN, no inter‑VLAN routing configured).

If you want PCs in different VLANs to communicate, you’d need a Layer 3 device (router or multilayer switch) with sub‑interfaces configured for each VLAN.


7. Common Pitfalls & Troubleshooting

Symptom Likely Cause Fix
Ports show down Interface not enabled or cable not connected no shutdown on the interface
Trunk shows no trunk Trunk mode not set or encapsulation mismatch switchport mode trunk and verify switchport trunk encapsulation dot1q if using older switches
VLAN not recognized on remote switch VLAN not created on both switches Create VLAN on the other switch
PCs cannot ping each other within the same VLAN Port not assigned to VLAN Reassign port to correct VLAN
Trunk port shows trunking but VLANs not allowed Allowed VLAN list incorrect switchport trunk allowed vlan add 10,20

8. Extending the Lab: Adding a Layer‑3 Switch

To enable inter‑VLAN routing:

  1. Add a cisco3560 (or any Layer‑3 capable switch) between Switch‑1 and Switch‑2.
  2. Configure SVI (Switched Virtual Interface) for each VLAN:
Switch(config)# interface Vlan10
Switch(config-if)# ip address 192.168.10.1 255.255.255.0
Switch(config-if)# no shutdown
Switch(config-if)# exit
Switch(config)# interface Vlan20
Switch(config-if)# ip address 192.168.20.1 255.255.255.0
Switch(config-if)# no shutdown
  1. Enable routing:
Switch(config)# ip routing
  1. Connect the trunk links from the Layer‑3 switch to Switch‑1 and Switch‑2, then set PCs’ default gateways to the corresponding SVI IPs.

Now PCs across VLAN 10 and VLAN 20 can ping each other, demonstrating a complete VLAN and inter‑VLAN routing setup Nothing fancy..


9. FAQ

Q1: Can I use Voice VLANs in Packet Tracer?
A1: Yes, Packet Tracer supports Voice VLANs. Use switchport voice vlan 30 on an access port to separate voice traffic from data.

Q2: How do I delete a VLAN?
A2: Use no vlan 10 in global configuration mode. Remember to remove any ports assigned to that VLAN first.

Q3: What happens if I leave a trunk port in access mode?
A3: The port will carry only untagged traffic for the assigned VLAN, and any tagged frames will be dropped Took long enough..

Q4: Can I create VLANs with names that contain spaces?
A4: In Packet Tracer, VLAN names must be single words. Use underscores or hyphens instead.


10. Conclusion

Mastering VLAN configuration in Cisco Packet Tracer equips you with a foundational skill set that translates directly to real‑world networking. Whether you’re preparing for certification exams or simply expanding your technical knowledge, the hands‑on practice offered by Packet Tracer makes learning both effective and engaging. By carefully creating VLANs, assigning ports, configuring trunk links, and verifying each step, you confirm that your network remains organized, secure, and scalable. Happy switching!

Out This Week

Recently Launched

Branching Out from Here

Related Posts

Thank you for reading about 3.3.12 Packet Tracer - Vlan Configuration. We hope the information has been useful. Feel free to contact us if you have any questions. See you next time — don't forget to bookmark!
⌂ Back to Home