Calling a special IPL recovery program
To call a special recovery program for situations when the IPL senses that the previous system ending was abnormal, you can add an autostart job entry to the subsystem description for the controlling subsystem. This program checks the Previous system ending status (QABNORMSW) system value . For a normal system ending, the value of QABNORMSW is ’0’, and for an abnormal system ending the value of QABNORMSW is ’1’. An alternative is to drop the messages and start up other subsystems when your recovery function is complete.
1.00 /* SPCRECOV - Autostart program to call special recovery program */ 2.00 PGM 3.00 DCL &QABNORMSW *CHAR LEN(1) 4.00 RTVSYSVAL SYSVAL(QABNORMSW) RTNVAR(&QABNORMSW) 5.00 IF (&QABNORMSW *EQ '1') DO /* Recover */ 6.00 SNDPGMMSG MSG('Recovery program in operation-do not + 7.00 start subsystems until notified') + 8.00 TOMSGQ(QSYSOPR) 9.00 CALL RECOVERY 10.00 SNDPGMMSG MSG('Recovery complete-jobs may be started') + 11.00 TOMSGQ(QSYSOPR) 12.00 ENDDO /* Recover */ 13.00 ENDPGM
Parent topic:
Managing work