24
Default command level
2: System level
Parameters
vlan-id1
,
vlan-id2
: Specifies a VLAN ID in the range of 1 to 4094.
vlan-id1
to
vlan-id2
: Specifies a VLAN range.
vlan
-
id2
must be no smaller than
vlan
-
id1
.
all
: Creates or removes all VLANs except reserved VLANs. The keyword is not supported when the
maximum number of VLANs that can be created on a router is less than 4094.
The following matrix shows the
all
keyword and hardware compatibility:
Hardware Keyword
compatibility
MSR800 No
MSR 900
No
MSR900-E No
MSR 930
No
MSR 20-1X
No
MSR 20
No
MSR 30
Yes
MSR 50
Yes
MSR 2600
Yes
MSR3600-51F Yes
Usage guidelines
You cannot create or remove the default VLAN (VLAN 1).
You cannot create or remove VLANs reserved for specific functions.
To remove the following VLANs, remove the related configurations first, because you cannot use the
undo vlan
command to directly remove them:
•
Protocol reserved VLANs
•
Voice VLANs
•
Management VLANs
•
Dynamic VLANs
Examples
# Create VLAN 2, and enter VLAN 2 view.
<Sysname> system-view
[Sysname] vlan 2
[Sysname-vlan2]
# Create VLAN 4 through VLAN 100.
<Sysname> system-view
[Sysname] vlan 4 to 100
Please wait............. Done.
Related commands
display vlan