September 17, 2024
Configure VLANs

VLANs are in every network environment. Whether you’re configuring end-to-end or local VLANs you are segmenting the network into logical groups.

Prior to getting into the configuration of a VLAN, there are some best practices to be aware of:

  • Avoid using VLAN 1. Put unused ports on an unused VLAN. I like to use VLAN 999.
  • Separate voice and data VLANs.
  • Place management on its own VLAN.
  • Configure non-trunk links as access ports.
  • Use SSH instead of Telnet.

To configure a VLAN, start in global config mode:

SW01#conf t

Create a VLAN with a VLAN ID number:

SW01(config)#vlan 10

Give the VLAN a name:

SW01(config-vlan)#name Users
SW01(config-vlan)#exit

Assign a switchport to the new VLAN:

SW01(config)#interface g0/5
SW01(config-if)#switchport access vlan 10
SW01(config-if)#end

switchport access vlan 10 changes the default VLAN membership of this port to VLAN 10.

Verify the new VLAN configuration:

SW01#show vlan

About Author