cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
521
Views
0
Helpful
0
Replies

Smartport System Variables

m.weatherly
Beginner
Beginner

I'm writing custom Smartport macros and it appears that there are system variables that are not documented anywhere.  The documentation clearly shows how you can add custom variables, but all examples reference the following system variables:

$LINKUP

$INTERFACE

$TRIGGER

$AUTH_ENABLED

Is there a document that describes these system variables and others? Below is an example from the Smartport documentation.

Thanks,

Matt

Config# macro auto execute CISCO_CUSTOM_EVENT {
if [[ $LINKUP -eq YES ]]; then
conf t
interface $INTERFACE
description asp3-link-UP i.e. Custom Macro OFF
no macro description
switchport
switchport mode access
switchport access vlan $ACCESS_VLAN
spanning-tree portfast
exit
end
fi
if [[ $LINKUP -eq NO ]]; then
conf t
interface $INTERFACE
macro description $TRIGGER
switchport access vlan $ACCESS_VLAN
description asp3-link-DOWN i.e. Custom Macro ON
exit
end
fi
}

0 Replies 0
Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Recognize Your Peers