Previous Topic: CTSDEU Utility—Erase DataNext Topic: CTSSYNC Utility—Support 3495/3494 Devices


Job Control Statements

This feature is delivered as a single program CTSDEU which is installed in the CA 1 load library CAI.CTAPLINK when maintenance is applied using SMP/E. Sample JCL to execute the CTSDEU program follows:

//stepname  EXEC  PGM=CTSDEU[,PARM='parm']
//STEPLIB   DD   DSN=CAI.CTAPLINK,DISP=SHR
//SYSPRINT  DD SYSOUT=*
//SYSUT1    DD   UNIT=(TAPE,,DEFER),DISP=(OLD,KEEP),LABEL=(,SL),  *NOTES
//               VOL=SER=anyvol,                                 *NOTES
//               DSN=any.tape.file

Notes:

Parameter Definition

ERASE

Reads the tape header label and verifies that the tape is in the TMC, that it is not a virtual tape, and the data set names match those recorded in the TMC. If the volume serial number was not supplied by VOLLAB1, the VOLSER from the VOL1 record on SL or AL or TMSXTPPR user exit. The console operator is asked to supply the volume serial number.

Note: When ERASE is used on a scratch tape, we assume that the intent is to erase the whole tape. The DSN field in the tape catalog will be changed to (CTSDEU.ERASE.yyyy/ddd), where the first character is a hexzero and the tape will be reinitialized.

NOERASE

Reads the tape header label and verifies that the tape matches the TMC, no residual data is erased. The default is ERASE.

Note: If the NOERASE parameter is used on a scratch tape, the specified scratch tape is taken out of scratch status. Only the volume specified in the JCL will be mounted.

ALL

Indicates that all volumes of the requested tape file should be secured. Normally when a set of tapes are produced, they are filled completely, overlaying any old data. If force end of volume (FEOV) macro is used to produce short tapes, data previously written may not be overlaid.

LAST

Indicates that only the last volume of the requested tape file will be secured. The default is ALL.

LIST

A detail list of the contents of the requested volumes is produced.

NOLIST

A detail list is not produced. The default is NOLIST.

CTSMAIL Utility – Email or WTO

The CTSMAIL utility enables you to send WTOs and emails that contain substitution variables from the VDB. The utility is the batch version of the services that the Volume Pool Monitor (VPM) subtask of the CTS provides. CTSMAIL can do the following actions:

CTSMAIL enables you to test the formatting of emails or WTOs that you create. You can then specify the emails and WTOs in an alert that the VPM subtask monitors. You can also add notification emails or WTOs to existing jobs for tape management and other systems.

JCL to execute the CTSMAIL utility is provided in member CTSJMAIL of hlq.CTAPJCL.

Note: Product variables that the TMSCLEAN, TMSCOPY, and TMSVMUPD utilities create are available to include in emails or WTOs after the VPM subtask updates the Product Variables table and writes it back to the VDB. The OPT_VPM_TIMER variable specifies how often the VPM subtask updates the table. If OPT_VPM_TIMER specifies 10 minutes, it can be up to 10 minutes before the new product variables are added to the VDB and information from the most recent run of these utilities is available.

CTSMAIL invokes either a WTO processor (CTSWTO) or an email processor (CTSEML) depending on the member that the CAI.SEND data set or the CAMAILIN DD processes. CTSMAIL obtains a list of substitution variables and their values and it changes the WTO or email text to reflect the variable values. The utility then issues the WTO or sends the email.

The source statements are in a data set that the CAMAILIN DD defines or in a CAI.SEND data set that the variable OPT_EMAIL_DEFAULT_DSN defines. If the source is in the CAI.SEND data set, the utility obtains a member list from the EXEC PARM or CAMAILIN DD statement. If you specify both the items, the utility uses only the EXEC PARM.

If you specify a member list, each CAI.SEND member is dynamically allocated. CTSMAIL then processes the source statements for control statements. The remaining statements are tabled for the WTO or email processor. If the source is in-stream in the CAMAILIN DD, CAI.SEND is not allocated.

Note: The output of the WTO is limited to 426 lines of 70 characters by z/OS restrictions. The tabled source is limited to 60,000 bytes. Email servers between the sender and receiver can limit the output of the email.

Report Description

CTSMAIL does not produce a report. CTSMAIL and its processors (CTSWTO, CTSEML) write WTOs and set return codes when errors occur.

Job Control Statements

//SEND     EXEC PGM=CTSMAIL,                                              
//  PARM='SAMPE01,SAMPW01'                                                
//STEPLIB  DD DSN=CAI.CTAPLINK,DISP=SHR                                   
//SYSUDUMP DD   SYSOUT=*                                                  
//*                                                                       
//*CAMAILIN DD   DSN=CAI.SEND(SAMPE01),DISP=SHR  SOURCE IN A PDS MEMBER   
//*CAMAILIN DD   DSN=CAI.SEND(SAMPW01),DISP=SHR  SOURCE IN A PDS MEMBER   
//*CAMAILIN DD   DSN=ANY.FILE,DISP=SHR           SOURCE IN A FILE         
//*CAMAILIN DD   *                               SOURCE INLINE            
//CAMAILIN DD   *                                                         
  SAMPW01,SAMPE01,YOURMAIL,YOURWTO       /* MANY MEMBER OF ONE CARD */    
  SAMPW01                                /* ONE MEMBER ON EACH CARD */    
  SAMPE01                                /*        OR               */    
  YOURMAIL                               /*   A COMBINATION         */    
  SAMPW01 SAMPE01,YOURMAIL    YOURWTO    /* SEPARATED WITH COMMAS    */   
  SAMPW01                     SAMPE01    /*     OR SPACES           */    
//                                                                        

Parameter Definition

member,member,…

Specifies a list of members. The members must exist in the CAI.SEND data set.

JCL Considerations

CAMAILIN DD

Do not specify if you use the EXEC PARM to specify a member of the CAI.SEND data set to process. If you do not use EXEC PARM, specify the CAMAILIN DD to provide a list of members in the CAI.SEND data set to process. The CAMAILIN can also include source statements to create a WTO or an email.

Control Statement Specification

You can specify the control statements in the CAMAILIN DD in two formats. You can specify them as a list of members to process in the CAI.SEND data set. If the first statement begins with EMAIL or WTO, you define an in-stream email or WTO to send.

For emails, the first statement contains just EMAIL followed by email header fields and the body of the email.

For WTOs, the first statements must contain WTO with the ROUTCDE parameter on the same line or the next line.

The following example shows a test WTO with an in-stream text:

//CAMAILIN DD *
WTO
ROUTCDE=(1,3,5,11)
TEXT
This is a test WTO sent from &SYSID& on &SYSDATE& to show the value of the &TMSCOPY_DATE_OF_LAST_BACKUP& variable.
/*

The following example shows a test WTO with a list of members. All the members must be in the CAI.SEND data set:

//CAMAILIN DD *
EMAIL001, MAIL2RB
MAIL0050
WTO045
/*

Note: For more information about constructing an email, see the Administration Guide.