16-7
Software Configuration Guide—Release 15.0(2)SG
OL-23818-01
Chapter 16 Configuring SmartPort Macros Configuring SmartPort Macros
Use the macro global trace macro-name global configuration command or the macro trace
macro-name interface configuration command to apply and debug a macro to find any syntax or
configuration errors. If a command fails because of a syntax error or a configuration error, the macro
continues to apply the remaining commands.
Some CLI commands are specific to certain interface types. If a macro is applied to an interface that
does not accept the configuration, the macro fails the syntax check or the configuration check, and
the switch returns an error message.
Applying a macro to an interface range is the same as applying a macro to a single interface. When
you use an interface range, the macro is applied sequentially to each interface within the range. If a
macro command fails on one interface, it is still applied to the remaining interfaces.
When you apply a macro to a switch or a switch interface, the macro name is automatically added
to the macro description of the switch or interface. You can display the applied commands and
macro names by using the show parser macro description user EXEC command.
The user-configurable macro has a buffer that can take commands and comments up to 3000
characters. Each new line takes two characters, and empty lines are counted as is.
Cisco-default SmartPort macros are embedded in the switch software (see Table 16-1). You can display
these macros and the commands they contain by using the show parser macro user EXEC command.
Follow these guidelines when you apply a Cisco-default SmartPort macro on an interface:
Display all macros on the switch by using the show parser macro user EXEC command. Display
the contents of a specific macro by using the show parser macro macro-name user EXEC
command.
Keywords that begin with $ mean that a unique parameter value is required. Append the
Cisco-default macro with the required values by using the parameter value keywords.
The Cisco-default macros use the $ character to help identify required keywords. There is no
restriction on using the $ character to define keywords when you create a macro.