 |
SoftTree Technologies
Technical Support Forums
|
|
Author |
Message |
laiko
Joined: 11 Feb 2010 Posts: 43 Country: India |
|
Job with Database Command |
|
I am evaluating 24x7 MP version and encountered this issue on a job which 'Execute Database command' options all checked (Job Start, Job Finished.. Late Job Start).
The command is simply:
INSERT INTO job_log (event_time, host, job_id, job_name, event_type) VALUES (sysdate, '@V"computer"', '@V"job_id"', ' @V"job_name"', '@V"event"')
and the job simply calls a procedure which basically does nothing:
begin
null;
end;
When I open the master and run the job, the record gets created in the job_log table with event_type = 'START'. After that, nothing happens. The log says 'Job Finished' but the Monitor shows the green arrow. I do not see any record for the 'finished/end' event type. When I run the job again, it hangs. The log says 'Job started' and no record in the job_log is created. It hangs. What can be wrong here? My job is 'Asynchronous' and 'Detached'.
Basically, my goal here is to know how the job is performing by logging its start/end times. But does 24x7 have such feature - a report showing the job's average elapsed times, performance, CPU usage and all.
I really hope you can help me out on this. There are few things I've been trying lately but could not accomplish.
|
|
Sun Feb 28, 2010 3:44 pm |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7952
|
|
|
|
You may have a locked table and a hung job waiting for the lock to be released. When you update/insert/delete, make sure you close your transactions (commit or rollback)
|
|
Sun Feb 28, 2010 6:21 pm |
|
 |
laiko
Joined: 11 Feb 2010 Posts: 43 Country: India |
|
|
|
Ok, I changed my database command to:
begin
INSERT INTO job_log (event_time, host, job_id, job_name, event_type) VALUES (sysdate, '@V"computer"', '@V"job_id"', ' @V"job_name"', '@V"event"');
commit;
end;
When I restart the master, the job runs fine. It creates the record. When I rerun, it STILL hangs.
Can you give me an example? A very simple one which will insert records during 'Job Start', 'Job Finished' and 'Job Error'.
|
|
Mon Mar 01, 2010 6:20 am |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7952
|
|
|
|
Please use some database monitor to find out why the job hangs on the database side.
|
|
Mon Mar 01, 2010 9:43 am |
|
 |
laiko
Joined: 11 Feb 2010 Posts: 43 Country: India |
|
|
|
There are no locks or hanging transactions.
|
|
Tue Mar 02, 2010 3:13 am |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7952
|
|
|
|
Please enable tracing option in Tools->Options menu; Log tab. and rerun this job. Let's take a look at what is recorded in jdbc.log and debug.log files. Please post the content of these files. If you find any sensitive data in these logs, like IP address or password, mask them with some symbols before posting.
|
|
Tue Mar 02, 2010 8:54 am |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|