2-459
Catalyst4500 Series SwitchCiscoIOS Command Reference—Release 12.2(18)EW
78-16201-01
Chapter2Cisco IOS Commands for the Catalyst 4500 Series Switches
switchport access vlan
switchport access vlan
To set the VLAN when an interface is in access mode, use the switchport access vlan command. To
reset the access mode VLAN to the appropriate default VLAN for the device, use the no form of this
command.
switchport access [vlan {vlan-id | dynamic}]
no switchport access vlan
Syntax Description
Defaults The default settings are as follows:
• Access VLAN and trunk interface native VLAN are default VLANs corresponding to the platform
or interface hardware.
• All VLAN lists include all VLANs.
Command Modes Interface configuration
Command History
Usage Guidelines You must enter the switchport command without any keywords to configure the LAN interface as a
Layer 2 interface before you can enter the switchport access vlan command. This action is required only
if you have not already entered the switchport command for the interface.
Entering the no switchport command shuts the port down and then reenables it, which could generate
messages on the device to which the port is connected.
The no form of the switchport access vlan command resets the access mode VLAN to the appropriate
default VLAN for the device.
If your system is configured with a Supervisor Engine 1, valid values for vlan-id are from 1 to 1005. If
your system is configured with a Supervisor Engine 2, valid values for vlan-id are from 1 to 4094.
Extended-range VLANs are not supported on systems configured with a Supervisor Engine 1.
Examples This example shows how to cause the port interface to cease operating as a Cisco-routed port and convert
to a Layer 2-switched interface:
Switch(config-if)# switchport
Switch(config-if)#
vlan-id (Optional) Number of the VLAN on the interface in access mode; valid values are from
1 to 4094.
dynamic (Optional) Enables VMPS control of the VLAN.
Release Modification
12.1(12c)EW Support for this command was introduced on the Catalyst 4500 series switch.
12.1(13)EW Support for VPMS was added.