How to Setup VLAN Trunking Protocol (VTP) on Cisco Switches?

Unlock Best Pricing with In-stock, Ready-to-Ship Products

If you have more than a couple of switches, configuring VLAN’s can be a real pain. To make it easier, Cisco developed VLAN Trunking Protocol (VTP). Now, let’s find out what VTP can do for you.

If you have 20 switches in your large office building, on each of these switches, you have four VLAN’s. Without VTP, you have to create each of these four VLANs on each of these switches. With VTP, you only have to create the four VLANs once, on one switch, and all other switches learn about the four VLANs. In other words, the job of VTP is to distribute VLAN configuration information between all the switches.How to Setup VLAN Trunking Protocol (VTP) on Cisco Switches

How does VTP Work?

The job of VTP is best explained from the perspective of the VTP server. All switches, by default, are VTP servers. The VTP server is where you would create, remove, or modify VLANs.

This VTP server sends an advertisement, across the domain, every 5 minutes or whenever a change is made in the VLAN database. And the advertisement contains all the different VLAN names, VLAN numbers, what switches have ports in what VLANs and a revision number. Whenever a switch receives an update with a larger revision number than the last one it applied, it applies that revision.

Keep in mind that VTP is a Cisco proprietary protocol. So, to use VTP between your switches, you must have all Cisco switches.

VTP Modes

VTP switches can be in three different modes. Those modes are:

  • Server – the default where all VLAN adds, changes, and removals are allowed
  • Client – where no changes can be made, only new revisions can be received from the VTP server switches.
  • Transparent – where local VLAN information can be changed but that information is not sent out to other switches. Transparent switches also do not apply VTP advertisements from other switches but they do forward those advertisements on.

Usually, you would want a few of your core switches to be servers and all remaining remote or access layer switches to be clients. You would only make changes on the server switches and those changes would be propagated to the client switches.

What about Pruning?

VTP pruning is the process of not sending IP broadcast traffic for certain VLANs to switches that do not have any ports in that VLAN. The switches that choose not to send these broadcasts know that they cannot do this because of VTP. With VTP telling them what ports the other switches have, this switch knows that they don’t have to send them broadcast packets, because they know that the other switches don’t need them.

Pruning saves LAN bandwidth because broadcasts don’t have to be sent to switches that don’t need them.

How to Configure VTP?

To configure VTP, you use the vtp global configuration mode command. With this command you can specify the following:

  • VTP domain – the name of the VTP domain. All switches communicating with VTP in the same domain must have the same VTP domain name.
  • VTP mode – either server, client, or transparent
  • VTP password – a password to control who can and cannot receive VTP information
  • VTP pruning – VTP pruning is either turned on or off

Here is a sample configuration:

How to Setup VLAN Trunking Protocol (VTP) on Cisco Switches-02

To see what is going on with VTP, you can use show VTP status, like this:

How to Setup VLAN Trunking Protocol (VTP) on Cisco Switches-01

To sum up,

  • VTP is used to distribute VLAN configuration information between switches
  • VTP is Cisco proprietary and can only be used on Cisco switches.
  • By using VTP, you can also prune your VLANs, saving bandwidth
  • The command to configure VTP is the global configuration mode command, VTP
  • The command to check status is the privileged mode command, show VTP status

 

More Related Cisco Switch Tutorials:

LAN and Setup VLAN on a Cisco Switch

Demo: How to Configure InterVLAN Routing On Layer 3 Switches?

Switch Types and LAN Switching

Simple Steps to Create a Non-Routed VLAN on Cisco Switch

How to Create and Delete VLAN on Cisco Catalyst Switch?

Share This Post

Post Comment