cDSCHEDULE Automated Job Submission System Guide and Reference �ManualD

SCHEDULE
Automated Job Submission System
Guide and Reference Manual



 o T Y  
PreviousContentsIndex




4

Chapter 5
An Example




?Included with the SCHEDULE System are some predefined 7calendars and a procedure to create some demonstration :jobs1. The demonstration jobs are grouped into 'subdirectories of the [DEMO] directory.

BThe jobs grouped into the [DEMO.D] subdirectory are configured to @simulate the task of the daily updating of a database. This job Csequence is divided into three groups of jobs. In brief, the first Hgroup backs up the database, the second group updates the database, and Hthe third group does the final reporting on the results of the database update.

DThe first part of this section describes the job flow for the daily Edatabase update, identifying each job and describing the function of Fthat job. The next part of this section gives the complete set of DCL Acommands to create and configure each job. The last part of this Dsection describes running the job sequence and reviewing the events that occurred during execution.

GIn this section, DCL commands will be used to illustrate how the daily >database update job sequence was created, configured, and run.



/   
N
Note

 L

1 To build the demonstration jobs, I issue the following command:@SCHEDULE_LIBRARY:SCHEDULE_DEMO.



T

5.1 Outline of job flow



>The complete job flow of the three groups of jobs is shown in FFigure 5-1 Complete Job Flow.

-Figure 5-1 Complete Job Flow




AThe first group consists of three sequential jobs to back up the Zdatabase, as shown in Figure 5-2 First Group of Jobs.

/Figure 5-2 First Group of Jobs




DEvery day at a preset time, job A1 is scheduled to be submitted and Erun. When run, job A1 checks to see if the database is available for Gupdating. If this check fails, the complete job sequence is exited. If Fthe check succeeds, job A2 is initiated. Job A2 backs up the database Dto allow for recovery from errors in the subsequent updating of the Gdatabase. When job A2 successfully completes, job A3 is initiated. Job EA3 does no operation but just serves as a return point used in error Arecovery. Since job A3 does no operation, it always succeeds and Finitiates job B1, the first job of the second group. The second group Gconsists of five sequential jobs to update the database and three jobs iused in error recovery, as shown in Figure 5-3 Second Group of Jobs.

0Figure 5-3 Second Group of Jobs




@Job B1 does the initial update of the database. Upon successful Hcompletion, job B21 is initiated to do the main update to the database. BIf this job fails, job C is initiated. Job C restores some of the Ddatabase from the backup files and then initiates jobs in the third Egroup of jobs. If job B21 succeeds, job B22 is initiated to sort the Foutput of the database update. If job B22 fails due to the disk being Hfull, job D is initiated. Job D purges files and then initiates job B22 @again. This loop continues until job B22 succeeds. Upon job B22 Csucceeding, job B23 is initiated to do the final processing in the 3database update. If this fails, job E is initiated.

FJob E completely restores the database from the backup files and then Dinitiates the last job of the first group, job A3, to start another ?pass at updating the database. If job B23 succeeds, job B24 is Finitiated. Job B24 prints out the results for the successful database :update and then initiates jobs in the third group of jobs.




 o V T Y  
PreviousNextContentsIndex