Configuring VoIP Support on a Switch

Configuring VoIP Support on a Switch
Manual Configuration
To associate a voice VLAN with a switch port, use the following:
Switch(config-if)#switchport voice vlan vlan-ID
To configure an IOS switch to trust the markings on traffic entering an
interface, use the following:
Switch(config-if)#mls qos trust {dscp | cos}
To configure the switch to trust the traffic markings only if a Cisco phone is
connected, use the following:
Switch(config-if)#mls qos trust device cisco-phone
To set a COS value for frames coming from a PC attached to the phone, use
the following:
Switch(config-if)#switchport priority extend cos cos-value
To verify the interface parameters, use the following:
Switch(config-if)#show interfaces interface switchport
To verify the QoS parameters on an interface, use the following:
Switch(config-if)#show mls qos interface interface
Using AutoQoS
When AutoQoS is enabled, the switch configures its interfaces based on a
best-practices template. AutoQoS has the following benefits:
■ Automatic discovery and classification of network applications.
■ Creates QoS policies for those applications.
■ Configures the switch to support Cisco IP phones as well as network
applications. Manual configuration can be done afterward, also.
■ Sets up SNMP traps for network reporting.
■ Configures consistently across your network when used on all routers
and switches.
CDP must be enabled for AutoQoS to function properly with Cisco IP phones.
AutoQoS commands for switches running the Catalyst OS are listed in Table 7-2.
Table 7-2 AutoQoS Commands for Catalyst OS
Command Description
set qos autoqos Globally enables AutoQoS on the switch.
set port qos mod/port Configures the port to trust either the COS
autoqos trust [cos|dscp] or DSCP markings of all traffic coming in
the port.
set port qos mod/port autoqos Configures the port to trust traffic markings
voip [ciscosoftphone | only if a Cisco phone or a computer with a
ciscoipphone] [trust] Cisco softphone is connected to the port.
Requires that CDP be enabled.
AutoQoS commands for switches running Native IOS are shown in Table 7-3.
Table 7-3 AutoQoS Commands for IOS
Command Description
(config-if)#auto qos voip trust Configures the port to trust the COS on all
traffic entering the port.
(config-if)#auto qos voip Configures the port to trust traffic markings
cisco-phone only if a Cisco phone is connected to the
port. Requires that CDP be enabled.
#show auto qos Shows the AutoQoS configuration. Does
[interface interface] not show any manual QoS configuration—
use show run to see that.