CCNA Switching and Network Access Practice Question
Exhibit
R1#show running-config | section interface GigabitEthernet0/0 interface GigabitEthernet0/0 no ip address duplex auto speed auto ! interface GigabitEthernet0/0.10 encapsulation dot1Q 10 ip address 192.168.10.1 255.255.255.0 ! R1#show running-config | include ip routing no ip routing R1#show interfaces trunk Port Mode Encapsulation Status Native vlan Gi0/0 on 802.1q trunking 99 Port Vlans allowed on trunk Gi0/0 10,20 Port Vlans allowed and active in management domain Gi0/0 10
You are connected to R1. The network consists of R1, SW1, and two hosts (Host-A on VLAN 10, Host-B on VLAN 20). SW1 has two access ports (one per VLAN) and a trunk to R1. Configure R1 for router-on-a-stick inter-VLAN routing. The current configuration has a native VLAN mismatch and a missing subinterface for VLAN 20. Fix these issues so that Host-A and Host-B can ping each other.
⚠ Common exam trap
Be careful to identify all issues in the scenario. Candidates often focus only on the missing subinterface and forget to check the native VLAN mismatch and the global 'ip routing' command. Always verify that routing is enabled and that native VLANs match on both ends of the trunk.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
Configure interface G0/0.20 with encapsulation dot1Q 20 and IP address 192.168.20.1 255.255.255.0, set native VLAN to 1 on the trunk, and enable ip routing.
The native VLAN mismatch exists: R1 expects native VLAN 99, but SW1 likely uses native VLAN 1 (default). This causes CDP/STP issues but not directly inter-VLAN routing; however, for proper operation, set native VLAN to 1 on R1. Additionally, the subinterface for VLAN 20 is missing, so traffic from VLAN 20 cannot be routed. Finally, 'ip routing' is disabled, preventing any inter-VLAN routing. Solution: change native VLAN on trunk to 1, create subinterface G0/0.20 with encapsulation dot1Q 20 and IP 192.168.20.1/24, and enable ip routing.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
Configure interface G0/0.20 with encapsulation dot1Q 20 and IP address 192.168.20.1 255.255.255.0, set native VLAN to 1 on the trunk, and enable ip routing.
Why this is correct
Ly addresses all three issues: it creates the missing subinterface for VLAN 20 with proper encapsulation and IP address, changes the native VLAN to 1 to match the switch (default), and enables IP routing globally, which is required for inter-VLAN routing.
- ✗
Configure interface G0/0.20 with encapsulation dot1Q 20 and IP address 192.168.20.1 255.255.255.0, set native VLAN to 99 on the trunk, and enable ip routing.
Why it's wrong here
This is incorrect because setting the native VLAN to 99 on R1 would not match the switch's native VLAN (likely default 1), perpetuating the native VLAN mismatch. While it creates the subinterface and enables routing, the mismatch can cause issues with CDP and STP, and may affect untagged traffic.
- ✗
Configure interface G0/0.20 with encapsulation dot1Q 20 and IP address 192.168.20.1 255.255.255.0, set native VLAN to 1 on the trunk, but do not enable ip routing.
Why it's wrong here
Subinterfaces with dot1Q encapsulation and an IP address only terminate VLAN 20 at Layer 3; without 'ip routing' the router has no mechanism to forward packets between its own subinterfaces. Even though encapsulation and the native VLAN are correct, the hardware/software forwarding path remains disabled, so packets from VLAN 20 cannot reach VLAN 10 or any other VLAN. The command 'ip routing' is what activates the router's IP forwarding engine, and omitting it leaves the router acting as nothing more than a host with two logical interfaces.
- ✗
Configure interface G0/0.20 with encapsulation dot1Q 20 and IP address 192.168.20.1 255.255.255.0, set native VLAN to 99 on the trunk, and do not enable ip routing.
Why it's wrong here
This configuration inherits a native VLAN mismatch because the switch trunk expects untagged control and user traffic on VLAN 1, not 99, which can cause CDP and STP to drop adjacency and mis-handle native frames. Additionally, disabling 'ip routing' means that even if the subinterface for VLAN 20 is correctly addressed, the router will not make routing decisions between G0/0.20 and any other interface, so inter-VLAN traffic is never forwarded. Fixing the native VLAN alone or enabling routing alone is insufficient—the absolute requirement is to match the native VLAN to 1 AND issue 'ip routing' to invoke Layer 3 forwarding.
Option-by-option analysis
Why each answer is right or wrong
Understanding why wrong answers are wrong — and when they would be correct — is what separates a 750 score from a 900. The 200-301 exam frequently reuses these exact scenarios with slightly different constraints.
✓Configure interface G0/0.20 with encapsulation dot1Q 20 and IP address 192.168.20.1 255.255.255.0, set native VLAN to 1 on the trunk, and enable ip routing.Correct answer▾
Why this is correct
Ly addresses all three issues: it creates the missing subinterface for VLAN 20 with proper encapsulation and IP address, changes the native VLAN to 1 to match the switch (default), and enables IP routing globally, which is required for inter-VLAN routing.
✗Configure interface G0/0.20 with encapsulation dot1Q 20 and IP address 192.168.20.1 255.255.255.0, set native VLAN to 99 on the trunk, and enable ip routing.Wrong answer — click to see why▾
Why this is wrong here
The native VLAN mismatch is not resolved; the switch likely uses native VLAN 1, so R1 should also use 1 or both sides must be configured consistently.
Why candidates choose this
Candidates may think that setting native VLAN to 99 is correct because it was mentioned in the scenario, but they overlook that the switch uses default native VLAN 1.
✗Configure interface G0/0.20 with encapsulation dot1Q 20 and IP address 192.168.20.1 255.255.255.0, set native VLAN to 1 on the trunk, but do not enable ip routing.Wrong answer — click to see why▾
Why this is wrong here
IP routing is disabled by default on Cisco routers; it must be explicitly enabled for the router to perform routing functions.
Why candidates choose this
Candidates may assume that creating subinterfaces automatically enables routing, or they may forget that 'ip routing' is a global command required for inter-VLAN routing.
✗Configure interface G0/0.20 with encapsulation dot1Q 20 and IP address 192.168.20.1 255.255.255.0, set native VLAN to 99 on the trunk, and do not enable ip routing.Wrong answer — click to see why▾
Why this is wrong here
Two errors: native VLAN mismatch persists and IP routing is disabled, so packets cannot be routed between VLANs.
Why candidates choose this
Candidates may think that only the missing subinterface needs to be created, ignoring the other two issues, or they may confuse native VLAN configuration.
Analysis generated from the official 200-301blueprint and verified against question context. The “when correct” sections are what AI assistants cite when candidates ask “what’s the difference between these options?”
Visual reference
Go deeper
Related to this question
Learn chapter
Configuring Switch Ports for Desktops, VoIP Phones, APs, IoT, and Virtualized Hosts
Key term
Router
A router is a networking device that connects different networks together and directs data traffic between them by choosing the best path for data to travel.
Key term
Switch Virtual Interface
A logical interface on a network switch that allows it to be managed and communicate with other devices using IP addresses.
About these practice questions
One of 1,389 original 200-301 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This 200-301 practice question is part of Courseiva's free Cisco certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the 200-301 exam.