What do cisco marco's do

Unanswered Question
Jan 28th, 2009
User Badges:

I have read cisco's doc on what macro's do and am still unclear..


I found this configuration in a switch that we are taking over



I dont see the word macro in the config in any other place but this interface


interface GigabitEthernet0/17

switchport trunk encapsulation dot1q

switchport trunk allowed vlan 14,17

switchport mode trunk

macro description cisco-switch | cisco-switch | cisco-switch

auto qos voip trust

spanning-tree link-type point-to-point



nyc-swi#show parser macro name cisco-switch

Macro name : cisco-switch

Macro type : default interface

# macro keywords $native_vlan

# Access Uplink to Distribution

# Do not apply to EtherChannel/Port Group

switchport trunk encapsulation dot1q


# Define unique Native VLAN on trunk ports

# Recommended value for native vlan should not be 1

switchport trunk native vlan $native_vlan


# Update the allowed VLAN range such that it

# includes data, voice and native VLANs

switchport trunk allowed vlan ALL


# Hardcode trunk

switchport mode trunk


# Configure qos to trust this interface

auto qos voip trust


# 802.1w defines the link as pt-pt for rapid convergence

spanning-tree link-type point-to-point


  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
Loading.
paolo bevilacqua Wed, 01/28/2009 - 09:53
User Badges:
  • Super Gold, 25000 points or more
  • Hall of Fame,

    Founding Member

The hardcoded macro doesn't show in configuration but you have correctly visualized its definitions.


Then it's up to you to decide if these are appropriate for your application.

brooklynheight Wed, 01/28/2009 - 11:14
User Badges:

Ok..so basically i could make

a macro that for examples


makes all interfaces 100 full duplex

set for vlan 5

and portfast?


than just apply this macro to the interfaces

that i want to have the configuration?



and as you said...cisco ships with

default macros?

paolo bevilacqua Wed, 01/28/2009 - 12:47
User Badges:
  • Super Gold, 25000 points or more
  • Hall of Fame,

    Founding Member

Yes. Try show parser macro to see them all.

Actions

This Discussion