The port VLAN ID (PVID) is the VLAN to which incoming untagged and priority-tagged frames are classified on a general port.
To configure the PVID of an interface when it is in the general mode, use the switchport general pvid Interface Configuration
(Ethernet, port channel) mode command.
To revert to its default setting, use the no form of this command.
Syntax
switchport general pvid vlan-id
no switchport general pvid
Parameters
vlan-id—The VLAN as the PVID.
Default Configuration
The default VLAN is the PVID.
Command Mode
Interface Configuration (Ethernet, port channel) mode
Examples
Example 1—The following example configures gi2 as a general port and sets its PVID to 234:
switchxxxxxx(config)# interface gi2
switchxxxxxx(config-if)# switchport mode general
switchxxxxxx(config-if)# switchport general pvid 234
Example 2—The following example adds VLAN 2 as tagged, and VLAN 100 as untagged to the general port gi14, defines VID 100
as the PVID, and then reverts to the default PVID (VID=1).
switchxxxxxx(config)# interface gi14
switchxxxxxx(config-if)# switchport mode general
switchxxxxxx(config-if)# switchport general allowed vlan add 2 tagged
switchxxxxxx(config-if)# switchport general allowed vlan add 100 untagged
switchxxxxxx(config-if)# switchport general pvid 100
switchxxxxxx(config-if)# no switchport general pvid
Example 3—The following example configures VLAN on gi14 as untagged on input and untagged on output:
switchxxxxxx(config)# interface gi14
switchxxxxxx(config-if)# switchport mode general
switchxxxxxx(config-if)# switchport general pvid 2
switchxxxxxx(config-if)# switchport general allowed vlan add 2 untagged
Example 4—The following example configures VLAN on gi21 as untagged on input and tagged on output:
switchxxxxxx(config)# interface gi21
switchxxxxxx(config-if)# switchport mode general
switchxxxxxx(config-if)# switchport general pvid 2
switchxxxxxx(config-if)# switchport general allowed vlan add 2 tagged
Example 5—The following example configures VLAN on gi11 as tagged on input and tagged on output:
switchxxxxxx(config)# interface gi11
switchxxxxxx(config-if)# switchport mode general
switchxxxxxx(config-if)# switchport general allowed vlan add 2 tagged
switchxxxxxx(config-if)#
Example 6—The following example configures VLAN on gi23 as tagged on input and untagged on output:
switchxxxxxx(config)# interface gi23
switchxxxxxx(config-if)# switchport mode general
switchxxxxxx(config-if)# switchport general allowed vlan add 2 tagged
switchxxxxxx(config-if)#