HP3000-L Archives

April 1995, Week 2

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
"Paul H. Christidis" <[log in to unmask]>
Reply To:
Date:
Mon, 10 Apr 1995 15:38:43 PST
Content-Type:
text/plain
Parts/Attachments:
text/plain (134 lines)
>>On Mon, 10 Apr 1995, Chris Michael wrote:
 
>>I have two remote sites where we've set up backups to run as jobs
>>automatically--all the people there have to do is remember to put in a tape.
>>Unfortunately when they forget the backup runs, locks all the files, and then
>>patiently waits.  When the users get in in they can't work--then I get a
>>wakeup call.  Since one of the sites is Milan, the wakeup call is about 2am.
>>
>>Is there any way to test for the presence of a tape (scsi dat) mounted from a
>>job stream?  With roadrunner, since I can append multiple backups to the same
>>tape, I can do a backup on an unimportant fileset first.  If it hangs, at
>>least the whole system isn't locked--but there's got to be a more elegant
>>solution.
>>
>>Chris
>>--
>>christopher michael, george s. may international, 708-825-8806 x 395
>
>Hi,
 
>Another solution:  Abort the backup if it takes more than a predetermined
>amount of time.  When my backup signs on, it immediately streams another
>job, using the in= parm.  When the backup finishes, it aborts the
>pending ABORTER job.
 
>--john sullivan
 
>[log in to unmask]  http://www.interex.org/~sullivan/
>irc: irc.interex.org  phone: 408 747 0227
 
In the same direction as john's suggestion you could try the following:
 
<<Text of sample 'backup' stream file >>
 
!job backup,.....
! ...
! ...
!comment
!comment  Setup a file to 'pass' the needed data to the monitor job
!comment
!purge Bkupfile
!build Bkupfile;rec=-72,,f,ascii
!file BK=Bkupfile,old
!setvar backuptape "BACK001"
!echo setvar backuptape "!!backuptape"  > *BK
!echo setvar backupjob  "#J!hpjobnum"  >> *BK
!
!stream monitorj
!comment
!comment  Give time to the 'monitor' job to logon and setup
!comment
!Pause 60
!
!file t = !backuptape
!store @[log in to unmask]@;*t;.....
!
!eoj
 
<<Text of sample 'monitor' stream file >>
!job monitorj,......
! ...
!comment
!comment 'Receive' the 'passed' info from the backup job
!comment
!xeq Bkupfile
!showvar backup@
!comment  Set some environment variables
!
!setvar initial_delay  600
!comment  Wait !init_delay seconds to allow the backup job to 'lock'
!comment  the files of the file set being stored.
!comment
!setvar iterations     5
!setvar delay         600
!
!Pause !initial_delay
!build rcfile;rec=-100,,f,ascii;msg;temp
!file rc=rcfile,oldtemp
!setvar loop 0
!setvar g_reply_pending  0
!setvar loop_done      false
!setvar replied        false
!while loop < iterations  AND  NOT loop_done
!  setvar loop   loop + 1
!  echo *** LOOP # !loop ***
!  echo *** Recall Start *** > *rc
!  recall >> *rc
!  echo *** Recall End   *** >> *rc
!  setvar loop2  0
!  setvar recall_size finfo("*rc",'eof') - 1
!  setvar reply_pending  0
!  while loop2 < recall_size
!    setvar loop2  loop2 + 1
!    input recall_text;wait=2  < *rc
!    if pos(backuptape,recall_text) <> 0 then
!       setvar reply_pending reply_pending + 1
!    endif
!  endwhile
!
!  if reply_pending = 0 then
!     if g_reply_pending <> 0 then
!        setvar replied   true
!        setvar loop_done true
!     endif
!  else
!     setvar g_reply_pending g_reply_pending + 1
!  endif
!
!  if NOT replied then
!     Pause !Delay
!  endif
!endwhile
!
!if NOT replied AND g_reply_pending > 0 then
!   abortjob !backupjob
!endif
!eoj
 
The above will 'loop' a configurable number of times checking to see if a
tape request by the 'backup' job was replied to.  If the operator does NOT
reply within the indicated time it will abort the backup job.
 
I have one concern though.  If the 'backup' job gets aborted do the files
that had their 'store bit' turned on get released?   You should verify that
before using the above.
 
It may be safer to use some type of CI logic along the lines of the above
stream file to determine if the tape is mounted before the 'backup' job is
streamed.
 
Regards
 
Paul H. Christidis  -- [log in to unmask]

ATOM RSS1 RSS2