Page 1 of 1

HRECALL Ignoring WAIT Parm

PostPosted: Fri Mar 07, 2014 3:14 am
by gmosley
I have a utility that needs to allocate files before it can run.
I do an HRECALL with the WAIT option and messages suppressed so that I can make sure the file is available (before checking if it exists) before attempting to allocate. That way the user shouldn't be interrupted at all or forced to re-start.
Here's the code I use:

msgstat = MSG('off')                     
"HRECALL ('"tdsname"') WAIT"             
msgrset = MSG(msgstat)                   
If sysdsn("'"tdsname"'") ¬= 'OK' Then   
  Do                                     
    zerrtp = 'ACTION'                   
    zerrsm = 'ALLOC error'               
    zerrlm = tdsname 'could not be found'
    "SETMSG MSG(ISRZ003)"               
    Return 8                             
  End

Unfortunately, I'm not suppressing anything it seems. Here's what I get when I attempt to process an SMS archived file:

ARC0612I VOLUME MOUNT ISSUED FOR RECALL OR RECOVER OF DEVSUP.TESTDBT.TRIB.OUTF
>V> "DEVSUP.TESTDBT.TRIB.OUTF"
>O> "'DEVSUP.TESTDBT.TRIB.OUTF"
>L> "'"
>O> "'DEVSUP.TESTDBT.TRIB.OUTF'"
ARC1020I DFSMSHSM IS RECALLING FROM TAPE DSN=DEVSUP.TESTDBT.TRIB.OUTF, PLEASE RETRY
THE USER REQUEST AFTER THE RECALL HAS COMPLETED.

Re: HRECALL Ignoring WAIT Parm

PostPosted: Fri Mar 07, 2014 4:01 am
by dick scherrer
Hello,

This does not answer your question directly, but if you use DEFER mount, it may help your situation.

Re: HRECALL Ignoring WAIT Parm

PostPosted: Fri Mar 07, 2014 4:12 am
by gmosley
Actually, I figured out the problem right after posting but couldn't see any way to delete my original.

I was flipping between Address ISPEXEC and Address TSO mode and was inadvertently in ISPEXEC mode when I issued the HRECALL. Embarrassing...

Re: HRECALL Ignoring WAIT Parm

PostPosted: Fri Mar 07, 2014 4:19 am
by Pedro
I cannot explain why.

After the HRECALL, you should try 'z= LISTDSI(my.dsn)'. The advantage is that when LISTDSI ends, it will have a value in SYSVOLUME. If the volid is still MIGRAT, issue a SLEEP 5 and try LISTDSI again in five seconds.

LISTDSI has a RECALL parameter, but it clearly states that it will recall only if it is migrated to DASD. Perhaps HRECALL has some similar verbage somewhere. Is it the case where your dataset is on a tape?

Re: HRECALL Ignoring WAIT Parm

PostPosted: Fri Mar 07, 2014 4:40 am
by gmosley
Unfortunately, in spite of my attempt to suppress messages, the following appears:

ARC0612I VOLUME MOUNT ISSUED FOR RECALL OR RECOVER OF DEVSUP.TESTDBT.DTSF

At least it pauses there, though, meaning when it resumes, the dataset has been retrieved and my logic that confirms the existence of the dataset succeeds.

Message is annoying, though.

Re: HRECALL Ignoring WAIT Parm

PostPosted: Fri Mar 07, 2014 4:59 am
by steve-myers
At one level, I agree with you. On the other hand, if HSM is going to mount a tape to do the recall, it leaves the terminal user stuck with a dead workstation. The message gives the user a clue the workstation will come back to life sooner or later, which is a little better than leaving the user in complete limbo.

Re: HRECALL Ignoring WAIT Parm

PostPosted: Fri Mar 07, 2014 5:05 am
by gmosley
Actually, we use "virtual" tapes now and retrieval is never more than a few seconds.

Re: HRECALL Ignoring WAIT Parm

PostPosted: Fri Mar 07, 2014 9:34 am
by steve-myers
True. Even before virtual tape a lot of shops were using tape libraries, which also feature relatively fast mountscompared to operators going

I don't know about current HSM, but it used to be each data set was a separate file on the tape, and the spin to the appropriate file can be time consuming. In 1990 I think it was I was watching a round tape drive doing some awfully funky processing. I eventually determined it was HSM migrating stuff to the tape. The funky processing was HSM writing tape labels for a new file.