I will tell step by step how to create a subsystem , jobqueue, userprofile and job description.
First we will create a job description. The job description will be used by the subsystem to start the autostart job. (I will explain later why we need a autostart job.)
Create jobqueue(notice you can set up a library list for the job.
Now we a userprofile for this example I chose ATLANTIS.
see I have attached the jobdescription ATLANTIS here also,
with the value PWDEXP you will be prompted at signon to change the current password.
Create a subsystem- this is where the autostart job will run.
Create a job queue to feed the subsystem created above.
Now we add a jobqueue entry to attach the subsystem and jobqueue.
Add routing entry so our jobs will run. (I borrowed QBATCH -CLASS)
Now we have our subsystem
To start a subsystem automatically you need to add this to the startup program.
To find this you use command
WRKSYSVAL QSTRUPPGM
As in this example the start up program is QSTRUP in library QSYS.
This is a CLP program. You must use the RTVCLSRC command to get the source. Then just add to the source
STRSBS ATLANTIS/ATLANTIS
MONSMG CPF0000
and recompile the program back into library QSYS.
Now when the box is IPLed the subsytem will start automatically.
Getting diveline to run in subsystem ATLANTIS
First we will create a job description. The job description will be used by the subsystem to start the autostart job. (I will explain later why we need a autostart job.)
Create jobqueue(notice you can set up a library list for the job.
Code:
CRTJOBD JOBD(ATLANTIS/ATLANTIS) JOBQ(ATLANTIS/ATLANTIS) TEXT('dimensional Insight default job description') INLLIBL(QTEMP QGPL ATLANTIS)
see I have attached the jobdescription ATLANTIS here also,
with the value PWDEXP you will be prompted at signon to change the current password.
Code:
CRTUSRPRF USRPRF(ATLANTIS) PASSWORD(ATLANTIS) PWDEXP(*YES) USRCLS(*PGMR) CURLIB(ATLANTIS) TEXT('Dimensional Insight default profile') JOBD(ATLANTIS)
Code:
CRTSBSD SBSD(ATLANTIS/ATLANTIS) POOLS((1 *BASE)) TEXT('dimensional Insight subsystem')
Code:
CRTJOBQ JOBQ(ATLANTIS/ATLANTIS) TEXT('Dimensional Insight Job Queue')
Now we add a jobqueue entry to attach the subsystem and jobqueue.
Code:
ADDJOBQE SBSD(ATLANTIS/ATLANTIS) JOBQ(ATLANTIS/ATLANTIS) MAXACT(*NOMAX)
Add routing entry so our jobs will run. (I borrowed QBATCH -CLASS)
Code:
ADDRTGE SBSD(ATLANTIS) SEQNBR(9999) CMPVAL(*ANY) PGM(QSYS/QCMD) CLS(QBATCH)
To start a subsystem automatically you need to add this to the startup program.
To find this you use command
WRKSYSVAL QSTRUPPGM
Code:
Display System Value System value . . . . . : QSTRUPPGM Description . . . . . : Startup program Startup program . . . . . . : QSTRUP Name, *NONE Library . . . . . . . . . : QSYS Name
This is a CLP program. You must use the RTVCLSRC command to get the source. Then just add to the source
STRSBS ATLANTIS/ATLANTIS
MONSMG CPF0000
and recompile the program back into library QSYS.
Now when the box is IPLed the subsytem will start automatically.
Getting diveline to run in subsystem ATLANTIS
Code:
* * SBMJOB CMD(CALL PGM(ATLANTIS/DVLNSVR) PARM(ATLANTIS ' ' )) * JOB(DIVER) JOBD(ATLANTIS/ATLANTIS) JOBQ(atlantis/ATLANTIS) * USER(ATLANTIS) *
Comment