Interested in opinions on best method to execute either a RULE or OPS/REXX routine just one time as the system is coming back up from an IPL.
Consider review CA OPS/MVS parameters AOFINITREXX and AOFACTIVEREXX.
Review the considerations documented for both parameters in this documentation link:
Share with us what kind of processing you are interested to execute.
There are other places where you could also execute during the IPL of the OPSMAIN Address Space.
Those parms are just for OPS/MVS startup. Think he is looking for LPAR IPL. INITREXX can be used to initialize some variables for the process. Although OPS is usually started at IPL and stays up until system shutdown - need to consider that OPS/MVS could be recycled without an IPL for some reason. This may/may not require different process, depending on your needs. You may need to use some flags/globals to keep track that something has run once since IPL, so don't use TEMP globals. . Maybe the globals would have reference to OPSINFO('IPLTIME') and OPSINFO('IPLDATE') to help determine if it has already fired since last IPL?
I'm sure there are other ways.
Various methods as Sal has pointed out. One method would be to have a rule auto-enabled with just an )INIT section that checks if OPS is initializing for the first time (assumes first start after IPL) and then issues the 'desired' work. Refer to hlq.CCLXRULS(IPLTIME) as a sample...Another method if utilizing SSM is to query the IPL parm that is internally passed to the SSMBEGIN startup rule . Parm is set to Y if OPS was just started after an IPL.
I use the OPS0123O (AOF Initialization Complete) message to key off an IPL. Within the rule I use OPSINFO('PRODUCTSTARTS') to tell how many times CA-OPS has been started since IPL. If it is one then we assume it is an IPL. If it is more than 1 we assume it is a restart and then go from there. I have a REXX which collects the IPL information at this time and sends me an e-mail each time one of our systems is IPL'ed. It also records this in a reference file for use at Disaster Recovery if needed. One caveat that I did find in using this is depending on what you use to send the e-mail (I use JES2MAIL) and how much of your system is up when AOF Initialization is complete, it may be tricky to send an e-mail immediately. Since the information I want doesn't change until the next IPL anyway, I have a dynamic TOD rule to wait for 10 minutes (TOD *+10 MIN) before sending the e-mail.
I decided on OPS0123O because it was the first point that you could safely execute a rule
Travi, that is what we use also, OPS0123O.