Running A Script From The Ftos Cli - Dell FORCE10 Open Automation Configuration

Open automation guide
Table of Contents

Advertisement

Running a Script from the FTOS CLI

Command Syntax
[username name]
script
script-path [script-parameter
script-parameter ...]
f)# script /usr/pkg/scripts/sample_scripts/cmd-server.pl
f)# no script /usr/pkg/scripts/sample_scripts/cmd-server.pl
f)# script username admin /usr/pkg/scripts/sample_scripts/DisplayAlarms.py
f)# no script username admin /usr/pkg/scripts/sample_scripts/DisplayAlarms.py
You can run any PERL, Python, and UNIX script that is stored on the switch from the
FTOS CLI.
When you run a script from the FTOS CLI, you can specify an optional user name to
apply the associated read-write privileges when the script is run (see
Name and Password for Smart
script is run with the privileges of the current user.
To run a PERL, Python, or UNIX script from the FTOS CLI, enter the
command. You must enter the script name and directory path to start the script. The
script can invoke any of the supported UNIX utilities listed in
enter the command multiple times to run more than one script at the same time.
Command Mode
CONFIGURATION
To stop a script that is running. enter the
example:
no script admin.pl
To display the scripts that are currently running, including the scripts you have
stopped, enter the
show running-config | grep
Figure 3-1. Starting and Stopping PERL and Python Scripts: Examples
Tip: For information on how to run a script directly from a UNIX shell without using
the FTOS CLI, see
Running a Script from the UNIX
Scripting). If you do not specify a user name, the
Task
Run an installed script; for examples, see
For script-path, enter the directory path and filename.
(Optional) For username name, enter the user name
whose read-write privileges will be applied when the script
is run. A username used to run scripts cannot contain
special characters.
(Optional) For script-parameter, enter the values of up to
three parameters to be applied when the script is run. Enter
a blank space between parameter values; for example:
script username admin /f10/flash/createVlans.py 1 2
version of the
no
.
command.
Creating a User
script
Table
3-2. You can
Figure
3-1.
command; for
script
Shell.
Smart Scripting | 21

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FORCE10 Open Automation and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Force10

Table of Contents