Mariusz, Gorzoch tech Blog

6648 Orphaned DTA Service Instances in {Server}.BizTalkDTADb, 1 Messages with refcount less than 0 in {Server}.BizTalkMsgBoxDb [SQLSTATE 42000] (Error 50000)

leave a comment »

My dear BizTalk 2010. I’ve just installed you and placed really simply app… why you are screaming with this nasty error ?

Actually not BizTalk itself is doing that but rather one of his SQL jobs :

Monitor BizTalk Server
Scans for any known issues with the BizTalkMgmtDb, BizTalkMsgBoxDb, and BizTalkDTADb databases. This includes orphaned instances.
Note This job is created on BizTalk Server 2010.

After digging for a while I found a good post describing what to do with that. The idea is to use special tool called “BizTalk Terminator”.

As you can find in description of mentioned post this tools is mentioned to resolve one of common database integration problem. In the old days those tasks where performed manually. Lucky now… we can just start that tool and use it.

Here are steps to use mentioned terminator:

  • Do backup of entire environment. In my case I was lucky that we are running BizTalk on VM host, so I’ve just asked to create snapshot of the entire machine
  • Determine task in “BizTalk Terminator” to run in order to resolve problem. In case of our issue the problem should be resolved by task:


  • Shutdown BizTalk instance and all his SQL jobs (make sure that they are not running)
  • Open “Terminator” , specify server name and database information
  • Check all checkboxes in order to confirm that you did backup and stop all instances and SQL jobs
  • Find task “Repair Refcounts for All Messages” and execute it (no parameters is required)



  • Find task “Repair Orphaned DTA Service Instances” and execute it (no parameters are required)



After performing above steps I did run SQL job “Monitor BizTalk Server” and confirmed that problem was resolved.

good luck…


Written by Mariusz Gorzoch

26 August 2011 at 21:31

Posted in BizTalk 2010

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 )

Google+ photo

You are commenting using your Google+ 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 )


Connecting to %s

%d bloggers like this: