Having issues with a schedule job (jal), when testing the job (debug) it runs just fine but when it is run normally the job gets hung in the queue when it is finished. I can see that it is finished by: 1) the files have been moved and 2) it is no longer showing up in the task manager. It also cannot be “killed”; the only way to get it out of the queue is to stop the 24x7 service.
Version 5.1.395

Do you see JAL.EXE process in the task manager after the job completes?

If you set timeout property for the job, is the scheduler able to clear the job from its queue after the specified timeout time?

Fri Sep 27, 2013 11:46 am

MightyMouse

Joined: 27 Sep 2013Posts: 16

No the jal.exe process in task manager is no longer there when the job completes.

In order to use the “time out” function the job has to be run in “detached process” which is not our standard. Plus the job will vary depending on the amount of files to be moved. It takes about 25 minutes to move four thousand files.

For testing purposes I did as requested and used a different queue, the job “finished” in 26 minutes and the time out was set for 30 minutes, and after 33 minutes the job was still showings as RUNNING in the job monitor.

Fri Sep 27, 2013 12:33 pm

MightyMouse

Joined: 27 Sep 2013Posts: 16

Correction:
Version 5.1 Build 405
JVM Version 1.6.0_17-b04

Fri Sep 27, 2013 12:48 pm

SysOpSite Admin

Joined: 26 Nov 2006Posts: 6739

Generally speaking all jobs should run detached there only very few exceptions to that rule.

Back to the issue, please enable tracing in scheduler options, and rerun the job. After job completion review debug.log file and let us know if you see any errors or exceptions there.

Please try one more thing for me, disable output capturing option in the job, rerun it and see if that helps.

Fri Sep 27, 2013 2:42 pm

MightyMouse

Joined: 27 Sep 2013Posts: 16

Disabled the capture, rebooted the server and let the job run as scheduled, still hangs up in the queue.

Mon Sep 30, 2013 11:04 am

SysOpSite Admin

Joined: 26 Nov 2006Posts: 6739

Well, we know now it's not a logging conflict, the job process must be leaving some resources open.
Can you please add to the end of your JAL job scrip the following commands instead of Exit

Dim pid
JobProcessID pid
ProcessKill pid

Mon Sep 30, 2013 12:44 pm

MightyMouse

Joined: 27 Sep 2013Posts: 16

The first run ended with an error: An error occurred while executing automation script Line 52: Invalid datatype.

The Dim statement needs a Datatype, I used datatype “Number”, same results; 1) the files have been moved and 2) it is no longer showing up in the task manager and the JOB shows as RUNNING in the Queue.

Mon Sep 30, 2013 3:44 pm

SysOpSite Admin

Joined: 26 Nov 2006Posts: 6739

Sorry I forgot to add the data type.

Does the job have any notifications and/or other on finish actions

Mon Sep 30, 2013 4:13 pm

MightyMouse

Joined: 27 Sep 2013Posts: 16

Yes,
Send e-mail message:
Job Start
Job Finish
Job Error

I get the e-mail on the start of the job and on an error but not on the finish.

Mon Sep 30, 2013 4:21 pm

SysOpSite Admin

Joined: 26 Nov 2006Posts: 6739

Let's temporarily disable them to ensure that is not a factor.

Mon Sep 30, 2013 5:34 pm

MightyMouse

Joined: 27 Sep 2013Posts: 16

Disabled the all the e-mail notifications – same results.
Created a new job – copied the JAL from notepad – same results.

Tue Oct 01, 2013 10:46 am

SysOpSite Admin

Joined: 26 Nov 2006Posts: 6739

Just to be certain, other JAL jobs work fine, this is the only JAL job having difficulties, correct?