|
At 05:48 PM 11/4/98 +1300, you wrote: >At 09:43 2/11/98 -0500, you wrote: >> > >I'd be interested to hear what you have done. I have a 3570.. (*IS* that >magstar tape drive ?) Yes, but there are several models of the Magstar 3570 Tape Subsystem. The following was done on a Model C01 (Library Model) set to "Random" via the control l panel option menu. I believe it would work also on C02, C11 and C12. But, not Model C00. | This is what I have done, concocted, developed and stumbled across in relation ship to a Magstar tape drive. Or more specifically managing one without buying tape management software. One of the things I have yet to understand is the relationship of the CATEGORY of the tapes in the drive to the function of the tape drive. I have read the manuals but I do not grasp it's purpose and how it would or could be used. Much of the following could be improved upon. However, it was put together on a trial basis and (as usual) there has never been enough time to go back and clean up, optimize, etc. Alligators by themselves do not count. Only alligators that are on fire warrant attention. There are many things that interact upon this procedure that are unique to my operation that I have not included. This backup procedure is based on a two-week cycle. There are 14 tapes. Each day of the week has two tapes I.D. with the first three characters of the day plus a 4th character of # or @. This makes one week the "pound week" and the next week the "at week." Example: SUN# and SUN@. There are 10 carrying cases labeled MON# through FRI# and MON@ through FRI@. Mondays case carries both Sunday and Monday tapes. Friday's case carries both Friday and Saturday tapes. Tapes are loaded 3 to 4 days in advance of their use. The other tapes are kept off site. Every morning the previous night's tapes are removed and carried off site. Outline: 1. Set up the tape drive as a library device as TAPLIB 2. Initialize the tapes with the cartridge I.D. and the volume I.D. set to the serial number on the bar code label on each tape. 3. Create physical file TAPEFILE A* FILE OF THE TAPES USED IN THE BACKUP A*---------------------------------------------------------------- A UNIQUE A*---------------------------------------------------------------- A R TAPE001 TEXT('TAPE REGISTERY') A*---------------------------------------------------------------- A CARTID 6 TEXT('CARTRIDGE I.D.') A VOLID 6 TEXT('TAPE VOLUME I.D.') A DOW 3 TEXT('DAY OF WEEK CYCLE') A CYCLE 1 TEXT('CYCLE WEEK I.D.') A LCYMD 8 0 TEXT('DATE OF LAST SAVE') A SORT 2 TEXT('SORT SEQUENCE') A*---------------------------------------------------------------- A K CARTID 4. Load the information into the file via DFU. 5. Create command TAPUNLD that runs CL TAPEUNLOAD PGM /* Unload any tape loaded */ DCL VAR(&JOB) TYPE(*CHAR) LEN(10) /* Job name */ DCL VAR(&USER) TYPE(*CHAR) LEN(10) /* Job user */ DCL VAR(&NBR) TYPE(*CHAR) LEN(6) /* Job number */ DCLF FILE(*LIBL/TAPES) /* List of Tapes */ DLTF FILE(QTEMP/TAPES) /* Delete file */ MONMSG MSGID(CPF2105) /* Not there */ DSPTAPCTG DEV(TAPLIB) CGY(*ALL) OUTPUT(*OUTFILE) OUTFILE(QTEMP/TAPES) READ: RCVF /* Get a record */ MONMSG MSGID(CPF0864) EXEC(GOTO CMDLBL(THEEND)) /* + End of File */ IF COND(&RDLOC *EQ 'TAP01 ') THEN(DO) DMPTAP DEV(TAPLIB) VOL(&RDMID) ENDOPT(*UNLOAD) MONMSG MSGID(CPF6723) EXEC(GOTO CMDLBL(THEEND)) /* + No file */ RTVJOBA JOB(&JOB) USER(&USER) NBR(&NBR) /* Job I.D. */ DLTSPLF FILE(QPTAPDMP) JOB(&NBR/&USER/&JOB) + SPLNBR(*LAST) /* Remove the printout */ ENDDO GOTO CMDLBL(READ) THEEND: ENDPGM 6. Create a data area (TAPECYCLE) of 1 byte and load it with "#" or "@." 7. Create an RPG program that runs after midnight Saturday that switches the "#' or "@" in the TAPECYCLE data area. 7. Create a daily save CL and execute it automatically ever night just before midnight. PGM /* Daily save */ DCL VAR(&XDAY) TYPE(*CHAR) LEN(4) DCL VAR(&DAY) TYPE(*CHAR) LEN(3) DCL VAR(&CYCLEID) TYPE(*CHAR) LEN(1) /* Cycle I.D. */ DCL VAR(&TEXT01) TYPE(*CHAR) LEN(30) DCL VAR(&TEXT02) TYPE(*CHAR) LEN(30) + VALUE('Could not be found on T1 drive') DCL VAR(&TEXT03) TYPE(*CHAR) LEN(30) + VALUE('Could not be ejected! ') DCLF FILE(JLQGPL/TAPEFILE) /* List of Tapes */ CHGJOB OUTQ(ISMGROQ) /* My OUTQ */ WHAT_DAY: RTVSYSVAL SYSVAL(QDAYOFWEEK) RTNVAR(&XDAY) /* *DAY */ CHGVAR VAR(&DAY) VALUE(%SST(&XDAY 2 3)) RTVDTAARA DTAARA(JLQGPL/TAPECYCLE) RTNVAR(&CYCLEID) /* + Cycle I.D.; # or @ */ READ: RCVF /* Get a record */ MONMSG MSGID(CPF0864) EXEC(GOTO CMDLBL(NOTFOUND)) + /* End of File */ IF COND(&DOW *EQ &DAY *AND &CYCLEID *EQ &CYCLE) + THEN(GOTO CMDLBL(FOUND)) GOTO CMDLBL(READ) FOUND: TAPUNLD /* Unload TAPLIB if loaded */ ADDTAPCTG DEV(TAPLIB) CTG(&CARTID) MONMSG MSGID(CPF67AB CPF67D2) EXEC(DO) CHGVAR VAR(&TEXT01) VALUE(&CARTID) /* # of tape */ CALL PGM(SENDMEMO02) PARM('WAYNEMP ' &TEXT01 + &TEXT02) RETURN /* Error Exit */ ENDDO CHKTAP DEV(TAPLIB) VOL(&VOLID) /* Load tape */ MONMSG MSGID(CPF412C) EXEC(DO) /* Not found */ CHGVAR VAR(&TEXT01) VALUE(&CARTID) /* # of tape */ CALL PGM(SENDMEMO02) PARM('WAYNEMP ' &TEXT01 + &TEXT02) RETURN /* Error Exit */ ENDDO INZTAP DEV(TAPLIB) NEWVOL(&VOLID) VOL(&CARTID) + CHECK(*NO) RMVM FILE(JLQGPL/TAPESAVEL1) MBR(*ALL) SAVLIB LIB(*ALLUSR) DEV(TAPLIB) VOL(&VOLID) + ENDOPT(*REWIND) SAVACT(*SYNCLIB) + OMITOBJ((JLQGPL/TAPESAVE *FILE)) MONMSG MSGID(CPF3777) /* Not all *lib saved */ CALL PGM(TAPEDATSET) PARM(&CARTID) /* Update date */ ADDRPYLE SEQNBR(4011) MSGID(CPA401E) RPY(C) /* Set + the reply list to (C)ancel if there is a + tape in the way */ MONMSG MSGID(CPF2555) /* Already defined */ CHGJOB INQMSGRPY(*SYSRPYL) /* Allow reply list + entry to be used to reply to CPA401E */ RMVTAPCTG DEV(TAPLIB) CTG(&CARTID) STATION(*CNV) MONMSG MSGID(CPF67E4) EXEC(DO) CHGVAR VAR(&TEXT01) VALUE(&CARTID) /* # of tape */ CALL PGM(SENDMEMO02) PARM('WAYNEMP ' &TEXT01 + &TEXT03) ENDDO RMVRPYLE SEQNBR(4011) /* Remove 4011 from reply list */ MONMSG MSGID(CPF2556) /* Not there! */ NOTFOUND: SBMJOB CMD(CALL PGM(JLQGPL/TAPE_ERROR)) + JOB(TPAE_LOG) JOBQ(QS36EVOKE) THEEND: ENDPGM -************************** G. Wayne Calvert Information Systems Manager JacksonLea A unit of Jason Incorporated APICS CPIM certified jacklea@jacksonlea.com http://www.jacksonlea.com (800) 439-9304 x 3314 (828) 464-1376 x 3314 (828) 464-7094 Fax *************************** +--- | This is the Midrange System Mailing List! | To submit a new message, send your mail to MIDRANGE-L@midrange.com. | To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com. | To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: david@midrange.com +---
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.