Troubleshooting Upgrade and CU Batch jobs stuck in a waiting status in Dynamics AX 2012

本文介绍了在 Dynamics AX 2012 中进行全版本升级或应用累积更新时遇到批处理任务卡在等待状态的问题及解决步骤。包括检查 X++ 编译、使用正确的管理员账户、调整批处理设置等。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

There may be circumstances when you are testing a Full version upgrade, in place upgrade, or applying a Cumulative Update (CU) in Dynamics AX 2012 where the batch jobs never start and appear to be stuck in a waiting status.

Normally we see problems when the Dynamics AX databases is restored to a different environment and the batch framework settings have not been corrected.  See this blog for a
larger discussion of this http://blogs.msdn.com/b/axsupport/archive/2011/11/07/moving-between-microsoft-dynamics-ax-2012-environments.aspx

I have compiled a list of things to check to make sure the setup of the batch framework is correct:

1. As always make sure you can get through a Full X++ compile and Full CIL generation without errors in the developer workspace before moving on to any of the other Checklist items.

2. Make sure the user account logging into the Dynamics AX client to run the checklist is the Dynamics AX admin account and NOT just a member of the system administrator security role.

  • To make sure you are logged in as the “admin” account go to Tools | Options | Status Bar and mark the checkbox to Show user ID.  Close the Options form and then when you check the lower right hand corner of the Main Dynamics AX window it will show the account you are logged in with.  This must be “admin”
  • Check the batch form directly in the client by going to System Administration | Batch Jobs | Batch Jobs and check the Createdby fields and if the DataUpdate job has already scheduled as an account other than admin, you need to start the upgrade over by logging in as the admin account or you may be able to change the records in the batch and batchjob tables to be the admin account. 
  • Check the userinfo table in SQL: select * from userinfo where ID = ‘admin’  to make sure a record for the “admin” ID has  a valid SID, networkdomain, and networkalias for each partition in the environment. 

Important: You should be very careful about updating the records in the SQL backend make sure to use a where clause in the SQL statement to only update those records you intend to, also make a SQL backup of the Dynamics database, and that you are testing the steps in an environment such as test or development.

The SQL statement you could use would be to set the EXECUTEDBY and CREATEDBY fields to the “admin” user id for the dataUpdate job.

 3. Remove any records in the SysServerSessions table that are not valid in this environment, you should do this while the AOS servers are stopped and make sure to have a SQL backup first.

4. Check the setup under system administration | setup | system | Server configuration

  • Delete any AOS instances here that are not valid in this environment
  • Make sure the remaining AOS instance is marked “is batch server”
  • Make sure batch server schedule is setup with proper start/end time i.e. Start time 12:00:00 am end time 11:59:59, so there are no gaps in the scheduled time.

5. Under system administration | setup | batch group

  • Make sure that the remaining valid AOS server that is also marked for batch has the blank batch group and dataUpdate batch group assigned to it.

Note: The blank batch group is used to process any runtime batch tasks that are spawned as separate batch threads so this batch group is critical.

6. Check system administration | Batch Jobs | Batch Jobs

    • Change the status of any other batch jobs from waiting to withheld so they don’t interfere with the Data Upgrade batch jobs.  To change the status highlight the jobs you want to change and select Functions | Change Status and choose Withhold
    • Check for any previously running batch jobs that are stuck in a status of Executing.  You may need to change the status to cancelled or remove the Job from the Batch and Batchjob table from the SQL backup.

转载于:https://www.cnblogs.com/xiangliqi/p/6204703.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值