CHAPT ER
14-1
Catalyst 3750-X and 3560-X Switch Software Configuration Guide
OL-21521-01
14
Configuring Auto Smartports Macros
This chapter describes how to configure and apply Auto Smartports and static Smartports macros on the
Catalyst 3750-X or 3560-X switch.
Note For complete syntax and usage information for the commands used in this chapter, see the command
reference for this release.
Understanding Auto Smartports and Static Smartports Macros, page 14-1
Configuring Auto Smartports, page 14-3
Configuring Static Smartports Macros, page 14-17
Displaying Auto Smartports and Static Smartports Macros, page 14-20

Understanding Auto Smartports and Static Smartports Macros

Auto Smartports macros dynamically configure ports based on the device type detected on the port.
When the switch detects a new device on a port it applies the appropriate Auto Smartports macro on the
port. When there is a link-down event on the port, the switch removes the macro. For example, when you
connect a Cisco IP phone to a port, Auto Smartports automatically applies the IP phone macro. The IP
phone macro enables quality of service (QoS), security features, and a dedicated voice VLAN to ensure
proper treatment of delay-sensitive voice traffic. Auto Smartports uses event triggers to map devices to
macros.
The Auto Smartports macros embedded in the switch software are groups of CLI commands. The
CISCO_PHONE event detected on a port triggers the switch to apply the commands in the
CISCO_PHONE_AUTO_SMARTPORT macro. You can also create user-defined macros by using the
Cisco IOS Shell scripting capability, which is a BASH-like language syntax for command automation
and variable replacement.
Auto Smartports macros differ from static Smartports macros because static Smartports macros provide
port configuration that you manually apply based on the device connected to the port. When you apply
a static Smartports macro the CLI commands within the macro are added to the existing port
configuration. When there is a link-down event on the port, the switch does not remove the static macro
configuration.