13-4
Cisco IE 3010 Switch Software Configuration Guide
OL-23145-01
Chapter 13 Configuring Smartports Macros
Configuring Smartports Macros
You can only delete a global macro-applied configuration on a switch by entering the no version of each
command in the macro. You can delete a macro-applied configuration on a port by enterin g the default
interface interface-id interface configuration command.
This example shows how to display the cisco-ie-desktop macro, how to apply the macro and to set the
access VLAN ID to 25 on an interface:
Switch# show parser macro name cisco-ie-desktop
--------------------------------------------------------------
Macro name : cisco-ie-desktop
Macro type : default interface
# macro keywords ACCESS_VLAN
#macro name cisco-ie-desktop
switchport mode access
switchport access vlan ACCESS_VLAN
switchport port-security
switchport port-security maximum 1
switchport port-security aging time 2
switchport port-security violation restrict
switchport port-security aging type inactivity
spanning-tree portfast
spanning-tree bpduguard enable
no macro description
macro description cisco-ie-desktop
--------------------------------------------------------------
Switch#
Switch# configure terminal
Switch(config)# interface gigabitethernet0/1
Switch(config-if)# macro apply cisco-ie-desktop $AVID 25
This example shows how to display the cisco-ethernetip macro and how to apply it to an interface:
Switch# show parser macro name cisco-ethernetip
Macro name : cisco-ie-global
Macro type : default interface
#macro name cisco-ethernetip
#macro keywords ACCESS_VLAN
#macro description cisco-ethernetip
switchport host
switchport access vlan ACCESS-VLAN
storm-control broadcast level 3.00 1.00
service-policy input CIP-Traffic
#service-policy input 1588
Switch# configure terminal
Switch(config)# interface fastethernet 0/1
Switch(config-if)# macro apply cisco-ethernetip ACCESS_VLAN 1
switchport mode will be set to access
spanning-tree portfast will be enabled
channel group will be disabled
Step 9 show running-config interface
interface-id
Verify that the macro is applied to an interface.
Step 10 copy running-config startup-config (Optional) Save your entries in the configuration file.
Command Purpose