Configuring a LAN Interface as an Ethernet Access Port vlan

This example shows how to set Ethernet 1/10 as an Ethernet access port that carries traffic for VLAN 5 only:

switch# configure terminal
switch(config)# interface ethernet 1/10
switch(config-if)# switchport mode access
switch(config-if)# switchport access vlan 5
switch(config-if)# end
switch# wr