Cisco ASR 9000 Serie Configuration Manuals page 76

Aggregation services router system
Table of Contents

Advertisement

How to Write Embedded Event Manager Policies Using Tcl
DETAILED STEPS
Command or Action
Step 1
show event manager environment [ all |
environment-name]
Example:
RP/0/RSP0/CPU0:router# show event manager
environment all
Step 2
configure
Step 3
event manager environment var-name [ var-value ]
Example:
RP/0/RSP0/CPU0:router(config)# event manager
environment _cron_entry 0-59/2 0-23/1 * * 0-7
Step 4
Repeat
Step 3, on page 60
environment variables required by the policy to be
registered in
Step 5, on page
Step 5
event manager policy policy-name username
username [ persist-time [ seconds | infinite ] | type [
system | user ]]
Example:
RP/0/RSP0/CPU0:router(config)# event manager
policy tm_cli_cmd.tcl username user_a type
system
Step 6
commit
Cisco ASR 9000 Series Aggregation Services Router System Monitoring Configuration Guide, Release 4.2.x
60
Purpose
(Optional) Displays the name and value of EEM environment
variables.
Resets environment variables to new values.
to configure all the
60.
Registers the EEM policy to be run when the specified event
defined within the policy occurs.
In this example, the sample EEM policy named tm_cli_cmd.tcl is
registered as a system policy.
Configuring and Managing Embedded Event Manager Policies
• The all keyword displays all the EEM environment
variables.
• The environment-name argument displays information about
the specified environment variable.
• The var-name argument is the name assigned to the EEM
environment configuration variable.
• The var-value argument is the series of characters, including
embedded spaces, to be placed in the environment variable
var-name .
• By convention, the names of all environment variables
defined by Cisco begin with an underscore character to set
them apart; for example, _show_cmd.
• Spaces may be used in the var-value argument. The
command interprets everything after the var-name argument
to the end of the line to be part of the var-value argument.
• Use the system keyword to register a system policy defined
by Cisco.
• Use the user keyword to register a user-defined system
policy.
• Use the persist-time keyword to specify the length of time
the username authentication is valid.

Advertisement

Table of Contents
loading

Table of Contents