VLAN Trunking Protocol (VTP) and how it works

VLAN Trunking Protocol or VTP defines a Layer 2 messaging protocol that let the switches share VLAN configuration information so that the configuration of VLAN remains consistent throughout that network. Cisco switches use its own proprietary VTP to exchange VLAN information between each other.

vtp vlan trunking protocolVTP manages the additions, deletions, and modification such as name changes of VLANs across multiple switches which eventually minimize the time in doing the VLAN configuration, changes of misconfiguration become less such as duplicate VLAN names or incorrect VLAN setting.

For Example, if we want to use VLAN 100 and name it as “Sales”, we can configure that VLAN configuration in one switch, and VTP will distribute that information to the rest all the switches in the network.

Suppose if there are more than 80 switches in a network which are interconnected and if we are not using VTP then we have to configure same VLANs in all the switches. If Vlan trunking protocol has been configured then we don’t need to configure the VLANs in all the 80+ switches, we have to configure the VLANs only in one switch (will be referred as VTP Server) and in rest of the switches VLANs would be learned dynamically.

Understanding the VTP process

Using VTP process, VLANs are being created in a switch which will be referred as VTP server. VLANs which are created or changed are distributed as a broadcast throughout the network.
VTP clients and servers exchanges the VTP messages and update their configuration based on those messages. So VTP allows switched network to expand to large size network by reducing the manual effort which is required for the configuration.

How VTP Works

VTP floods the advertisement packets throughout the VTP domain in every 5 minutes interval, or whenever any change happens or is done in VLAN configuration. This VTP advertisement includes config revision number, VLAN number & VLAN names, and information about which switches have ports assigned to each VLAN.
By configuring the same in one (or more) VTP server and propagating the VLAN information through advertisements, all switches knows the VLANs, their names and VLAN numbers.

VLAN Turning Protocol Standards

There are two VTP or VLAN Trunking Protocol standards used currently in the networks.

1. ISL
2. 802.1Q

ISL or also called as Inter-Switch Link which is cisco propriety protocol and hence can be used only in Cisco switches.
802.1Q also referred as IEEE 802.1Q which is industry standard protocol and can be used in any switch including Cisco.

VTP Modes

VTP operates in one of three modes:
1. Server mode
2. Client mode
3. Transparent mode
In VTP it propagates the information, some switches act as servers & some will act as client.

VTP Server

1. Can create, modify, and delete VLANs and other configuration for entire VTP domain.
2. Will propagated VLAN config to the VTP clients and servers in that same domain.
3. VLAN configurations is saved in NVRAM.

VTP Clients

1. Cannot create, change, or delete VLANs configuration.
2. No VLAN configuration is not stored.
3. No VLAN configuration is saved in NVRAM.

VTP Transparent

1. Can create, modify, and delete VLANs
2. Changes are not transmitted to other switches in the domain but they will effect on only that switch.
3. Ignore the VTP messages but forward VTP advertisements received from other switches.

Prerequisite for configuring VTP

• All the switches should be using same VTP version.
• VTP Domain must be same in all the switches.
• If we have configured authentication in VTP, then it should match as well in all the switches

Advantages of using VTP

1. VLAN Configuration consistency will be there in entire network.
2. New VLAN created & added will be distributed dynamically in the network.
3. Become easier & helpful in segregating the network using multiple VLANs.
4. VLAN Management (adding, deletion or renaming) can be done
5. Tracking &monitoring of VLAN will be accurate
6. Chances of errors will be reduced & configuration will be consistent.

Functional Difference between VTP Modes

Function

Server Mode Client Mode

Transparent Mode

Can create, modify, or delete VLANs within switch

Yes

No

Yes

Forwards VTP advertisements to other switches connected via trunk

Yes

Yes

Yes

Processes received advertisements and synchronizes VLAN config

Yes

Yes

No

Originates VTP advertisements

Yes

No

No

Saves VLAN configuration in NVRAM

Yes

No

Yes

VLAN Trunking Protocol Configuration

 

Core-Switch
Core-Switch#

Core-Switch#config terminal

Enter configuration commands, one per line. End with CNTL/Z.

Core-Switch(config)#vtp domain networkeducator

Changing VTP domain name from NULL to networkeducator

Core-Switch(config)#vtp mode server

Device mode already VTP SERVER.

Core-Switch(config)#

Core-Switch(config)#

Core-Switch#

 

Switch-2
Switch-2#config terminal

Enter configuration commands, one per line. End with CNTL/Z.

Switch-2(config)#vtp mode client

Device mode already VTP CLIENT.

Switch-2(config)#vtp domain networkeducator

Changing VTP domain name from NULL to networkeducator

Switch-2(config)#

Switch-2(config)#

 

Now lets create a VLAN in Core-Switch as VLAN 300 & name it as Accounts

Core-Switch
Core-Switch#config terminal

Enter configuration commands, one per line. End with CNTL/Z.

Core-Switch(config)#vlan 300

Core-Switch(config-vlan)#name Accounts

Core-Switch(config-vlan)#

Core-Switch(config-vlan)#exit

Core-Switch(config)#exit

Core-Switch#

%SYS-5-CONFIG_I: Configured from console by console

Core-Switch#

 

Now lets check whether VLAN 300 has been populated in Switch-2 which we had created in Core-Switch

 

Switch-2
Switch-2#show vlan

VLAN Name Status Ports

—- ——————————– ——— ——————————-

1 default active Fa0/1, Fa0/2, Fa0/3, Fa0/4, Fa0/5, Fa0/6, Fa0/7, Fa0/8, Fa0/9, Fa0/10, Fa0/11, Fa0/12, Fa0/13, Fa0/14, Fa0/15, Fa0/16, Fa0/17, Fa0/18, Fa0/19, Fa0/20, Fa0/21, Fa0/22

100 Sales active

200 Finance active

300 Accounts

1002 fddi-default act/unsup

1003 token-ring-default act/unsup

1004 fddinet-default act/unsup

1005 trnet-default act/unsup

..

——- ——— —————– ——————————————

Switch-2#

Frequently Asked Questions

Q: Why we use VTP Transparent mode ?

A. When we need to distribute the administrative control of the switches in network we uses VTP transport mode.

Q: What is the default mode of VTP in Cisco Switch ?

A: By default, Server Mode will be configured in Cisco Switch.

Q. Is configuring the VTP domain necessary ?

A. VTP domain is optional but it is recommended to use VTP domain.

Q: Can we configure VTP if one Switch is Cisco & other Switch is HP ?

A: Yes we can but in both we have to use 802.1Q standard which is industry standard.

Q: When connecting the new Cisco Switch in network which mode should we use ?

A: Whenever we are configuring new Switch for installation in the existing network we should first decide which switch will act as Server & if we have plan to do it later or we simply want to extend the network, please ensure it should be in transparent mode.

What are your comments about this article ?

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.