What is the Cisco VLAN Database ?

The VLAN database is used to store vlan data, such as the VLAN ID, name and MTU. The default location of the VLAN database is in the local vlan.dat file, this is stored in non-volatile memory.

Modify VLANDB Location

In order to change the location of where the VLAN information is stored the following command is used,

iosvl2-1(config)#vtp file vlan.dat-new
Setting device to store VLAN database at filename vlan.dat-new.

Creating a VLAN

There are 3 ways that a VLAN can be created.

Interface

The first method is via adding the vlan to a switchport. The VLAN is created, and a default naming standard of VLAN<ID> is used.

iosvl2-1(config-if)#switchport access vlan 33
% Access VLAN does not exist. Creating vlan 33

VLAN Command

The 2nd method is to use the vlan command. This takes you into the configuration prompt for the VLAN. Unlike the previous method this allows you to configure additional attributes for the VLAN, such as configuring the name.

iosvl2-1(config)#vlan 34
iosvl2-1(config-vlan)#name SALES

VLAN Database

Though the final method is depreciated it is still possible to create a VLAN via dropping directly into the VLAN database.

iosvl2-1#vlan database
% Warning: It is recommended to configure VLAN from config mode,
as VLAN database mode is being deprecated. Please consult user
documentation for configuring VTP/VLAN in config mode.
iosvl2-1(vlan)#vlan 35
VLAN 35 added:
Name: VLAN0035

Caveats

There are a few caveats around the VLAN database that are worth mentioning,

  • If a VLAN is configured on a port, once the VLAN is removed from the VLAN database the VLAN will still be assigned to the port. This is known as an orphaned port and will result in traffic for the VLAN no longer transversing the port.
  • Within VTP 1 and 2 extended VLANs are not supported. Extended VLANS are only supported in version 3.
Rick Donato

Want to become a networking expert?

Here is our hand-picked selection of the best courses you can find online:
Cisco CCNA 200-301 Certification Gold Bootcamp
Complete Cyber Security Course – Network Security
Internet Security Deep Dive course
Python Pro Bootcamp
and our recommended certification practice exams:
AlphaPrep Practice Tests - Free Trial