HP3000-L Archives

May 2006, 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:
Paul H Christidis <[log in to unmask]>
Date:
Wed, 10 May 2006 11:00:55 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (72 lines)
Robert,

You could try the following:

!setvar _ExecCount 0
!if SETVAR(_JobCount, JOBCNT('@J:!hpjobname,!hpuser.!hpaccount', 
_JobList)) > 1 then
!  setvar idx 0
!  while SETVAR(idx, idx + 1) <= _JobCount OR _ExecCount < 2 do
!     if JINFO("![WORD(_JobList, ,idx)]", "State") = "EXEC" then
!       setvar _ExecCount _ExecCount + 1
!     endif
!  endwhile
!endif
!if _ExecCount > 1 then
!  tellop WARNING: Job is already running. I'm terminating.
!  eoj
!endif

You may have to change "!hpjobname,!hpuser.!hpaccount" unless ALL these 
'copy' jobs do log-on with the same jobcard.

Regards
Paul Christidis

-----------------

HP-3000 Systems Discussion <[log in to unmask]> wrote on 05/10/2006 
03:31:49 AM:

> We have loads of jobs that would cause damage if more than one copy was
> run. To prevent this we have the following code at the start of them:
> 
>   !if jobcnt('jobname,user.account') > 1 then
>   !  tellop WARNING: Job is already running. I'm terminating.
>   !  eoj
>   !  endif 
> 
> A couple of system problems has resulted in a large backlog of jobs
> waiting to run. One of our jobs is never getting passed the above check
> because by the time it moves from WAIT to EXEC our scheduler has
> streamed the next copy which joins the WAIT queue.
> 
> One way I can see around this is to do the following instead (we have
> MPEX):
> 
>   !setjcw mpexfaststart 1
>   !mpex
>   %if jscount('jobname,user.account&EXEC') > 1 then
>   %  tellop WARNING: Job is already running. I'm terminating.
>   %  eoj
>   %  endif 
>   %exit
>   !setjcw mpexfaststart 0
> 
> Anybody have a method that would work with vanilla MPE (our D/R box does
> not have MPEX)?
> 
> 
> regards, 
> 
> Robert W.Mills 
> MIS Systems Development Manager 
> Windsong Services 
> +44 (0)20 8309 3604 
> 
> * To join/leave the list, search archives, change list settings, *
> * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2