How to Reset ‘Stuck’ Documentum Jobs

One of my Documentum system administrators continued to get messages like the one below:

Job “dm_StateOfDocbase” failed to execute successfully. The message was:
“[ERROR] [AGENTEXEC 3836] Detected while processing dead job
dm_StateOfDocbase: The job object indicated the job was in progress, but the job was not actually running. It is likely that the dm_agent_exec utility was stopped while the job was in progress.”

——————————
COMPUTER-READABLE DATA
——————————
>>>begin_data_block
>>>data_block_type=docbase_event
>>>data_block_name=none
>>>docbase_name=globalregistry
>>>event_name=Job_Failure
>>>sender_name=dmadmin
>>>recipient_name=dmadmin@mail.com
>>>recipient_login_name=dmadmin
>>>object_name=dm_StateOfDocbase
>>>message_text=[ERROR] [AGENTEXEC 3836] Detected while processing dead
>>>job dm_StateOfDocbase: The job object indicated the job was in progress, but the job was not actually running. It is likely that the dm_agent_exec utility was stopped while the job was in progress.
>>>queue_item_id=1b0000000000d919
>>>end_data_block

Though not serious, it is troubling and if it doesn’t self-correct, it needs to be investigated.  Robin East wrote about this problem in depth in his post http://robineast.wordpress.com/2008/01/.  I will give you the easy remedy here.

When a job runs, its dm_job.a_special_app attribute is set to ‘agentexec’.  When the job completes, this attribute is reset to blank.  Likely, what happened is that the server was shutdown/restarted while this job was running and, because it did not properly complete, the a_special_app attribute was not reset to blank.  When the AgentExec process was restarted, it noticed the inconsistency and sent the warning message.  To fix it, simple manually reset the job’s attributes:

update dm_job object set a_special_app = ”, set a_current_status = ‘ABORTED’, set a_last_completion = DATE(TODAY) where object_name = ‘dm_StateOfDocbase’

Here are some other handy job-related queries and procedures:

To determine which jobs are currently running:

select object_name, r_object_id, a_last_invocation from dm_job where a_special_app = ‘agentexec’

To stop a currently executing job, terminate its process in the Windows Task Manager.

  1. First, determine the job’s process id (PID) with DQL:

    select object_name, r_object_id, a_last_invocation, a_last_completion, a_last_process_id, a_current_status from dm_job where a_special_app = ‘agentexec’ order by a_last_process_id

  2. Then, terminate the job’s PID in the Window’s Task Manager.
  3. After you terminate the job, you will need to manually reset the status attribute of the dm_job object using a DQL query like above.
Advertisements

About Scott
I have been implementing Documentum solutions since 1997. In 2005, I published a book about developing Documentum solutions for the Documentum Desktop Client (ISBN 0595339689). In 2010, I began this blog as a record of interesting and (hopefully) helpful bits of information related to Documentum, and as a creative outlet.

2 Responses to How to Reset ‘Stuck’ Documentum Jobs

  1. doquent says:

    Scott,

    Thanks for sharing this useful troubleshooting information.

    In my experience, unlocking the job object using API (unlock,c,) has been sufficient for me to get the job going again.

    Pawan

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: