interface fastEthernet 0/1 switchport mode access switchport access vlan 10 no shutdown

Below is a complete blog post tutorial walking through the configuration, verification, and troubleshooting of this essential networking scenario.

Router# show ?

interface gigabitEthernet 1/0/2 switchport trunk encapsulation dot1q switchport mode trunk switchport trunk allowed vlan 10,20

Based on the findings of this paper, we recommend: