🎓 BookMCQ
← Back to 17. Connecting Devices and Virtual LANs

📝 Virtual LANs (VLANs) (16 MCQs)

Logical Network Segmentation Within Ethernet Switching

A virtual LAN groups selected switch ports or devices into a logical Layer 2 network, regardless of their physical location in the switching infrastructure. Each VLAN forms a separate broadcast domain, limiting the spread of broadcast frames and allowing network administrators to organize users, departments, or services independently of physical cabling arrangements across large campus, building, and office switching infrastructures.

VLAN Identifiers and Separate Broadcast Domains

IEEE 802.1Q assigns a VLAN identifier to tagged Ethernet frames on VLAN-aware links. Switches use VLAN membership and the identifier to keep traffic within the correct logical network. A VLAN is a Layer 2 construct; communication between different VLANs requires a Layer 3 device, such as a router or multilayer switch.

Frame Handling Within Access and Trunk Links

A device connected to an access port normally sends and receives untagged Ethernet frames belonging to that port's configured VLAN. A trunk link carries traffic for multiple VLANs, commonly using 802.1Q tags. Switches preserve the VLAN context as frames cross trunk links and remove the tag when forwarding to an untagged access port.

Separating Staff and Guest Computers

A switch may place staff computers in VLAN 10 and guest devices in VLAN 20. Broadcast frames from a staff computer remain within VLAN 10 and do not reach VLAN 20. To allow controlled communication between them, a router or Layer 3 switch must provide inter-VLAN routing and any required access policies.

VLANs, Security Boundaries and Network Management

VLANs simplify moves, additions, and changes because logical membership can be adjusted without rewiring the entire LAN. They reduce broadcast scope and support traffic separation, but VLANs alone are not a complete security solution. Inter-VLAN routing, switch management, and access-control rules must be configured carefully to control communication across the organization.

Misconceptions About VLAN Isolation

'A VLAN is a separate physical switch' is incorrect because several VLANs can share one switch. 'VLANs communicate automatically' is incorrect because inter-VLAN traffic requires Layer 3 routing. 'A VLAN tag encrypts traffic' is incorrect because 802.1Q identifies VLAN membership but does not provide confidentiality or cryptographic protection for transmitted data.

Interpreting VLAN IDs and Broadcast Boundaries

For examinations, identify VLANs as separate Layer 2 broadcast domains and distinguish access ports from trunk ports. Interpret the 802.1Q VLAN identifier, determine which ports receive a broadcast, and explain when inter-VLAN routing is required. Remember that VLAN separation is logical and does not itself encrypt traffic in practical network designs.

VLAN Segmentation and Tagging Terms

  • VLAN - Logical Layer 2 network segment.
  • Broadcast domain - Set of devices receiving broadcasts.
  • VID - Identifies a VLAN in a tag.
  • 802.1Q - Standard for VLAN-aware Ethernet tagging.
  • Access port - Connects endpoint to one VLAN.
  • Trunk port - Carries multiple VLANs.
5
Easy
6
Medium
5
Hard

📝 All Virtual LANs (VLANs) MCQs

Q1. If a layer‑2 switch connects LAN segments that already contain broadcast domains, what is the most likely immediate effect?

A.Broadcast storm ✅
B.Reduced latency
C.Increased unicast throughput
D.Elimination of collisions
💡 Difficulty: easy | ✅ Correct: A

📖 Explanation: A looped broadcast domain causes frames to be endlessly replicated, producing a broadcast storm that quickly consumes bandwidth and overwhelms devices. This is the typical symptom when switches create loops without spanning‑tree protection.

Q2. What does the acronym VLAN stand for?

A.Virtual Local Area Network ✅
B.Variable LAN
C.Virtual Link Access Node
D.Verified LAN
💡 Difficulty: easy | ✅ Correct: A

📖 Explanation: The term VLAN expands to Virtual Local Area Network, describing a logical segmentation of a physical LAN that allows devices to communicate as if they were on the same physical segment, even when they are not.

Q3. How does 802.1Q tagging enable multiple VLANs to share a single physical trunk link?

A.By inserting a VLAN ID field into the Ethernet header
B.By encrypting each frame with a VLAN key
C.By assigning separate MAC addresses per VLAN ✅
D.By using separate physical cables for each VLAN
💡 Difficulty: medium | ✅ Correct: C

📖 Explanation: 802.1Q adds a four‑byte tag after the source MAC address, containing a 12‑bit VLAN identifier. This tag travels with the frame across the trunk, allowing switches to separate traffic into the appropriate VLAN while using only one cable.

Q4. Which statement best contrasts the behavior of a hub and a switch when VLANs are configured?

A.A hub forwards frames to all ports regardless of VLAN, while a switch forwards only within the VLAN ✅
B.A hub can isolate VLANs, a switch cannot
C.A hub supports 802.1Q tagging, a switch does not
D.Both devices treat VLANs identically
💡 Difficulty: medium | ✅ Correct: A

📖 Explanation: A hub operates at the physical layer and floods all incoming frames to every port, ignoring VLAN tags. In contrast, a switch inspects the tag and forwards frames only to ports belonging to the same VLAN, preserving logical separation.

Q5. When a trunk port’s native VLAN on one switch differs from the native VLAN on the neighboring switch, what problem typically occurs?

A.Traffic loss for untagged frames ✅
B.Increased throughput
C.Automatic VLAN reconciliation
D.No impact
💡 Difficulty: easy | ✅ Correct: A

📖 Explanation: If the native VLANs differ, untagged frames arriving on the trunk are placed in the wrong VLAN on the far end, causing those frames to be dropped or misrouted, which manifests as apparent traffic loss for the affected VLAN.

Q6. Why does placing each department in its own VLAN reduce the size of collision domains?

A.Because each VLAN creates a separate broadcast domain that isolates collisions ✅
B.Because VLANs increase the number of switches required
C.Because VLANs convert collisions into unicast traffic
D.Because VLANs disable CSMA/CD
💡 Difficulty: medium | ✅ Correct: A

📖 Explanation: VLANs logically partition a switched network, so frames from one department are confined to its VLAN. This isolation prevents collisions generated in one VLAN from being seen by devices in another, effectively shrinking the collision domain to the VLAN’s members.

Q7. When evaluating security, how does a VLAN‑based approach differ from using an ACL on a router?

A.VLANs restrict traffic at Layer 2, while ACLs filter at Layer 3 or higher ✅
B.VLANs encrypt data, ACLs do not
C.VLANs replace firewalls, ACLs are redundant
D.VLANs provide authentication, ACLs do not
💡 Difficulty: medium | ✅ Correct: A

📖 Explanation: VLANs enforce segregation by keeping traffic within distinct Layer 2 domains, preventing unauthorized crossing before any Layer 3 routing occurs. ACLs, however, inspect and permit/deny traffic after it has been routed, making VLANs a more proactive security boundary.

Q8. In a network of three switches where Switch A hosts VLAN 10, Switch B hosts VLAN 20, and a trunk links them, what happens to a broadcast frame generated in VLAN 10 on Switch A?

A.It is forwarded only on ports belonging to VLAN 10 ✅
B.It is flooded to all ports including VLAN 20
C.It is dropped because VLAN 20 does not exist on Switch A
D.It is converted to unicast before leaving the trunk
💡 Difficulty: hard | ✅ Correct: A

📖 Explanation: The trunk carries the VLAN tag, so the broadcast remains tagged as VLAN 10. Switch B receives the frame, recognizes the tag, and forwards it only to ports assigned to VLAN 10, never to VLAN 20, preserving VLAN isolation.

Q9. How does integrating the Spanning‑Tree Protocol (STP) with VLANs prevent network loops while maintaining VLAN separation?

A.STP runs a separate instance per VLAN, blocking only the links that would cause a loop within that VLAN ✅
B.STP disables all trunk ports when a loop is detected
C.STP merges all VLANs into a single broadcast domain
D.STP replaces VLAN tagging entirely
💡 Difficulty: hard | ✅ Correct: A

📖 Explanation: Modern STP implementations, such as PVST+, instantiate a distinct spanning‑tree for each VLAN. When a potential loop is identified, the protocol blocks the offending port only for the affected VLAN, allowing other VLANs to continue using the same physical link without disruption.

Q10. Which VLAN implementation method offers the greatest mobility for devices that frequently change locations?

A.MAC‑based VLANs ✅
B.Port‑based VLANs
C.IP‑subnet VLANs
D.Time‑based VLANs
💡 Difficulty: hard | ✅ Correct: A

📖 Explanation: MAC‑based VLANs assign membership based on the device’s MAC address rather than the physical port. When a device moves to a new port, the switch still places it in the same VLAN, eliminating the need to reconfigure the port and providing seamless mobility.

Q11. If a network interface receives Ethernet frames with a VLAN ID of 0, what does that indicate?

A.Priority tagging without a VLAN identifier ✅
B.A misconfiguration of the trunk port
C.The frame belongs to the default VLAN
D.The switch has disabled VLAN tagging
💡 Difficulty: easy | ✅ Correct: A

📖 Explanation: A VLAN ID of 0 is defined by the 802.1Q standard for priority tagging: the frame carries QoS priority information but no VLAN assignment, allowing the frame to be treated as belonging to the native VLAN while preserving priority bits.

Q12. What role does the VLAN Trunking Protocol (VTP) play in maintaining VLAN consistency across multiple switches?

A.It propagates VLAN configuration information so that all switches share the same VLAN database ✅
B.It encrypts VLAN tags for security
C.It assigns IP addresses to VLANs automatically
D.It replaces the need for spanning‑tree protocol
💡 Difficulty: medium | ✅ Correct: A

📖 Explanation: VTP allows a designated switch to act as a server, distributing VLAN creation, deletion, and naming information to all client switches. This ensures that each switch maintains an identical VLAN database, simplifying management and reducing configuration errors.

Q13. How does using multiple VLANs instead of a single broadcast domain affect overall network performance?

A.It reduces unnecessary broadcast traffic, freeing bandwidth for useful data ✅
B.It increases latency because of additional tagging
C.It has no effect on performance
D.It doubles the amount of required cabling
💡 Difficulty: medium | ✅ Correct: A

📖 Explanation: Segmenting a network into VLANs confines broadcasts to the relevant group, preventing them from flooding the entire infrastructure. This limits wasted bandwidth, lowers CPU load on devices, and generally improves throughput compared with a flat, single‑broadcast‑domain design.

Q14. When a trunk link employs 802.1Q tagging, what is the theoretical maximum number of distinct VLANs that can be identified on that link?

A.4094 ✅
B.1024
C.2048
D.8192
💡 Difficulty: hard | ✅ Correct: A

📖 Explanation: The 802.1Q tag contains a 12‑bit VLAN identifier field, allowing 212=40962^{12}=4096 possible values. Two values (0 and 4095) are reserved, leaving 4094 usable VLAN IDs for segmentation on a single trunk.

Q15. In a multi‑tenant data center that uses VLANs for isolation, which design principle most directly supports scalability as the number of tenants grows?

A.Assigning each tenant a unique VLAN ID and using hierarchical spanning‑tree to manage trunks ✅
B.Merging all tenant traffic into a single VLAN to simplify configuration
C.Relying on a single physical switch for all VLANs
D.Disabling VLAN tagging to reduce overhead
💡 Difficulty: hard | ✅ Correct: A

📖 Explanation: By giving each tenant its own VLAN ID and organizing switches with hierarchical spanning‑tree, the network can add new tenants simply by creating new VLANs and extending trunks, without redesigning the physical topology, thereby scaling efficiently.

Q16. Which advantage best distinguishes a managed switch from an unmanaged hub when creating VLANs?

A.A managed switch can enforce VLAN membership and isolate traffic, while a hub cannot ✅
B.A managed switch increases cable length limits
C.A hub provides higher bandwidth than a managed switch
D.A hub automatically creates VLANs without configuration
💡 Difficulty: easy | ✅ Correct: A

📖 Explanation: Managed switches operate at the data‑link layer, understand VLAN tags, and can forward frames only to ports belonging to the same VLAN, achieving traffic isolation. Unmanaged hubs lack any intelligence; they simply repeat all incoming signals to every port, making VLAN segregation impossible.

🔗 Related Topics (MCQs)