Timedora

2 VLAN Configuration

Learn how to create VLANs on Cisco switches, assign end-device ports, verify the configuration, and troubleshoot common connectivity problems.

VLANs and access ports

A (virtual LAN) is a logical Layer 2 network. It groups switch ports into separate broadcast domains, even when the ports are on the same physical switch.

An normally connects an end device and belongs to one . Ethernet frames on the access-port link are sent untagged.

Create and make a available

On Cisco IOS and IOS XE switches, create a from global configuration mode. You can optionally give it a descriptive name:

Creating a defines it on the switch, but does not automatically assign any ports to it. The must also be available on the switch. In some environments, information is managed or propagated through . If the does not appear, check the platform and configuration.

Assign access ports

Set an end-device port to access mode, then assign it to the intended . This example assigns two user-facing ports to 20:

An belongs to one access at a time. Devices connected to access ports in the same can communicate at Layer 2 through the switch, subject to other controls. Devices in different VLANs belong to different broadcast domains, so communication between them requires .

Assigning a does not configure a device’s IP address, subnet, or default gateway.

Verify and port settings

Verify both that the exists and that the intended port is assigned to it. Use more than one command:

show brief lists VLANs and, on typical access-port displays, their member ports. show interfaces ... switchport reports the port’s administrative mode and access . The interface’s running configuration confirms which commands were applied.

Command output and supported syntax can vary by switch model and software release.

Troubleshoot common errors

When an end device cannot connect as expected, check the configuration and the endpoint in a deliberate order:

  • Wrong port: Confirm the interface identifier. Assigning the correct to a different port will not help the connected device.

  • Wrong ID: Check the value in switchport access against the intended , and verify that with show brief.

  • Port not in access mode: Explicitly configure switchport mode access for an end-device port rather than relying on defaults or dynamic negotiation.

  • unavailable: creation and propagation behavior varies by platform and setup. Verify that the appears and is active on the switch; create it explicitly where required by the platform or workflow.

  • Link or endpoint issue: Check that the port is up and that the endpoint’s IP settings match the ’s subnet. membership does not supply IP configuration or inter- routing.

The basic configuration sequence is to create the , place end-device ports in access mode, and assign each port to its intended . Verify the and port separately with show brief and show interfaces ... switchport. If connectivity still fails, check the physical link and endpoint IP settings, then confirm that routing is configured when communication across VLANs is required.