How To Configure MSDTC For SQL Server

How To Configure MSDTC For SQL Server

In this article, we will configure MSDTC(Microsoft Distributed Transaction Coordinator) for an application that will connect to SQL Server with MSDTC. First open component services.

Open Component Services

Click Start->Run and type dcomcnfg to open component services or  go to Server Manager->Tools->Component Services.

Enable MSDTC

Configure Local DTC if the server is not cluster

If the server on which SQL Server is located is not Windows cluster, and SQL Cluster DTC is not available, you should configure Local DTC.

Go to the following tab and right click on “Local DTC” anc click Properties.

Then configure Local DTC as follows.

It will not be very safe to open Allow Remote Administration.

Configure Cluster DTC if the server is cluster:

If the server where SQL Server is located is windows cluster, you should configure the Cluster DTC.

Right-click the Cluster DTC that appears as deleted from the following screenshot and click Properties. Then configure Cluster DTC as follows.

It will not be very safe to open Allow Remote Administration.

MSDTC Ports:

MS DTC does not use the default ports of SQL.

There are special ports that it uses.

You can find a list of these ports on the link below.

https://msdn.microsoft.com/en-us/library/ee784913(v=cs.20).aspx

It may also use ports other than these ports.

Therefore, it is necessary to check whether there is a closed port between the application servers that will use ms DTC and the database servers.

You must grant the necessary access privilege from the firewall.

If you do not do this, the transactions that come with ms dtc will abort as follows.

dbtut

We are a team with over 10 years of database management and BI experience. Our Expertises: Oracle, SQL Server, PostgreSQL, MySQL, MongoDB, Elasticsearch, Kibana, Grafana.

Leave a Reply