Page 1 of 2

Execute REXX code immediately after IPL.

PostPosted: Sat Jan 18, 2014 7:58 pm
by abyvarghes
Dear All,

I have requirement to execute a peace of REXX code immediately after every IPL of systems.We were doing it before schedule it trough a Batch job. But now we need to do it after every IPL even before our scheduler (TWS/OPC) comes UP.

Thanks,
Aby

Re: Execute REXX code immediately after IPL.

PostPosted: Sat Jan 18, 2014 9:35 pm
by steve-myers
How soon after the IPL? You must realize an IPL is not really a unitary event.
  • The IPL itself just loads and starts execution of a program I will call the IPL program for the time being. Once the IPL program starts executing the IPL as such is complete.
  • The IPL program loads the basic operating system kernal. The IPL program cannot use any operating system kernal services. The IPL program is size constrained; it must fit on cylinder 0, track 0 and share that track with other data.
  • Once the kernal has been loaded the IPL program starts a piece of the kernal called the Nucleus Initialization Program, or NIP as it commonly called. NIP prepares the tables required for at least partial virtual storage usage and builds other system control blocks required for normal system operation. Once NIP completes it starts the master scheduler.
  • The master scheduler starts more of the basic operating system. I think enough of the system is loaded so that Rexx can run at this point, but I'm not sure about that.
  • The master scheduler starts the major subsystems such as the security server (e.g., RACF/ACF2/Top Secret), perhaps automated operations and JESx (though automated operations may start JESx). Once JESx is started, more critical services, such as TCPIP, and VTAM can start.
  • Once VTAM is running, the remaining services can start.
This is not really a topic suitable for a beginners's forum. What do you propose this Rexx program is to do?

Re: Execute REXX code immediately after IPL.

PostPosted: Sat Jan 18, 2014 9:52 pm
by abyvarghes
steve-myers wrote:How soon after the IPL? You must realize an IPL is not really a unitary event.
  • The IPL itself just loads and starts execution of a program I will call the IPL program for the time being. Once the IPL program starts executing the IPL as such is complete.
  • The IPL program loads the basic operating system kernal. The IPL program cannot use any operating system kernal services. The IPL program is size constrained; it must fit on cylinder 0, track 0 and share that track with other data.
  • Once the kernal has been loaded the IPL program starts a piece of the kernal called the Nucleus Initialization Program, or NIP as it commonly called. NIP prepares the tables required for at least partial virtual storage usage and builds other system control blocks required for normal system operation. Once NIP completes it starts the master scheduler.
  • The master scheduler starts more of the basic operating system. I think enough of the system is loaded so that Rexx can run at this point, but I'm not sure about that.
  • The master scheduler starts the major subsystems such as the security server (e.g., RACF/ACF2/Top Secret), perhaps automated operations and JESx (though automated operations may start JESx). Once JESx is started, more critical services, such as TCPIP, and VTAM can start.
  • Once VTAM is running, the remaining services can start.
This is not really a topic suitable for a beginners's forum. What do you propose this Rexx program is to do?


Thanks a lot Steve for the reply. My REXX issue a Console display command (Eg: D IPLINFO) and the out put will get stored in a PS file. In our environment we start AOC (Automation) when all the above steps you mentioned went fine . then we start AOC , the AOC will start all other subsystems and applications like OPC/ TWS etc. But How can I get my peace of code get executed , before AOC starts ?

Re: Execute REXX code immediately after IPL.

PostPosted: Sat Jan 18, 2014 10:34 pm
by enrico-sorichetti
did You care to look at the manuals for the output of the D IPLINFO ?
its content is pretty static and does not change with time.
after all the command syntax tells ...
so You will get the same info every time You issue the command
so having it processed after automation has started
will not make too much difference !

Re: Execute REXX code immediately after IPL.

PostPosted: Sat Jan 18, 2014 10:56 pm
by abyvarghes
enrico-sorichetti wrote:did You care to look at the manuals for the output of the D IPLINFO ?
its content is pretty static and does not change with time.
after all the command syntax tells ...
so You will get the same info every time You issue the command
so having it processed after automation has started
will not make too much difference !


Thanks enrico for your reply. As you said the value will not change. But if we do IPL multiple times in same day .(It will not happen in Production ) . We do IPL test systems multiple times for testing and training purpose in our environment. So our management wants to keep the IPL Time and Date and few other values from IPLINFO in a PS file as a record to know how many times the system is IPLed.
Or , is there any way we can get the information how many times and the time a system is been IPL'ed in a month or more ?

We were doing it manually updating a PS file with D IPLINFO after every IPL. But I thought , get it done automated. Just to learn REXX also by doing these kind of things.

My only requirement is to execute my code before AOC or OPC starts.

Re: Execute REXX code immediately after IPL.

PostPosted: Sat Jan 18, 2014 11:10 pm
by Robert Sample
Why not use the data IBM provides for you? From the System Management Facility (SMF) manual:
13.4 Record Type 0 (00) -- IPL
Record type 0 is written after every SMF initialization. It includes the virtual and central storage sizes and some of the SMF options in effect. See record type 90 (subtype 9) for information about the IPL of SMF.

Re: Execute REXX code immediately after IPL.

PostPosted: Sat Jan 18, 2014 11:11 pm
by enrico-sorichetti
My only requirement is to execute my code before AOC or OPC starts.


WHY ?

Re: Execute REXX code immediately after IPL.

PostPosted: Sun Jan 19, 2014 2:39 am
by steve-myers
I agree with Mr. Sorichetti and Mr. Sample: use the data that's already there. The only fault with the SMF 0 record is the time is too late, though it is close enough for your purposes. Compared with many SMF records, the SMF 0 record is very simple and easy to analyze, though not in Rexx.

Re: Execute REXX code immediately after IPL.

PostPosted: Mon Jan 20, 2014 8:23 pm
by nevilh
Is this not what the COMMNDxx member in Parmlib is for

Re: Execute REXX code immediately after IPL.

PostPosted: Fri Jan 24, 2014 4:02 pm
by abyvarghes
nevilh wrote:Is this not what the COMMNDxx member in Parmlib is for

Sorry for late reply.

Can you tell me what command I need to place in COMMANDXX to trigger a PDS member ( my rexx code).
I meant the syntax. I know that syntax should be same as console command syntax. But how or what command to execute a Rexx code form console.?

Thanks,