EasyManua.ls Logo

Cisco ASR 9000 Serie

Cisco ASR 9000 Serie
378 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
PurposeCommand or Action
The following example pkgIndex is created when some Tcl package
files are in a library file directory and the pkg_mkindex command
is run:
pkgIndex
# Tcl package index file, version 1.1
# This file is generated by the "pkg_mkIndex" command
# and sourced either when an application starts up or
# by a "package unknown" script. It invokes the
# "package ifneeded" command to set up package-related
# information so that packages will be loaded
automatically
# in response to "package require" commands. When this
# script is sourced, the variable $dir must contain the
# full path name of this file's directory.
package ifneeded xmlrpc 0.3 [list source [file join $dir
xmlrpc.tcl]]
Copy the Tcl package files from Step 1 and the
pkgIndex file from Step 3 to the directory used for
storing user library files on the target router.
Step 4
The directory can be the same directory used in Step 4, on page
79.
Copy a user-defined EEM policy file written in Tcl
to the directory used for storing user-defined EEM
policies on the target router.
Step 5
The following example user-defined EEM policy can be used to
test the Tcl library support in EEM:
packagetest.tcl
::cisco::eem::event_register_none maxrun 1000000.000
#
# test if xmlrpc available
#
#
# Namespace imports
#
namespace import ::cisco::eem::*
namespace import ::cisco::lib::*
#
package require xmlrpc
puts "Did you get an error?"
configure
Step 6
Specifies the EEM user library directory; this is the directory to
which the files in Step 4, on page 79were copied.
event manager directory user library path
Example:
RP/0/RSP0/CPU0:router(config)# event manager
directory user library disk2:/eem_library
Step 7
Cisco ASR 9000 Series Aggregation Services Router System Monitoring Configuration Guide, Release 4.2.x
79
Configuring and Managing Embedded Event Manager Policies
How to Write Embedded Event Manager Policies Using Tcl

Table of Contents

Related product manuals