Download Print this page

HP XP P9500 Reference Manual page 262

Hp p9000 for business continuity manager software reference guide
Hide thumbs Also See for XP P9500:

Advertisement

/*
/**********************************************************************/
/* Sample script begins. */
say "#-- BEGIN YKDEMO01.";
address TSO "YKENV"
/*
* YKLOAD should always be called to make information about a copy
* group available from the REXX environment. In this YKLOAD calling,
* the information about "MYTCS" in "BCM.DEMO" is loaded and stored
* into the REXX variable structure beginning with "DEMO_INFO.".
* One or more error messages that may be generated during execution
* of a CLI command will be stored in the message structure with the
* prefix that is specified by the MSG parameter. In this example,
* the message structure is assumed to have the prefix "DEMO_MSG.".
* Notice that YKLOAD is called with "call" instruction because it is
* a REXX subroutine, not TSO/E command.
*/
call "YKLOAD" "STEM(DEMO_INFO.) PREFIX(BCM.DEMO) GROUP(MYTCS)",
/*
* Make sure that YKLOAD completed successfully. If YKLOAD failed,
* the return value "result" is non-zero.
*/
if result /= 0
then do
call printErrorMessage;
exit;
end;
else
nop;
/*
* You should always refresh the information in the Copy Group
* structure before calling any copy group-manipulation command such
* as YKMAKE, YKSUSPND and so on.
* To refresh the information, use YKQUERY.
*/
address TSO "YKQUERY STEM(DEMO_INFO.) MSG(DEMO_MSG.)";
/*
* The return code must be checked. Notice that the return code is
* checked to see if it is bigger than 8, not 0. In YKQUERY, the
* return code 8 indicates that one or more volumes in the given
* copy group are offline, which is not necessarily a bad situation.
*/
if rc > 8
then do
call printErrorMessage;
exit;
end;
else
nop;
call printCopyGroupStatus;
/*
* Alternatively, you can use YKEWAIT to retrieve the copy group
* status information more quickly as YKEWAIT also updates the Copy
* Group structure (but not entirely. The information items that are
* RCU-dependant such as C/T Delta and C/T Time are not updated).
* Refer to Business Continuity Manager Reference Guide to see how
262 CLI Commands
"DAD(PRIM) MSG(DEMO_MSG.) ROUTE(DEMORLST)";
/* Prints the copy group status info.
*/
*/

Advertisement

loading

This manual is also suitable for:

P9000 for business continuity manager 6.6.1