175
Before you configure parameters for a VLAN interface, use this command to shut it down to prevent
the configuration from affecting the network. After you complete the VLAN interface configuration,
use the undo shutdown command to make the settings take effect.
To troubleshoot a failed interface, you can use the shutdown command and then the undo
shutdown command on the interface to see whether it recovers.
In a VLAN, the state of any Ethernet port is independent of the state of the VLAN interface.
Examples
# Shut down VLAN-interface 2, and then bring it up.
<Sysname> system-view
[Sysname] interface vlan-interface 2
[Sysname-Vlan-interface2] shutdown
[Sysname-Vlan-interface2] undo shutdown
vlan
Use vlan vlan-id to create a VLAN and enter its view or to enter the view of an existing VLAN.
Use vlan vlan-id1 to vlan-id2 to create VLANs vlan-id1 through vlan-id2, except reserved VLANs.
Use vlan all to create VLANs 1 through 4094.
Use undo vlan to delete the specified VLANs.
Syntax
vlan { vlan-id1 [ to vlan-id2 ] | all }
undo vlan { vlan-id1 [ to vlan-id2 ] | all }
Default
VLAN 1 (system default VLAN) exists.
Views
System view
Predefined user roles
network-admin
Parameters
vlan-id1, vlan-id2: Specifies a VLAN ID. The value range is 1 to 4094.
vlan-id1 to vlan-id2: Specifies a VLAN range. The vlan-id1 and vlan-id2 arguments specify VLAN IDs.
The value range for each of the two arguments is 1 to 4094. The value for the vlan-id2 argument
must be equal to or greater than the value for the vlan-id1 argument.
all: Creates or deletes all VLANs except reserved VLANs.
Usage guidelines
You cannot create or delete the system default VLAN (VLAN 1).
You cannot create or delete reserved VLANs.
Before you delete a dynamic VLAN, a VLAN with a QoS policy applied, or a VLAN locked by an
application, you must first remove the configuration from the VLAN.
Examples
# Create VLAN 2 and enter its view.
<Sysname> system-view
[Sysname] vlan 2