HP XP Command View Advanced Edition Software User Manual

Page 221

Advertising
background image

5.

Execute the CLI command-execution log output procedure to extract the CLI command-execution
log to the dataset you created in step 2.

If the procedure is stored in the sequential dataset

YUKON.EXTCMD

, execute as follows.

EXEC 'YUKON.EXTCMD' 'KTC31 YUKON.SYSLOG YUKON.KTLOG'

Example of a CLI command-execution log output procedure

/* REXX ***/

Parse Upper Arg Mystrg Myinds Myoutds;

"ALLOCATE DA('"Myinds"') F(INDD) SHR REUSE"

"ALLOCATE DA('"Myoutds"') F(OUTDD) OLD REUSE"

"EXECIO 0 DISKR INDD (OPEN)"

eof='NO'

DO WHILE eof = 'NO'

"EXECIO 1 DISKR INDD (STEM LINE.)"

IF RC = 2 THEN

eof='YES'

ELSE

DO

IF INDEX(LINE.1,Mystrg) <> 0 THEN

DO

"EXECIO 1 DISKW OUTDD (STEM LINE.)"

END

END

END

"EXECIO 0 DISKR INDD (FINIS)"

"EXECIO 0 DISKW OUTDD (FINIS)"

"FREE F(INDD)"

"FREE F(OUTDD)"

EXIT 0

User Guide

221

Advertising