Creating A VLAN Command Meaning vlan

Creating A VLAN
Command Meaning
vlan
Creates or allows the modification of a VLAN in the VLAN
database
name
Configures a name for a given VLAN from the VLAN
configuration mode
Here is how you simply create VLANs on a switch:
S1#
config t
S1(config)#
vlan ?
WORD ISL VLAN IDs 1-4094
internal internal VLAN
S1(config)#
vlan 2
S1(config-vlan)#
name Sales
S1(config-vlan)#
vlan 3
S1(config-vlan)#
name Marketing
S1(config-vlan)#
vlan 4
S1(config-vlan)#
name Accounting
S1(config-vlan)#
^Z
S1#
From the previous output, you can see that you can create VLANs from 2-4094. This is
only mostly true. Like I said, VLANs can really be created only up to 1005, and you can’t use,
change, rename, or delete VLANs 1 and 1002 through 1005 because they’re reserved. The previous
VLAN numbers are called
extended
VLANs and won’t be saved in the database unless
your switch is set to VTP Transparent mode. You won’t see these VLAN numbers used too
often in production. Here’s an example of setting my S1 switch to VLAN 4000 when my
switch is set to VTP Server mode (the default VTP mode):
S1#
config t
S1(config)#
vlan 4000
S1(config-vlan)#
^Z
% Failed to create VLANs 4000
Extended VLAN(s) not allowed in current VTP mode.
%Failed to commit extended VLAN(s) changes.