8 switchport access vlan, 9 switchport trunk allowed vlan – PLANET WGSD-1022 User Manual

Page 321

Advertising
background image

5.27.8 switchport access vlan

The switchport access vlan interface configuration command configures the VLAN ID when the

interface is in access mode. To reconfigure the default, use the no form of this command.

Syntax

switchport access vlan vlan-id

no switchport access vlan

ƒ vlan-id — VLAN ID of the VLAN to which the port is configured.

Default Configuration

VLAN ID=1

Command Mode

Interface configuration (Ethernet, port-channel) mode

User Guidelines

The command automatically removes the port from the previous VLAN, and adds it to the new VLAN.

Example

The following example configures a VLAN ID of 23 to the untagged layer 2 VLAN interface number e8.

Console (config)# interface ethernet e8

Console (config-if)# switchport access vlan 23

5.27.9 switchport trunk allowed vlan

The switchport trunk allowed vlan interface configuration command adds or removes VLANs from a

trunk port.

Syntax

switchport trunk allowed vlan {add vlan-list | remove vlan-list}

ƒ add vlan-list — List of VLAN IDs to add. Separate non consecutive VLAN IDs with a comma and

no spaces. A hyphen designates a range of IDs.

ƒ remove vlan-list — List of VLAN IDs to remove. Separate non consecutive VLAN IDs with a

comma and no spaces. A hyphen designate a range of IDs.

Default Configuration

This command has no default configuration.

Advertising