beautypg.com

HP XP Command View Advanced Edition Software User Manual

Page 273

background image

/DEMO_STEM.TPG.VOL.IO.Interval;

IF TRUNC(val_iops.j) /= val_iops.j THEN DO;

IF val_iops.j < 100 THEN

val_iops.j = TRUNC(val_iops.j,3);

ELSE

val_iops.j = TRUNC(val_iops.j,0);

END;

END;

/*

* Display this volume's I/O statistics.

*/

SAY ' 'RIGHT(val_Devn,4)','LEFT(val_Volser,6)||,

','LEFT(val_STORGRP,8)','val_SN','val_CU||,

', 'val_CCA||','RIGHT(val_iops.1,10)||,

','RIGHT(val_iops.2,10)','RIGHT(val_iops.3,10);

END;

END;

/*

* Wait for interval.

*/

address syscall "sleep" opt_interval

END;

SAY "#-- END KTDEMO14."; /* The sample script completed. */

EXIT 0;

/*

* printErrorMessage: This procedure prints all of the error messages

* in the Message structure when a CLI command failed.

*/

printErrorMessage: procedure expose DEMO_MSG.

ARG cli_name cli_result;

SAY "Command name=" || cli_name || ",result=" || cli_result;

IF DATATYPE(DEMO_MSG.0) = 'NUM' THEN

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;

User Guide

273