22-2
Catalyst 4500 Series Switch, Cisco IOS Software Configuration Guide - Cisco IOS XE 3.9.xE and IOS 15.2(5)Ex
Chapter 22 Configuring Cisco IOS Auto Smartport Macros
About Auto Smartport Macros
The Auto Smartport macros are groups of CLI commands. Detection of devices on a port triggers the
application of the macro for the device. (For example, detecting a CISCO_PHONE event on a port
triggers the switch to apply the commands in the CISCO_PHONE_AUTO_SMARTPORT macro.)
System built-in macros exist for various devices, and, by default, system built-in triggers are mapped to
the corresponding built-in macros. You can change the mapping of built-in triggers or macros as needed.
A macro basically applies or removes a set of CLIs on an interface based on the link status. In a macro,
the link status is checked. If the link is up, then a set of CLIs is applied; if the link is down, the set is
removed (the
no
format of the CLIs are applied). The part of the macro that applies the set of CLIs is
termed
macro
. The part that removes the CLIs (the no format of the CLIs) are termed
antimacro
.
Besides creating user-defined triggers, you can also create user-defined macros and map one to the other
among all triggers (both built-in and user-defined) and all macros (both built-in and user-defined). Use
the Cisco IOS scripting capability to create the macros. Cisco IOS scripting is a BASH-like language
syntax for command automation and variable replacement.
The four detection mechanisms adhere to the following order of priority:
•
If 802.1X authentication is configured on a port, an authentication response-based trigger is applied,
and other triggers are ignored.
•
If 802.1X authentication fails and the CDP/LLDP fallback mechanism is configured, CDP/LLDP
triggers for phone devices only; if no fallback mechanism is configured, or a device is not a phone
device, nothing is triggered.
•
If 802.1X authentication is configured on a port, a MAC address-based trigger is never triggered.
•
If 802.1X authentication is not configured on a port, CDP/LLDP has priority over a MAC
address-based trigger with a hold-off timer applied for MAC-address based trigger. Between
CDP/LLDP, there is no particular order; whichever one arrives first is triggered.
Device Classifier
Starting with Cisco Release IOS XE 3.3.0SG and IOS 15.1(1)SG, the device classifier (DC) feature is
enabled by default on the Catalyst 4500 series switch.
The DC collects information from MAC-OUI and protocols such as CDP, LLDP, and DHCP to identify
devices. You must enable CDP and LLDP on the switch. To make DHCP options information available
to the DC, you must enable the DHCP snooping feature on the switch. The device attributes collected
from these protocols are evaluated against a set of profiles available to the DC to find the best match.
The best-matched profile is used for device identification.
Devices that do not send CDP, LLDP or DHCP traffic may not be properly identified by the device
classifier.
Device-classifier uses profile definitions—built-in and default profiles. The built-in profiles contain the
device profiles that are known to the Auto Smartport module, comprising a limited set of Cisco devices.
They are built into Cisco IOS and cannot be changed. The default profiles are stored as a text file in
nonvolatile storage and allow the DC to identify a much larger set of devices. The default profiles are
updated as part of the Cisco IOS archive download.
When a new device is detected, the corresponding shell trigger executes the Auto Smartport
configuration macro. Auto Smartport has built-in mappings for a large set of devices. You can use the
commands described in the
“Configuring Mapping Between User-Defined Triggers and Built-in
to create new mappings. You can create the trigger mappings based on the
profile name or device name that is provided by the DC.
Содержание Catalyst 4500 Series
Страница 2: ......
Страница 4: ......
Страница 2086: ...Index IN 46 Software Configuration Guide Release IOS XE 3 9 0E and IOS 15 2 5 E ...