Executing scripts at the dos command prompt, Executing scripts at the unix command prompt – HP NetRAID-4M Controller User Manual

Page 313

Advertising
background image

15-3

Working with Scripts

Executing Scripts at the DOS Command Prompt

You can execute a CLI script at the DOS command prompt as
follows:

Enter the script filename with a .bat filename extension at the
command prompt and press Enter, as in the following
example.

C:\> clist.bat

The CLI commands in this script file must be entered on a
single line and separated by a ";" (semicolon), as in the
following example. The script file may contain CLI and DOS
commands. In the example, the first line of the script is the
DOS dir command. The second line of the script is a series of
CLI commands separated by a ";".

dir clist.bat

afacli; open HPN0; container list; close; exit

Enter the

afacli

command followed by "@" (at sign) and a

script filename with a .afa filename extension, as in the
following example.

C:\> afacli @clist.afa

The commands in this script file must be separated by a
carriage return. The script file may contain CLI commands
only. See Executing a Script from the CLI Command Prompt on
page 15-2 for an example of a script with commands separated
by a carriage return.

Enter a series of CLI commands at the DOS command prompt.
A series of commands entered after the

afacli

command,

must be delimited by ";" (semicolon) and enclosed in a pair of
double quotation marks (" "), as in the following example.

C:\> afacli "open HPN0;logfile start /append=true 3-22-

log.txt; container list; logfile end;close;exit"

Executing Scripts at the UNIX Command Prompt

You can execute a CLI script at the UNIX command prompt as
follows:

Enter the script filename and press Enter, as in the following
example.

Advertising