3.7. Configuring Voice VLAN

Overview

Function Introduction

With the development of the voice technology, the use of IP Phone/IAD(Integrated Access Device) is becoming more and more widespread in broadband community. Voice and data traffics are usually present in the network at the same time, therfore, voice traffics need higher priority to improve the performance and reduce the packet loss rate.

The traditional method to improve the quality of voice traffic is using ACL to separate the voice packets, and using QoS to ensure the transmit quality.

The voice VLAN feature can identify the voice packets by source mac, which makes the conguration more convenient.

Principle Description

N/A

Configuration

step 1 Enter the configure mode

Switch# configure terminal

step 2 Enter the vlan configure mode and create vlan

Switch(config)# vlan database
Switch(config-vlan)# vlan 2
Switch(config-vlan)# exit

step 3 Set the cos of voice vlan (Optional)

The default cos is 5.

Switch(config)# voice vlan set cos to 7

step 4 Set the voice vlan and create a mac entry for it

Switch(config)# voice vlan 2
Switch(config)# voice vlan mac-address 0055.0000.0000 ffff.ff00.0000 description test

step 5 Enter the interface configure mode and enable voice vlan

Switch(config)# interface eth-0-1
Switch(config-if)# switchport mode trunk
Switch(config-if)# switchport trunk allowed vlan all
Switch(config-if)# voice vlan enable
Switch(config-if)# interface eth-0-2
Switch(config-if)# switchport mode trunk
Switch(config-if)# switchport trunk allowed vlan all

step 6 Validation

Send packet to eth-0-1, the format of the packet is as below (priority in Vlan tag is 0):

0x0000: 0000 0a02 0001 0055 0000 0011 8100 0002 ........k.......
0x0010: 0800 aadd aadd aadd aadd aadd aadd aadd ................
0x0020: aadd aadd aadd aadd aadd aadd aadd aadd ................
0x0030: aadd aadd aadd aadd aadd aadd ............

Receive packet from eth-0-2, the format of the packet received is as below (priority in Vlan tag is 5):

0x0000: 0000 0a02 0001 0055 0000 0011 8100 a002 ........k.......
0x0010: 0800 aadd aadd aadd aadd aadd aadd aadd ................
0x0020: aadd aadd aadd aadd aadd aadd aadd aadd ................
0x0030: aadd aadd aadd aadd aadd aadd ............

Application cases

N/A