Adds the trunk/uplink port to the specified VLAN and removes the
port from the VLANs not on the VLAN list.
A trunk/uplink port transmits all VLAN (1-4094) data by default. You can block some VLAN data by
configuring this command. Use the show interfaces command to display configuration.
The following example removes trunk port GigabitEthernet 0/10 from VLAN 2.
Ruijie(config)# interface gigabitEthernet 0/10
Ruijie(config-if-GigabitEthernet 0/10)# switchport mode trunk
Ruijie(config-if-GigabitEthernet 0/10)# switchport trunk allowed vlan remove
2
The following example removes trunk port GigabitEthernet 0/10 from VLAN 2.
Ruijie(config)# interface gigabitEthernet 0/10
Ruijie(config-if-GigabitEthernet 0/10)# switchport trunk allowed vlan except
10
The following example removes uplink port GigabitEthernet 0/10 from VLAN 10.
Ruijie(config)# interface gigabitEthernet 0/10
Ruijie(config-if-GigabitEthernet 0/10)# switchport mode uplink
Ruijie(config-if-GigabitEthernet 0/10)# switchport trunk allowed vlan remove
10
The following example adds uplink port GigabitEthernet 0/10 to all VLANs except VLAN10.
Ruijie(config)# interface gigabitEthernet 0/10
Ruijie(config-if-GigabitEthernet 0/10)# switchport trunk allowed
vlan except 10