DB2 XA transactions failure : : Failed to enlist on calling object's transaction.
We are unable to run XA transactions with DB2 server. It fails with the error :
Source: Microsoft OLE DB Provider for ODBC Drivers
[Microsoft][ODBC Driver Manager] Failed to enlist on calling object's transaction
Microsoft OLE DB Provider for ODBC Drivers
Few things to check
Checked the registry settings :
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSDTC\XADLL ] DB2cli.dll = <Path of db2cli.dll>
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSDTC\XADLL ] DB2app.dll = <Path of db2app.dll>
They entries were good.
Added NT Authority\NetworkService account to local admin group and still got the same error, that rules out permissions issue with the MSDTC service logon account.
If we set the COM+ components to transaction support level of Supported or Disabled, the web page works. Setting it to Required causes it to fail. This is because when we use the Supported or Disabled setting the transaction is not using DTC service.
We were also getting the error :
Failed to enlist in DTC: SQL state , native error -5042, error message [IBM][CLI
Driver] SQL5042N One of the communication protocol server support processes failed to start up.”
As the source of the error was IBM driver, suggested that we should include IBM support to check if the DB2 client is configured properly. Involved the IBM support and the error was resolved by running the correct command as :
db2 update dbm cfg using SPM_NAME sdawwi08
SPM_NAME = service name
sdawwi08 = server name