IBM Support

Running a Full System Save or SAVSYS in Restricted State Batch

Technote (troubleshooting)


Problem(Abstract)

This document describes how users can run a full system save in batch mode

Resolving the problem

Starting at V5R3M0, it is now possible to run batch jobs to the controlling subsystem (i.e. QCTL) in a restricted state. The intent is to run scheduled restricted state saves without a console. To do this, the ENDSBS command has a new BCHTIMLMT parameter.

The Batch time limit (BCHTIMLMT) parameter is new in V5R3M0. With this parameter, you can have a CL program that requires a restricted state save. For this to occur, the job must be submitted to a job queue that is released and assigned to the controlling subsystem as it is the only active subsystem when the system is in a restricted state (this example is submitting the job to job queue QCTL in library QSYS). In the CL, on the ENDSBS command, you should use the Batch time limit parameter to specify the maximum amount of time for the save to run. If the save does not complete in this amount of time, the save is ended and the system is brought back up. Specify *NOMAX so that there is no time limit for the save. The system remains in the restricted state until the job ends, the Start Subsystem (STRSBS) command is used, or the Dedicated Service Tools (DST) option to end batch restricted state is used.

Caution: The following example is provided as is. It has not been extensively tested and might not handle all errors. No warranty is expressed or implied. If assistance is required to create a CLP program, this is considered a consulting service.

Example
1. Create a CLP.

PGM
     
ENDHOSTSVR *ALL
     ENDTCPSVR *ALL
     DLYJOB DLY(300)
     ENDTCP                                        
ENDSBS SBS(*ALL) OPTION(*IMMED) BCHTIMLMT(*NOMAX)
DLYJOB DLY(180)
SAVSYS DEV(TAP01)
SAVLIB LIB(*NONSYS) DEV(TAP01) ACCPTH(*YES)
SAVDLO DLO(*ALL) DEV(TAP01)
SAV DEV('/QSYS.LIB/TAP01.DEVD') OBJ(('/*') ('/QSYS.LIB' *OMIT) ('/QDLS' *OMIT)) UPDHST(*YES
 STRSBS SBSD(QCTL)
ENDPGM    


Note: The CLP above is very basic and is saving to device TAP01. Modifications to the CLP, such as ending applications and TCP prior to ending the subsystems and monitoring for messages, may be advantageous for a customer environment.
2. Submit this program as a batch job to QCTL subsystem:

SBMJOB CMD(CALL PGM(LIBRARY/CLP)) JOB(xxx) JOBQ(QCTL)

While the save is running, the following SRCs will be displayed:

SRCA9003C60 is when console gets removed and restricted state happens.
SRCA9003C70 is when save is taking place.

Notes:
1. It is not possible to answer messages when the restricted state save is running, so if you specify BCHTIMLMT(*NOMAX) the job will never end if there is a message waiting to be answered.
2. While the save is running, the console will be blank and inaccessible except to force DST.
3. While the system is in batch restricted state, SRCA9003C70 is displayed on the operator panel, and the attention light will be on. If the job is still in restricted state when the specified time limit (BCHTIMLMT) is reached, the batch job is ended and the controlling subsystem is restarted.
4. To cancel a restricted state batch save, force DST (Option 21 from the operator panel), and select Option 14 - End Restricted State Batch.
5. Consider adding a MONMSG(CPF000 CPD0000) to the CL to monitor for error conditions.
6. After running a restricted state batch save, the controlling subsystem is automatically started by the operating system when the system comes out of batch restricted mode. When the controlling subsystem is started, the default startup program will be called. If needing the system in a restricted mode after the backup, the startup program will have to be changed before running restricted mode batch saves. If a subsystem is not started, no display will be available.


Cross reference information
Segment Product Component Platform Version Edition
Operating System IBM i 7.2
Operating System IBM i 7.1
Operating System IBM i 6.1
Operating System IBM i 7.3

Historical Number

402662951

Document information

More support for: IBM i
Save/Restore

Software version: 5.3.0, 5.3.5, 5.4.0, 5.4.5, 6.1, 6.1.0, 6.1.1, 7.1, 7.1.0, 7.2, 7.2.0, 7.3

Operating system(s): IBM i

Reference #: N1015176

Modified date: 15 October 2012