What is VTP – VLAN Trunking Protocol
VTP (VLAN Trunking Protocol) is a Cisco proprietary protocol used by Cisco switches to synchronize VLAN information across a network. With VTP, network managers can handle VLANs on a single switch and reflect those changes on all other switches in the same VTP domain. VTP uses trunk links to send and receive VTP messages containing information such as VTP version, domain name, configuration revision number, and VLAN ID and name. The VLAN configurations of all switches belonging to the same VTP domain are made available to one another. VTP can reduce the complexity and errors of VLAN configuration in large networks.
Before APIs were available on Cisco platforms, configuring a network switch was a manual process. So, the VTP – VLAN trunking protocol was a blessing to network engineers as it reduces the administration in a switched network.
Suppose you are working in a large enterprise switched network using hundreds of switches. For each type of traffic, you will need separate VLANs. Now, these VLANs need to be created on all switches, which is a time-consuming task for the network admins.
So, to reduce the burden of provisioning VLANs on switches, CISCO came up with this solution: VTP – VLAN Trunking Protocol.
What is VTP (VLAN trunking protocol) in Networking?
VTP (VLAN trunking protocol) is a Layer 2 messaging protocol that maintains VLAN configuration consistency by managing the addition, deletion, and renaming of VLANs within a VTP domain.
It is used to store and exchange the VLAN information with multiple switches throughout the network. We can modify the whole network from a single switch (server mode rather than going on every switch to apply or execute the configurations.
How VTP works?
VTP works by sending VTP messages over trunk links to other switches in the same VTP domain. VTP messages can be of different types, such as summary advertisements, subset advertisements, advertisement requests, and join messages. Each VTP message contains a configuration revision number. When a switch receives a VTP message with a higher revision number than its own, it updates its VLAN database accordingly.
Let’s understand with the help of an example.
Suppose there are three switches, A, B, and C, in the same VTP domain. Switch A is configured as a VTP server and has VLAN 10 and VLAN 20 configured. Switch B and C are configured as VTP clients and have no VLANs configured.
When switch A sends a summary advertisement with a revision number of 1, switch B and C receive it and compare it with their own revision number, which is 0. Since 1 is higher than 0, switches B and C update their VLAN database with VLAN 10 and VLAN 20 from switch A. They also increment their revision number to 1.
If switch A adds another VLAN, say VLAN 30, it sends another summary advertisement with a revision number of 2. Switch B and C receive it and update their VLAN database again with VLAN 30 from switch A. They also increment their revision number to 2.
There have been 3 VTP versions to date, and these are:
VTP Version 1
- It supports the standard 1-1005 VLAN range.
- VTP v1 is the default version on cisco switches.
VTP Version 2
- Version 2 provides additional features like token ring support and a VLAN consistency check.
- VTP version 1 and version 2 are not compatible with each other.
VTP Version 3
- It is the most flexible version of all.
- It was built to forward VLAN and other database information such as MSTP.
- It supports the extended VLAN range, which is 1006-4094.
- VTP Versions 1 and 2 are limited to VLANs from 1 to 1005.
- The version 3 of VTP allows the full range of VLANs 1 to 4094.
Modes in VTP
- It is the default mode on all CISCO Switches
- Here we can create, modify or delete VLANs
- It Syncs the VLAN information with other client switches
- Sends and forwards the advertisements
- Not allowed to create, delete or modify the VLANs
- These clients switch only receive the advertisements from server switches and sync the database with the server switch according to (Configuration Revision)
- A switch with VTP transparent mode doesn’t participate in the VTP domain.
- It doesn’t send or receive the VLAN database from VTP server switches, but it can pass the VLAN traffic to other switches connected to it via trunk links.
- VLANs can be created, deleted, and modified in this mode, but the VLAN database of this switch is not shared with any other switch in the network.
What are the components of VTP in networking?
VTP has three main components: VTP domain, VTP pruning, and VTP advertisements. Let’s understand all three components in detail.
The VTP domain limits the extent of configuration changes throughout the network in the event of an error. A switch belongs to a singular VTP domain at any given moment. Establishing or changing VLANs in a VTP server mode is impossible until the VTP domain name has been provided. This particular component comprises one or more interconnected switches.
Also known as VTP messages. It comprises VLAN information and is delivered to other switches by VTP servers periodically. It is distributed so that all of a VTP domain’s VLAN configuration is in sync with one another. VTP uses a multicast address for advertising its updates across the trunk links to all the switches in the VTP domain.
Multicast Address 01-00-0C-CC-CC-CC
Three types of VTP Advertisements are their –
- Summary advertisement
- Sent out every 300 seconds
- It also includes the VTP version of the domain, the revision number for the configuration and date stamp.
- Subset Advertisement
- Sent out when there is a change in the VLAN database
- Client request
- This happens when a switch with a low revision number joins the VTP domain and observes a summary advertisement with a higher revision than stored locally in the VTP domain.
VTP advertisements consist of,
- VLAN ID
- VTP Domain Name
- VTP Password
- VTP configuration revision number
- VLAN configuration
Conditions to configure VTP
- Trunking should be done; else, traffic will not be forwarded to client switches.
- The same VTP domain and password should be there on all switches which are part of VTP
- VTP Version must match on all the devices
VTP pruning reduces unnecessary broadcast traffic on trunk links by pruning VLANs that are not needed on a switch. VTP pruning can improve network performance and bandwidth utilization.
- VTP pruning eliminates the unnecessary broadcast or multicast traffic throughout the network.
- VLAN 1 cannot be pruned because it’s the default VLAN
- Pruning is by default disabled on switches
VTP Configuration Revision Number
- VTP switches use an INDEX number known as a configuration revision number to keep track of the most recent information in the VTP Domain.
- The advertisement always starts with the configuration revision number that is 0 (Zero)
- When subsequent changes are made on a VTP server, the revision number is incremented before the advertisement is forwarded to the next switch.
Note: – Before adding a switch to the existing VTP Domain, ensure the new switch has VTP revision (0) because as long as the revision number is higher, the switch will accept the update from that switch which is having higher revision number.
Advantages of VTP (VLAN Trunking Protocol)
VTP has many advantages, some of these are:
- It simplifies VLAN management by allowing you to automatically create, delete, and rename VLANs on one switch and propagate the changes to other switches.
- It reduces network traffic by enabling VTP pruning, which prevents unnecessary broadcast information from being sent over trunk links.
- It maintains consistency and avoids configuration errors by using a configuration revision number to track the most recent updates.
- It enables precise tracking and monitoring of VLANs for ease of use.
- Streamlines the process of managing the VLAN database across numerous switches.
Join our CCNA training for complete notes of the VTP. For more information, go to the CCNA training page. Meanwhile, you can explore deeper depth to VTP in this video with our trainer Mr Abhijit Bakale.
Frequently Asked Questions
Q1 – What is VTP used for?
VTP is a CISCO proprietary protocol that is used to ensure consistency across the network. It is also used to synchronize the VLAN information within the VTP domain. It lets network administrators modify, remove and add VLANs which are then transmitted to other switches within the VTP domain.
Q2 – What is VTP and STP?
VTP stands for VLAN trunking protocol, whereas STP stands for Spanning Tree Protocol. VTP is the Cisco intellectual protocol used to transmit VLAN on the whole local area network. STP is a layer-2 network protocol, and it is used to prevent looping in a network topology.
Q3 – What is VTP mode?
There are 3 VTP modes: Server, Client, and Transparent. Server mode is the default mode for Cisco switches allowing for creating, adding, and removing VLANs. In the client mode, the clients switch only receives the advertisements from server switches. In contrast, in the transparent mode, the switch doesn’t send or receive the VLAN database from VTP server switches, but it can pass the VLAN traffic to other switches connected to it via trunk links.
Q4 – What are the three modes of VTP?
The three modes of VTP are:
- Server mode – Switch in this mode can delete or add VLANs on its own.
- Client mode – A switch in this mode is not able to change its VLAN configuration.
- Transparent mode – A switch in this mode can send VTP advertisements but can’t share its VLAN database.
In this blog, we have covered everything related to VLAN Trunking Protocol (VTO), such as the working of VTP, its components, and the benefits associated with VTP. The VTP Protocol is regarded as the core of VLANs in large-scale networks since it totally simplifies and transparently manages every switch on your network.