VLAN technologies

1.1.c i Access ports

Access Ports can be configured in two ways:

“Access Ports” CLI configuration commands:

## Configuring an interface for access mode and set its VLAN ID
Switch(config-if)# switchport mode access
Switch(config-if)# switchport access vlan <vlan-id>

“Access Ports” CLI show commands:

## Showing all VLANs and their associated ports in detail
Switch# show vlan

## Showing all VLANs and their associated ports in brief
Switch# show vlan brief

## Showing a specific VLAN and its associated ports
Switch# show vlan id <vlan-id>

1.1.c ii Trunk ports (802.1Q)

General information on “Trunk ports (802.1Q)":

The 802.1q tag consists of the following fields:

“Trunk ports (802.1Q)” CLI configuration commands:

## Configuring an interface for trunk mode
## Important: The encapsulation command is only needed on older platforms where ISL is still configurable!
Switch(config-if)# switchport trunk encapsulation dot1q
Switch(config-if)# switchport mode trunk

“Trunk ports (802.1Q)” CLI show commands:

## Showing all trunk interfaces inlcuding detailed information
Switch# show interfaces trunk

1.1.c DTP (not on blueprint)

General information on “DTP”:

“DTP” timers default values:

“DTP” modes:

“DTP” port configuration combination results:

Dynamic Desirable Dynamic Auto Trunk Access
Dynamic Desirable Trunk Trunk Trunk Access
Dynamic Auto Trunk Access Trunk Access
Trunk Trunk Trunk Trunk Limited connectivity
Access Access Access Limited connectivity Access

“DTP” CLI configuration commands:

## Configuring DTP on an interface for active trunking (dynamic desirable)
Switch(config-if)# switchport mode dynamic desirable

## Configuring DTP on an interface for passive trunking (dynamic auto)
Switch(config-if)# switchport mode dynamic auto

## Configuring an interface for static trunk mode
Switch(config-if)# switchport mode trunk

## Configuring an interface for static access mode
Switch(config-if)# switchport mode access

## Disable DTP on an interface completely
Switch(config-if)# switchport nonegotiate

1.1.c iii Native VLAN

General Information on “Native VLAN”:

“Native VLAN” CLI configuration commands:

## Modifying the native VLAN of a trunk interface
Switch(config-if)# switchport trunk native vlan <vlan-id>

## Configuring tagging for the native VLAN
Switch(config)# vlan dot1q tag native

1.1.c iv Manual VLAN pruning

General information on “Manual VLAN pruning”:

“Manual VLAN pruning” CLI configuration commands:

## Allowing only specific VLANs on a trunk interface
Switch(config-if)# switchport trunk allowed vlan <vlan-ids>

## Adding VLANs to the list of allowed VLANs on a trunk interface
Switch(config-if)# switchport trunk allowed vlan add <vlan-ids>

## Removing VLANs from the list of allowed VLANs on a trunk interface
Switch(config-if)# switchport trunk allowed vlan remove <vlan-ids>

## Allowing all VLANs except specific ones on a trunk interfaces
Switch(config-if)# switchport trunk allowed vlan except <vlan-ids>

## Allowing all VLANs on a trunk interfaces
Switch(config-if)# switchport trunk allowed vlan all

## Allowing no VLANs on a trunk interfaces
Switch(config-if)# switchport trunk allowed vlan none

“Manual VLAN pruning” CLI show commands:

## Showing all trunk interfaces inlcuding detailed information
Switch# show interfaces trunk

1.1.c v VLAN database

Normal Range (1 - 1001):

Extended Range (1006 - 4094):

1.1.c vi Normal range and extended range VLANs

VLAN ranges:

VLAN states:

Cisco best practice:

“Normal range and extended range VLANs” CLI configuration commands:

## Configuring a new VLAN
Switch(config)# vlan <vlan-id>
Switch(config-vlan)# name <vlan-name>

## Activating/Suspending a VLAN
Switch(config)# vlan <vlan-id>
Switch(config-vlan)# state [active | suspend]

## Shutting down a VLAN
Switch(config)# vlan <vlan-id>
Switch(config-vlan)# shutdown

“Normal range and extended range VLANs” CLI show commands:

## Showing all VLANs and their associated ports in detail
Switch# show vlan

## Showing all VLANs and their associated ports in brief
Switch# show vlan brief

## Showing a specific VLAN and its associated ports
Switch# show vlan id <vlan-id>

1.1.c vii Voice VLAN

Benefits of using a dedicated “voice VLAN”:

“Voice VLAN” configuration types:

“Voice VLAN” configuration specialties:

“Voice VLAN default” CLI configuration/show commands:

## Configuring a dedicated Voice VLAN on a port
Switch(config-if)# switchport voice vlan <vlan-id>

## Showing output of a dedicated Voice VLAN port (example uses Voice VLAN 20)
Switch# show interface <if> switchport

[...]
Access Mode VLAN: 10 (10-data)
Trunking Native Mode VLAN: 1 (default)
Administrative Native VLAN tagging: enabled
Voice VLAN: 20 (20-voice)
[...]

“Voice VLAN dot1p” CLI configuration/show commands:

## Configuring dot1p Voice VLAN on a port
Switch(config-if)# switchport voice vlan dot1p

## Showing output of a dot1p Voice VLAN port
Switch# show interface <if> switchport

[...]
Access Mode VLAN: 10 (10-data)
Trunking Native Mode VLAN: 1 (default)
Administrative Native VLAN tagging: enabled
Voice VLAN: dot1p
[...]

“Voice VLAN untagged” CLI configuration/show commands:

## Configuring an untagged Voice VLAN on a port
Switch(config-if)# switchport voice vlan untagged

## Showing output of an untagged Voice VLAN port
Switch# show interface <if> switchport

[...]
Access Mode VLAN: 10 (10-data)
Trunking Native Mode VLAN: 1 (default)
Administrative Native VLAN tagging: enabled
Voice VLAN: untagged
[...]

1.1.c Internal VLAN (not on blueprint)

General Information on “Internal VLAN”:

“Internal VLAN” CLI configuration commands:

## Modifying the internal VLAN allocation policy
Switch(config)# vlan internal allocation policy [ascending | descending]

“Internal VLAN” CLI show commands:

## Showing current internal VLAN allocation policy
Switch# show vlan internal usage

1.1.c viii VTP

VLAN Trunking Protocol

Reasons to use “VTP”:

Default settings for “VTP”:

“VTP” Modes:

Reset “VTP” revision:

“VTP” message types:

“VTP” configuration considerations:

“VTP” and VLAN ranges:

“VTP” version feature overview:

Version 1 Version 2 Version 3
VLAN Range Normal Normal Normal + Extended
Private VLAN Support No No Yes
Modes
  • yes, only normal range
  • must only be enabled on the server
  • yes, only normal range
  • must only be enabled on the server
  • yes, only normal range
  • must only be enabled on the server
Additional features -
  • Support for Token Ring
  • Consistency check
  • Transparent mode without domain and consistency check
  • Backwards compatible to v2 on a per-link basis
  • Able to propagate MST database information
  • VTP primary (only 1 allowed per role and the only one who can make changes) and secondary servers
  • Ability to turn off VTP per port
  • Support for PVLANs
  • Support for RSPAN VLANs

“VTP” problem (“superior-revision-wipeout-issue”):

“VTP” v3:

“VTP” pruning:

“VTP” CLI configuration commands:

## =================
## VTP CONFIGURATION
## =================

## Configuring the VTP mode
Switch(config)# vtp mode <vtp-mode>

## Configuring the VTP domain
Switch(config)# vtp domain <vtp-domain>

## Configuring the VTP password
Switch(config)# vtp password <vtp-password>

## Configuring the VTP version
Switch(config)# vtp version <vtp-version>

## Disabling/Enabling VTP pruning
Switch(config)# [no] vtp pruning


## ===========================
## VTP CONFIGURATION (V3 ONLY)
## ===========================

## Configuring the VTP password (hidden mode)
Switch(config)# vtp password <vtp-password> hidden

## Configuring the VTP password (secret mode)
Switch(config)# vtp password <vtp-password> secret


## ===========
## VTP PRUNING
## ===========

## Only allowing specific VLANs to-be-pruned on a trunk interface
Switch(config-if)# switchport trunk pruning vlan <vlan-ids>

## Adding VLANs to the list of to-be-pruned VLANs on a trunk interface
Switch(config-if)# switchport trunk pruning vlan add <vlan-ids>

## Removing VLANs from the list of to-be-pruned VLANs on a trunk interface
Switch(config-if)# switchport trunk pruning vlan remove <vlan-ids>

## Allowing all VLANs except specific ones to-be-pruned on a trunk interfaces
Switch(config-if)# switchport trunk pruning vlan except <vlan-ids>

## Allowing no VLANs to-be-pruned on a trunk interfaces
Switch(config-if)# switchport trunk pruning vlan none

“VTP” CLI show commands:

## Showing configured VTP parameters
Switch# show vtp status


## ==========
## VTPv3 only
## ==========

## Making this device the primary VTP server for VLANs
Switch# vtp primary

## Making this device the primary VTP server for VLANs (same outcome as command above)
Switch# vtp primary vlan

## Making this device the primary VTP server for MST
Switch# vtp primary mst