CL PGM for full system save from the HMC

3175 pts.
Tags:
Administration
Backup
iSeries
System info: OS/6.1, 9117-MMB-770. Can you run a full system save from the HMC in a CL pgm? here is my code so far: PGM DCL VAR(&DATE) TYPE(*CHAR) LEN(6) DCL VAR(&TAPE) TYPE(*CHAR) VALUE(TAP02) CHGJOB RUNPTY(19) JOBQ(QSYS/QCTL) LOG(0 00 *SECLVL) + LOGCLPGM(*YES) BRKMSG(*NOTIFY) + TIMESLICE(99999) CHGMSGQ MSGQ(*USRPRF) DLVRY(*HOLD) MONMSG MSGID(CPF2451) CHGMSGQ MSGQ(*WRKSTN) DLVRY(*NOTIFY) RTVSYSVAL SYSVAL(QDATE) RTNVAR(&DATE) ENDSBS SBS(*ALL) OPTION(*CNTRLD) DELAY(30) + BCHTIMLMT(7777) MONMSG MSGID(CPF0968) /* System ended to restricted + condition. */ INZTAP DEV(&TAPE) NEWVOL(&DATE) + NEWOWNID(TSTSYSSAV) CHECK(*NO) DLYJOB DLY(300) SAVSYS DEV(&TAPE) ENDOPT(*LEAVE) SAVLIB LIB(*NONSYS) DEV(&TAPE) ENDOPT(*LEAVE) + ACCPTH(*YES) SAVDLO DLO(*ALL) FLR(*ANY) DEV(&TAPE) ENDOPT(*LEAVE) SAV DEV('qsys.lib&TAPE.devd&TAPE') OBJ(('/*') + ('/QSYS.LIB' *OMIT) ('/QDLS' *OMIT)) + ENDOPT(*REWIND) UPDHST(*YES) DSPTAP DEV(&TAPE) OUTPUT(*PRINT)

Software/Hardware used:
Os/6.1, 9117-MMB-770

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Discuss This Question: 1  Reply

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • TomLiotta
    Sure, you could do it; but why would anyone want to?   Now, there are a couple fundamental problems with your code.   First, you didn't specify a job name in your CHGJOB statement. You have the JOBQ() parameter, but that is only meaningful against a job that is currently on a jobq. You can't change the jobq of the current job, so a job name must be supplied and it must be for a different job.   Second, you ran ENDSBS *ALL with no error handling at all -- you merely ignore a particular condition. You risk putting your system into an unuseable state until you can force an IPL. Further, you don't test to see if restricted state has been achieved; you jump straight to your saves. It's almost guaranteed that restricted state will take a couple minutes or so to arrive. By that time, your SAVSYS command will probably already have failed. Your INZSYS command might take long enough, but it can't be expected.   That's about all that can be said for now.   Tom
    125,585 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following