21-7
Software Configuration Guide—Release IOS XE 3.6.0E and IOS 15.2(2)E
OL_28731-01
Chapter 21 Configuring Cisco IOS Auto Smartport Macros
Configuring Auto Smartport Macros
The no macro auto execute event trigger {[builtin built-in macro name [parameter=value]] |
[[parameter=value] {function contents}]} command deletes the mapping.
This example shows how to use two built-in Auto Smartport macros for connecting Cisco switches and
Cisco IP phones to the switch. This example modifies the default voice VLAN, access VLAN, and native
VLAN for the trunk interface:
Switch# configure terminal
Switch(config)# macro auto execute CISCO_PHONE_EVENT builtin CISCO_PHONE_AUTO_SMARTPORT
ACCESS_VLAN=10 VOICE_VLAN=20
Switch(config)#
Switch(config)#
Step 2
Switch(config)# macro auto execute
event trigger builtin
built-in
macro name [parameter=value]
[parameter=value]
Defines mapping from an event trigger to a built-in macro.
Specify an event trigger value:
• CISCO_PHONE_EVENT
• CISCO_SWITCH_EVENT
• CISCO_ROUTER_EVENT
• CISCO_WIRELESS_AP_EVENT
• CISCO_WIRELESS_LIGHTWEIGHT_AP_EVENT
• CISCO_DMP_EVENT
• CISCO_IPVSC_EVENT
• WORD—Apply a user-defined event trigger.
Specify a built-in macro name value:
• CISCO_PHONE_AUTO_SMARTPORT
(Optional) Specify the parameter values: $ACCESS_VLAN=(1) and
$VOICE_VLAN=(2).
• CISCO_SWITCH_AUTO_SMARTPORT
(Optional) Specify the parameter values: $NATIVE_VLAN=(1).
• CISCO_ROUTER_AUTO_SMARTPORT
(Optional) Specify the parameter values: $NATIVE_VLAN=(1).
• CISCO_AP_AUTO_SMARTPORT
(Optional) Specify the parameter values: $NATIVE_VLAN=(1).
• CISCO_LWAP_AUTO_SMARTPORT
(Optional) Specify the parameter values: $ACCESS_VLAN=(1).
• CISCO_DMP_AUTO_SMARTPORT
• CISCO_IP_CAMERA_AUTO_SMARTPORT
(Optional) parameter=value—Replace default values that begin with $.
Enter new values in the form of name value pair separated by a space:
[name1=value1 name2=value2...]. Default values are shown in
parenthesis.
Step 3
Switch(config)# end
Returns to privileged EXEC mode.
Step 4
Switch# show running-config
Verifies your entries.
Step 5
Switch# copy running-config
startup-config
(Optional) Saves your entries in the configuration file.
Command Purpose