Migrate REXX Procedures that Passed Analysis
12-1
The List of Procedures that Pass Analysis (Total=
n
) section near the end of the REXX Analyzer report identifies the REXX procedures that are most likely to be compatible. These procedures are usually the simplest to migrate. The team migrates these procedures first.These procedures contain only recognized entities, which are the REXX commands, functions, and pipe stages that have been implemented by the
NetMaster
NetView REXX Emulation environment. This does not guarantee that they will work unchanged, but they will generally be simple to change if required.Of Black Lion Telecom’s 200 NetView REXX procedures, the report indicates that 100 of them are procedures that passed analysis.
Verify the Procedures in Tivoli NetView
The
Broadcom
consultant recommends this step -- in previous migrations, a lot of time was wasted attempting to fix migrated procedures that did not work originally under Tivoli NetView. If problems occur with a procedure under NetMaster
, the fact that it was proven to work under Tivoli NetView narrows the problem determination effort.The network operators note the names of the 100 procedures that passed analysis.
They go to their production NCCF consoles and run the 100 procedures in Tivoli NetView to verify that they work correctly
before
, as well as after
, the move.They find that two of the procedures do not work in Tivoli NetView. They decide not to migrate these procedures.
Test the Procedures in
NetMaster
The migration team adds their NetView REXX procedures data set to NETM10's COMMANDS concatenation:
*-------------------------------------------------------------------- * PRODUCT REGION COMMANDS DATASET ALLOCATION *-------------------------------------------------------------------- DD=COMMANDS,BLKSIZE=32000,DISP=SHR,DSN=BLTNET.NETM10.TESTEXEC DD=*,DISP=SHR,DSN=BLTNET.WHATEVER.CC11EXEC DD=*,DISP=SHR,DSN=BLTNET.WHATEVER.CC2DEXEC DD=*,DISP=SHR,DSN=BLTNET.NETVIEW.PRODREXX
Because the REXX procedures use a customized CCDEF table and the VIEW command, the team also updates the NETVEMLDSN parameter group in NETM10 to point to the Tivoli NetView system definitions and panels that are used by the procedures.
The team then run these 100 REXX procedures, one by one, unchanged, in NETM10.
They run the procedures using the NCCF Emulation Facility. To access this facility, they type the command,
NCCF
, from OCS.This facility provides basic NCCF look-alike support. All commands entered under this facility are automatically assumed to be NetView REXX commands or procedures.
Example: Successful Procedure
Here is the result of running a procedure that checks the status of the currently active VTAM exits and reports if the required exit is not active.
(18.05)---------- NetMaster Operator Console Services (PROD1) ----------------- PROD1:USERO1 NCCF-like facility active, press PF3 to exit ACTVTMX10 - CHECKING ACTIVE VTAM EXITS - 28 Mar 2006 18:05:17 ACTVTMX10 - VTAM EXIT: ISTEXCUV IS ACTIVE ACTVTMX10 - VTAM EXIT: ISTEXCSD IS ACTIVE ACTVTMX10 - VTAM EXIT: ISTEXCAA IS ACTIVE ACTVTMX10 - VTAM EXIT: ISTEXCGR IS ACTIVE ACTVTMX10 - VTAM EXIT: ISTEXCPM IS ACTIVE ACTVTMX80 ----------------------------------------------------------------- ACTVTMX80 - ** VTAM EXIT: ISTEXCVR IS REQUIRED BUT IS CURRENTLY INACTIVE ** ACTVTMX80 ----------------------------------------------------------------- ACTVTMX99 DONE
The procedure is as follows:
/* REXX */ MSGID = 'ACTVTMX' WARNING = 'NO' SAY MSGID||'00' ' - CHECKING ACTIVE VTAM EXITS -' DATE('N') TIME('N') SAY 'PIPE VTAM D NET,EXIT ', ' | CORRWAIT 10', ' | SEP ', ' | LOC /IST1251I/', ' | STEM ACTX.' DO I = 1 TO ACTX.0 VTAMEXIT = WORD(ACTX.I,2) EXITSTATUS = WORD(ACTX.I,5) IF (EXITSTATUS = 'ACTIVE') THEN SAY MSGID||'10' '- VTAM EXIT: 'VTAMEXIT 'IS 'EXITSTATUS ELSE IF (VTAMEXIT = 'ISTEXCVR') THEN WARNING = YES END IF (WARNING = YES) THEN DO SAY MSGID||'80' '--------------------------------------------'||, '---------------------' SAY MSGID||'80' '- ** VTAM EXIT: ISTEXCVR IS REQUIRED BUT IS '||, 'CURRENTLY INACTIVE **' SAY MSGID||'80' '--------------------------------------------'||, '---------------------' END SAY SAY MSGID||'99' 'DONE ' EXIT
Review Test Results
Of Black Lion Telecom’s 100 NetView REXX procedures that passed analysis:
- 58 procedures execute without error the first time and produce the correct output.
- 12 procedures fail with a GREXX compile error.
- 10 procedures execute without error but produce incorrect output.
- 15 procedures have unrecognized or unsupported command parameters.
- 5 procedures failed during execution.
The team examines each of the procedures that did not work.
When testing the REXX procedures that passed analysis, there is no such thing as a typical spread of results. There is a very wide variance, from site to site, in the percentage of those procedures that will have a particular outcome.
Correct and Retest the Procedures in
NetMaster
The team corrects the procedures based on the encountered problem and retests them.
At the end of all of the repeated testing, updating and retesting of the procedures, 100 of Black Lion Telecom’s 200 NetView REXX procedures are now running successfully in NETM10.
Procedures with GREXX Compilation Errors
Causes of compilation errors are usually simple to identify.
After examination, a few procedures that got GREXX compile errors are found not to be REXX procedures, but Tivoli NetView CLISTs. The REXX header had been incorrectly added to them, so they were analyzed by mistake. The procedures are either removed from analysis or rewritten in REXX.
The other GREXX compile errors have the same cause. The REXX procedures contain a SIGNAL ON ERROR statement but no corresponding label. NetView REXX tolerates this, but
NetMaster
does not.Example: Procedure That Runs in Tivoli NetView but Does Not Compile in
NetMaster
/* REXX */ SIGNAL ON ERROR TOTAL = (1 + 1) SAY TOTAL
The following compilation error results:
(18.20)---------- NetMaster Operator Console Services (PROD1) ----------------- PROD1:USERO1 NCCF-like facility active, press PF3 to exit ------------------------------------------------------------------------------- NR1101 REXX COMPILE OF TT2 IN LIBRARY COMMANDS HAS ERRORS/WARNINGS: NR1284 ERROR 16 ... NR9916 Error within TT@ , line 2 Label not found
The solution is to make the REXX procedure code more accurate. Add the labels and associated proper error processing logic, as dictated by good programming practice.
When a procedure with a missing ON ERROR label is run in Tivoli NetView and a run-time error occurs, the processing continues exactly as if the ON ERROR statement was not there. This is not an advantage -- there could be a false sense of security from having SIGNAL statements that do nothing when triggered.
Procedures with Incorrect Output
Some NetView REXX procedures execute under
NetMaster
, but they produce incorrect output.After examining the code, the REXX programmers found the problem is due to some message prefix differences between Tivoli NetView and
NetMaster
.These procedures are updated to parse for the
NetMaster
messages prefixes.Procedures with Unsupported Parameters
Some NetView REXX procedures fail to execute because their parameters are not recognized. Although these procedures passed analysis, not every parameter on every emulated NetView REXX function, command, or pipe stage is supported.
Some of the unsupported parameters referred to Tivoli NetView-specific things that are not applicable under
NetMaster
. These parameters are removed. Retesting shows no loss of function.Some of the unsupported parameters do things that Black Lion Telecom requires. The REXX programmers update these procedures and use the appropriate NetMaster REXX pipe stage to issue
NetMaster
commands that perform the required function.NetMaster REXX supports many common Tivoli NetView pipe stages. The REXX programmers use the online help to get details of the pipe stage command parameters.
From OCS, they type
NCCF
, press F1, and select PIPE (NCCF) command.Example: Unsupported DELETE Parameter of CON Pipe Stage Command
Here is an example of running the following procedure that contains unsupported operands:
/* REXX */ " PIPE LIT /HELLO/|CON DELETE " EXIT
The following error results:
(18.48)---------- NetMaster Operator Console Services (PROD1) ----------------- PROD1:USERO1 NCCF-like facility active, press PF3 to exit ------------------------------------------------------------------------------- XNEM005 Unsupported keyword argument: DELETE XNH362E PIPELINE TERMINATED. ERROR IN STAGE 2 IN PIPELINE 'PIPE': CON DELETE
Procedures That Did Not Execute
Some NetView REXX procedures do not execute correctly.
After examining the code, the REXX programmers find that the procedures need non-executable files -- data, tables, and lists of VTAM commands -- that they usually find in the DSICLD data sets.
When the members were previously copied to BLTNET.NETVIEW.PRODREXX, the REXX procedures only were copied. This was so that only the very essential members were copied.
The non-executable members required by these procedures are now copied to the
NetMaster
PDS from the DSICLD data sets. The procedures now find their data and execute correctly.Considerations
Unlike NetView REXX, where procedure compilation is additional and chargeable, NetMaster REXX is always compiled. In production, this is a performance benefit.
In a development situation, where a REXX procedure may be frequently modified and retested, programmers can disable automatic compilation by
one
of the following methods:- Use the UNLOAD command to manually unload changed procedures.
- Use the PROFILE NCLTEST options to cause automatic recompilation.