Executing script files, Saving script files, Sample script files – HP MPX200 Multifunction Router User Manual
Page 8
Executing script files
The execute script command accepts a text file containing a series of Remote CLI commands
to be run in sequence.
For more information, see
.
Saving script files
After you finish setting up a new router, or whenever you save an FRU image, HP recommends
that you save the configuration script. The save script command saves an editable text file
containing a series of commands that can configure a router that has been reset to factory settings
For more information, see
Sample script files
Remote CLI provides sample scripts for Python and other scripting languages. You can use some
of these sample scripts with little or no modification. To view examples of the Remote CLI script
files, go to the install_dir\examples folder. The default installation directories are:
•
For Microsoft Windows:
C:\Program Files\QLogic Corporation\iSR-rcli\examples
•
For Linux:
/usr/share/doc/qlogic_rcli/examples
lists and describes the Remote CLI sample script folders that are included in the
installation.
Table 1 Remote CLI sample scripts
Description
Folder name
This folder contains a Perl script that produces a list of hard-coded router IP
addresses and reboots each router in turn. After the reboot is complete, the script
check_fcip_port_speed
retrieves the FCIP route information, stops if the port speed is exactly 100Mb,
and then continues to the next router. This script requires some modification for
use.
This folder contains a Python script that finds the hard-coded IP address of a
router and periodically collects performance data. To provide a continuous
iostats
display of the current values, leave this script running in a command prompt to
clear and refresh the window each time.
This script also captures output in a collection of csv files suitable for import
into a spreadsheet program such as Microsoft Excel. It produces one file for
each port and for each LUN. After data has been collected, you can use the
merge csv
command to combine all csv files into a summary csv file. See
. You can import the summary csv file into a spreadsheet
to produce graphs of usage over time, so that maintenance operations can be
scheduled for times when the network is less busy.
This folder contains scripts for automatically loading firmware on all MPX200s
in a local network subnet. After loading new firmware, this script restarts the
load_firmware
routers, obtains and verifies the firmware version number of each, and generates
log files that include router serial numbers.
This folder contains both Linux and Windows scripts that periodically collect and
display data from a specified router:
monitor
•
monitor.sh
—Collects temperature data. This script can be easily modified
to collect any other data available from the router.
•
perfmon.sh
—Collects performance information and I/O statistics and saves
the infomation to a csv file for later analysis. This script is useful without any
modification
8
Getting started