Universal Port uses CLI Scripting variables to make system and trigger event information available to profiles. For more information, see Using CLI Scripting.
Variables allow you to create profiles and scripts that respond to the state of the switch as defined in the variables. When a profile is triggered, the system passes variables to the profile. You can also create and use variables of your own. User-defined variables are limited to the current context unless explicitly saved.
NoteYou must enable CLI scripting before using variables or executing a script.
If you save variables (as described in Saving, Retrieving, and Deleting Session Variables), certain data from one profile can be reused in another profile for another event. For example, between login and logout events, the data necessary for the rollback of a port configuration can be shared.
Common Variables shows the variables that are always available for use by any script. These variables are set up for use before a script or profile is executed.
|$STATUS||Status of last command execution.|
|$CLI.USER||Username for the user who is executing this CLI.|
|$CLI.SESSION_ID||An identifier for a session. This identifier is available for the roll-back event when a device or user times out.|
|$CLI.SESSION_TYPE||Type of session of the user.|
|$EVENT.NAME||This is the event that triggered this profile.|
|$EVENT.TIME||Time this event occurred. The time is in seconds since epoch.|
|$EVENT.TIMER_TYPE||Type of timer, which is periodic or non_periodic.|
|$EVENT.TIMER_NAME||Name of the timer that the Universal Port is invoking.|
|$EVENT.TIMER_LATE_SECS||Time difference between when the timer fired and when the actual shell was run in seconds.|
|$EVENT.PROFILE||Name of the profile that is being run currently.|
User Profile Variables shows the variables available to user profiles.
|$EVENT.USERNAME||Name of user authenticated. This is a string with the MAC address for MAC-based user-login.|
|$EVENT.NUMUSERS||Number of authenticated
supplicants on this port after this event occurred.
Note: For user-authenticated events, the initial value of this variable is 0. For user unauthenticated events, the initial value is 1.
|$EVENT.USER_MAC||MAC address of the user.|
|$EVENT.USER_PORT||Port associated with this event.|
|$EVENT.USER_VLAN||VLAN associated with
this event or user.
Note: If the VLAN is assigned dynamically, and the name is not available at the time of authentication, “$EVENT.USER_VLAN” is returned as “<Not Found> xxx” where xxx is the VLAN number. This is not translated by UPM VLAN processing and appears for diagnostic purposes only.
|$EVENT.USER_ALL_VLANS||When a user is authenticated to multiple VLANs, this variable includes all VLANs for which the user is authenticated.|
|$EVENT.USER_IP||IP address of the user if applicable. Otherwise, this variable is blank.|
Device Profile Variables shows the variables available to device detect profiles.
Device identification string.
Possible values for EVENT.DEVICE are: AVAYA_PHONE, GEN_TEL_PHONE, ROUTER, BRIDGE, REPEATER, WLAN_ACCESS_PT, DOCSIS_CABLE_SER, STATION_ONLY and OTHER.
These strings correspond to the devices that the LLDP application recognizes and reports to the Universal Port management application.
|$EVENT.DEVICE_IP||The IP address of the device (if available). Blank if not available.|
|$EVENT.DEVICE_MAC||The MAC address of the device (if available). Blank if not available.|
|$EVENT.DEVICE_POWER||The power of the device in milliwatts (if available). Blank if not available.|
|$EVENT.DEVICE_MANUFACTURER_NAME||The manufacturer of the device.|
|$EVENT.DEVICE_MODEL_NAME||Model name of the device.|
|$EVENT.USER_PORT||Port associated with the event.|
Event Profile Variables shows the variables available to event profiles.
|$EVENT.NAME||The event message.|
|$EVENT.LOG_DATE||The event date.|
|$EVENT.LOG_TIME||The event time.|
|The component and subcomponent affected by the event as it appears in the show log components command display.|
|$EVENT.LOG_EVENT||The event condition as it appears in the show log events command display.|
|The EMS filter that triggered the profile.|
|$EVENT.LOG_SEVERITY||The event severity level defined in EMS.|
|$EVENT.LOG_MESSAGE||The event message with arguments listed in the format %1%.|
|$EVENT.LOG_PARAM_0 to $EVENT.LOG_PARAM_9||Event arguments 0 to 9.|