Managing scripts on a brocade virtual adx, Overview, Importing and exporting scripts – Brocade Virtual ADX OpenScript Programmer’s Guide (Supporting ADX v03.1.00) User Manual
Page 21: Chapter 3

Brocade Virtual ADX OpenScript Programmer’s Guide
13
53-1003244-01
Chapter
3
Managing Scripts on a Brocade Virtual ADX
Overview
A script can be written with any text editor or using the Brocade Virtual ADX GUI. The Brocade
Virtual ADX GUI process is described in the Brocade Virtual ADX GUI Configuration Guide.
Once a script has been written, it must be uploaded to a Brocade Virtual ADX to be compiled and
bound to a port. In addition, several operations can be performed on the script and a profile can be
defined that sets the environmental variables under which the script will run. This chapter
describes each of these operations.
•
“Importing and exporting scripts”
– This section provides information for copying a script to or
from a Brocade Virtual ADX using secure copy through an SSH connection.
•
– This section describes how to delete or rename a script that you have
imported onto a Brocade Virtual ADX. It also describes the process of displaying the contents
of a script that resides on a Brocade Virtual ADX.
•
“Compiling and binding scripts”
– Once a script has been imported to a Brocade Virtual ADX, it
must be compiled and bound to a virtual server port. This section describes how to perform
these actions and update the contents of an existing script.
•
“Creating and configuring script profiles”
– A series of default values for environmental
variables are used in compilation of a script on a Brocade Virtual ADX. If these values are
acceptable for your use, you do not need to create and define a script profile. This section
describes the default values and how to create and define a script profile that alters these
values for your application.
•
“Displaying script information”
– Several show commands are provided to display information
about scripts residing on a Brocade Virtual ADX.
Importing and exporting scripts
For a script to be run on a Brocade Virtual ADX, it must be in the following file location:
/opt/ADX/openscripts/dpscript
You can create or edit scripts in this directory. Note that a script name is a maximum of
eight characters and its extension is a maximum of three characters.
You can also copy files to or export files from this directory using SCP through an SSH connection.
For example, the following command secure copies the addip.pl script from the /home/test
directory on the Linux server 1.1.1.1 to the Brocade Virtual ADX.
[root@VirtualADX~] scp [email protected]:/home/test/addip.pl
/opt/ADX/openscripts/dpscript/addip.pl