Freigeben über


CHECKDB

Hello,

In this post, I would like to share with you a tool I created and which is commonly used at Microsoft in the COM+ & MSDTC Support team but also in my Biztalk Support team for example to troubleshoot DB access & DTC issues : CHECKDB.

Be careful, don't make confusion with the SQL CHECKDB command :-)

 

Purpose of this tool is mainly to test very quickly Db connection/query execution to a Database using or not an MSDTC transaction.

 

I'm sure you already met errors saying that Db connection failed or that an MSDTC transaction can not be enlisted ("Failed to Enlist") without to know really if the problem was specific to the client application you were using.

My tool just allow so to make quick connection/query tests to any ODBC or OLEDB compliant Databases w/o MSDTC and to Oracle via OCI 7 w/o XA.
It display then the detailed results of each step of the test (Connection to MSDTC, Tx creation, Db connection, Tx Enlistment, Query, Close...) with their duration.
This tool can also test quickly the db via 2 MTS/COM+ components, one configured to be non-Transactional and the other to be Transactional implementing both OLEDB, ODBC and ADO interfaces.

You can so verify very quickly if you can connect to the DB using the connection settings you configured and most important if an MSDTC transaction can be well propagated to the targeted Resource Manager (the DB).

This 32 bits tool was developed in C++ & MFC and can be used in any x86 windows platforms

 Tool usage is very simple :

- Just select the options you want to use via the "Options" tab (like MSDTC usage or not, COM+ components usage or not)

- Select the tab corresponding to the API Db you want to use : ODBC, OLEDB, ADO, Native Oracle db using API OCI 7

- Then  press the "Test" button to run the test

Detailed results of each step of the test (Connection to MSDTC, Tx creation, Db Connection Tx Enlistment, Query, Close...) with their duration will appear then in a Listbox and also in a log file (full path is shown in the "Options" tab).

If you see errors in the Enlistment step, you can read the two following good KB articles  https://support.microsoft.com/kb/191168/en-us and https://support.microsoft.com/kb/306843/en-us

Feel free to add your comment if you have any question or feedback to raise

Thanks !

JP

CheckDB.zip

Comments

  • Anonymous
    July 27, 2015
    Is it a good idea to use a name already taken by SQL Server? imagine how many failed internet searches we get because of this!!! "here is where the sad faced smile would be"
  • Anonymous
    February 26, 2016
    I was looking for DBCC CHECKDB...