
Triggers Introduction
©2008 Allied Telesis Inc. All rights reserved.
59.2
AlliedWare Plus
TM
Operating System Software Reference C613-50003-00 REV E
Software Version 5.2.1
Introduction
The Trigger facility provides a powerful mechanism for automatic and timed management of
your device by automating the execution of commands in response to certain events. For
example, you can use triggers to deactivate a service during the weekends, or to collect
diagnostic information when the CPU usage is high.
A
trigger
is an ordered sequence of scripts that is executed when a certain event occurs. A
script
is a sequence of commands stored as a plaintext file on a file subsystem accessible to the
device, such as Flash memory. Each trigger may reference multiple scripts and any script may be
used by any trigger. When an event activates a trigger, the trigger executes the scripts
associated with it in sequence. Various types of triggers are supported, each activated in a
different way.
Configuring a Trigger
The following describes the general steps to configure a trigger. For specific configuration
examples, see
Chapter 60, Triggers Configuration
.
1.
Create a configuration script
Create a configuration script with the commands you’d like executed when the trigger
conditions are met. To create the configuration script using the CLI, use the command:
awplus#
edit [<filename>]
Alternatively you can create a script on a PC then load it onto your device using the
copy
URL
command.
2.
Enter the trigger configuration mode
You must be in the Configure mode to reach the Trigger configuration mode. Use the
command:
awplus#
configure terminal
To create a trigger, and enter its configuration mode, use the command:
awplus(config)#
trigger <1-250>