82
Create VLAN (2)
Switch(config)# vlan 2
vlan 2 success
Switch(config)# interface vlan 2
Switch(config-if)#
Note: In CLI configuration, you should create a VLAN
interface first. Then you can start to add/remove ports.
Default status of the created VLAN is unused until you add
member ports to it.
Remove VLAN
Switch(config)# no vlan 2
no vlan success
Note: You can only remove the VLAN when the VLAN is in
unused mode.
VLAN Name
Switch(config)# vlan 2
vlan 2 has exists
Switch(config-vlan)# name v2
Switch(config-vlan)# no name
Note: Use no name to change the name to default name,
VLAN VID.
VLAN description
Switch(config)# interface vlan 2
Switch(config-if)#
Switch(config-if)# description this is the VLAN 2
Switch(config-if)# no description ->Delete the description.
IP address of the VLAN
Switch(config)# interface vlan 2
Switch(config-if)#
Switch(config-if)# ip address 192.168.10.18/24
Switch(config-if)# no ip address 192.168.10.8/24 ->Delete
the IP address
Shut down VLAN
Switch(config)# interface vlan 2
Switch(config-if)# shutdown
Switch(config-if)# no shutdown ->Turn on the VLAN
Display
– VLAN table
Switch# sh vlan
VLAN Name Status Trunk Ports Access Ports
---- ------------ ------- -------------------------- --------------------------
1 VLAN1 Static - fa1-7,gi8-10
2 VLAN2 Unused - -
3 test Static fa4-7,gi8-10 fa1-3,fa7,gi8-10
Display
– VLAN
interface information
Switch# show interface vlan1
Interface vlan1
Description : N/A
Administrative Status : Enable
Operating Status : Up
DHCP Client : Disable
Primary IP Address : 192.168.10.1/24
IPv6 Address : fe80::212:77ff:feff:2222/64
GVRP configuration
GVRP enable/disable
Switch(config)# gvrp mode
disable Disable GVRP feature globally on the switch
enable Enable GVRP feature globally on the switch
Switch(config)# gvrp mode enable