Preparing a script file – HP XP7 Storage User Manual
Page 97
Setting the status refresh interval of the Tasks window
The Tasks window automatically updates every 60 seconds by default. This interval can be changed
using the following procedure.
Procedure 31 To change the refresh interval:
1.
Click Settings > Environmental Settings > Edit Information Display Settings.
2.
Specify the interval for Task Screen Refresh Interval. If No Update is specified, the Tasks window
will not be automatically updated. In this case, to refresh the window, you must use Refresh
or File > Refresh All.
3.
Click Apply.
Creating a configuration report using the Report Configuration Tool
You can create a configuration report by using a command prompt when you use the Report
Configuration Tool. By preparing a script file that contains a series of commands and scheduling
a task in Windows to execute the script at regular intervals, you can automate the creation and
the deletion of the configuration report.
Preparing a script file
Before creating the configuration report, you will need to write a series of commands in a script
file. When you run the Report Configuration Tool, the commands in the script files execute
sequentially and then create or delete a configuration report. See
command reference (raidinf commands) ” (page 132)
for a list of commands.
Two examples of scripts are shown below. Refer to these examples as needed to create a script
file that suits your needs.
•
“Example script for creating a configuration report”
•
“Example script for downloading a configuration report”
Example script for creating a configuration report
This script logs the user in, deletes a configuration report, creates a configuration report, and logs
the user out, using the Report Configuration Tool.
For each command except the logout command, this example performs three retries at intervals of
2 minutes, assuming that communication errors and other errors can occur. In addition, the delete
report
command is executed with the -fill option before the add report command, so that
the script does not terminate when 20 configuration reports accumulate in the SVP.
REM
REM Create Report Script(CreateReport.bat)
REM
SET USER=<Username for Remote Web Console>
SET PASS=<Password for Remote Web Console>
SET SERVER=<Hostname or IP address of SVP>
SET REPORT_NAME=DailyConfigurationReport
SET LOOP=2
REM LOOP:0-2 3Times
SET TIMEOUT=121
REM TIMEOUT 2[minutes]=120[s]
SET RAIDINF_PATH="C:\Program Files\raidinf"
SET /a CNT_LOGIN=0
:LOGIN_RETRY
REM ############################# LOGIN %CNT_LOGIN%
SET /a CNT_LOGIN=%CNT_LOGIN% + 1
%RAIDINF_PATH%\raidinf -login %USER% %PASS% -servername %SERVER%
if ERRORLEVEL 1 (
if %CNT_LOGIN% GTR %LOOP% GOTO :ABEND
CALL :SLEEP
Managing tasks
97