Operating System - OpenVMS
1753907 Members
8944 Online
108810 Solutions
New Discussion юеВ

Re: Starting a detached process from the batch queue

 
Peter Elliott_3
Occasional Advisor

Starting a detached process from the batch queue

Hello

I'm trying to write a DCL command file which will restart a detached process if it has stopped. I want to use the batch queue so that the check can be performed periodically. When running from the batch queue my command file can detect that the target detached process is not running and can actually restart the process, however the process fails almost immediately. Any suggestions as to why is this happening?
14 REPLIES 14
Kris Clippeleyr
Honored Contributor

Re: Starting a detached process from the batch queue

Hi Peter,
Welcome to the VMS forum.

What's the error you're getting? Anything seen in the log file of the batch job?
Please gives us some more info.

Greetz,
Kris (aka Qkcl)
I'm gonna hit the highway like a battering ram on a silver-black phantom bike...
Peter Elliott_3
Occasional Advisor

Re: Starting a detached process from the batch queue

There are no error messages in the log file. I get notification that the process has started:
%RUN-S-PROC_ID,...
but the process disappears immediately.

If I perform the same command from the DCL prompt the process starts and continues as normal.
David B Sneddon
Honored Contributor

Re: Starting a detached process from the batch queue

Peter,

Can you provide the EXACT commands you are using when
it works and when it fails along with the EXACT errors
you get?

Dave
Kris Clippeleyr
Honored Contributor

Re: Starting a detached process from the batch queue

Peter,
You kick of a detached process by specifying either the /UIC or the /DETACHED qualifier is specified with the RUN command and you have the IMPERSONATE priv. You could change the RUN command and add the /OUTPUT=file and the /ERROR=file qualifiers, so that any conditions signalled by the created process are captured.
Greetz,
Kris (aka Qkcl)
I'm gonna hit the highway like a battering ram on a silver-black phantom bike...
Antoniov.
Honored Contributor

Re: Starting a detached process from the batch queue

Peter,
welcome to VMS forum.

Batch queue can run a detached process: there are no limitation about this feature. Like you I use batch command to check and restart some detached processes.
I guess, you forgot SET DEFAULT command or something like this. Don't forget, batch command may have different login environment.

Antonio Vigliotti
Antonio Maria Vigliotti
Peter Elliott_3
Occasional Advisor

Re: Starting a detached process from the batch queue

The command I am using
RUN/PROCESS=processname/DETACHED/OUTPUT=output.log process.exe

I have now included /error=error.log and get the following error:

%SYSTEM-F-ACCVIO, access violation, reason mask=04, ...

Perhaps this is more useful information?
Karl Rohwedder
Honored Contributor

Re: Starting a detached process from the batch queue

Check the accounting with the PID you get when the RUN command is executed.

$ ACCOUNT /FU/ID=... ACCOUNTNG

Check for the final status code/text.

regards Kalle
Robert_Boyd
Respected Contributor

Re: Starting a detached process from the batch queue

Peter,

One possibility is that the process is getting started with insufficient quotas and is running out of something leading to the ACCVIO.

You might try adding the /AUTHORIZE qualifier to the RUN to force it to be logged in with the quotas of the intended username.

And, if you still get the error message(s), please provide the complete text of the error.

Robert
Master you were right about 1 thing -- the negotiations were SHORT!
Peter Elliott_3
Occasional Advisor

Re: Starting a detached process from the batch queue

Adding AUTHORIZE did not help, so here is the error message in full:

SYSTEM-F-ACCVIO, access violation, reason mask=04, virtual address=0000FFFE, PC=00040C54, PS=0000001B
%TRACE-F-TRACEBACK, symbolic stack dump follows
Image Name Module Name Routine Name Line Number rel PC abs PC
RNGCLIN 0 00030C54 00040C54
0 85404170 85404170