HP XP P9000 for Business Continuity Manager Software Reference Guide

nop
/*
* Wait for completion of copying from the primary site to
* the remote site.
*/
address TSO "YKEWAIT STEM(DEMO_INFO.MYUR1.) MSG(DEMO_MSG.)",
"GOTO(DUPLEX) TIMEOUT(30)"
/*
* Check the return code of YKEWAIT.
*/
if rc /= 0
then do
call printErrorMessage
exit
end
else
nop
say "#-- END YKDEMO09."
exit
/*
* printErrorMessage: This procedure prints all of the error messages
* in the Message structure when a CLI command failed.
*/
printErrorMessage: procedure expose DEMO_MSG.
do x = 1 to DEMO_MSG.0
say "Severity = " || DEMO_MSG.x.Severity
say "Text = " || DEMO_MSG.x.Text
say "Value = " || DEMO_MSG.x.Value
end
return 0
YKDEMO10
/* REXX */
/**********************************************************************/
/* */
/* All Rights Reserved. Copyright (C) 2009, 2010, Hitachi, Ltd. */
/* */
/**********************************************************************/
/* */
/* YKDEMO10 is a sample demonstration script of YKWTOMSG. */
/* Using YKWTOMSG, a REXX script can pass a string to another script */
/* through a MCS console. */
/* */
/* Summary of the procedure is following steps. */
/* 1) Issuing YKQRYDEV to retrieve the volume information. */
/* 2) Depending on result of YKQRYDEV, either USR000I or USR001E */
/* message will be written to MCS console by YKWTOMSG. */
/* If the command is terminated successfully, the script writes */
/* USR000I message with some command device related attributes. */
/* If the command is terminated abnormally, the script writes */
/* USR001E message with return code. */
/* */
/* To run the script, execute "START YKDEMO1S,DEVN=xxxx" from your */
/* MCS console. YKDEMO1S is a sample cataloged procedure of BCM. */
/* "xxxx" is device number of a volume. This value is passed to DEVN */
/* parameter of YKQRYDEV. Specify the value to fit your environment. */
/* */
Command details 297