Archive for the ‘MSDTC’ Category

Powershell MSDTC cluster add in

Teched 2010 Berlin #TEE10 #Teched

For Demo and learning Sites you need often thing that takes only a minute but when you play with it it takes more time than you want.

So with this in my mind I created 3 powershell scripts that you can use for builing a cluster , NLB Cluster and a MSTDC cluster resource.

So If you want to create a MSDTC resource in your Cluster you can do this in the GUI or with a Powershell Script.

You can find the Scripts Here : Powershell Scripts

Powershell MSDTC cluster add in

First We load the powershell modules If it is a cluster you should do this on all the Cluster Nodes

Servermanagercmd -install Application-Server
Servermanagercmd -install AS-Dist-Transaction AS-Ent-Services –allSubFeatures

I Comment every line for what it does.

# Create a new HA Server Role – Distributed Transaction Coordinator
Add-ClusterServerRole -Name ServerDTC -Storage "Cluster Disk 6" -StaticAddress 192.168.1.1

Here we create the resource and chuck it to a disk and IP

# Add the MSDTC Service to the new Server Role
Get-ClusterGroup ServerDTC | Add-ClusterResource -Name MSDTC-ServerDTC -ResourceType "Distributed Transaction Coordinator"

Put in the MSDTC services.

# Create Dependencies for the DTC group
Add-ClusterResourceDependency MSDTC-ServerDTC ServerDTC
Add-ClusterResourceDependency MSDTC-ServerDTC "Cluster Disk 6"
# Start DTC group
Start-ClusterGroup ServerDTC

 

So Now that this is ready you can configure the MSDTC but remember the items that I mentioned in my previous blog.

http://robertsmit.wordpress.com/2010/10/20/msdtc-clustering-logfile-bug/

MSDTC Clustering Logfile Bug

For some enhanced settings I want to change the log file settings in the MSDTC settings.

It should been between 1 MB and 512 MB so I set my logfile setting to 512 Mb.

Invalid log file ? What ??  Why is 70 MB between 1 and 512 Mb  ?

clip_image001

So it turns out that 64 MB is the max logfile size for the MSDTC log.

Is it a bug ? Yes and No The error message is not clear for this You can’t set this in the GUI you can only set this in the Registery.

clip_image002 clip_image003

There is more diskspace so this can’t be the issue.

Set the LOG size above 64 MB

By default, the Maximum log file size is 64 MB. For general scenarios, one should not need more than that. But if you have a reason to increase the log file size past 64 MB, you can push this up to 512 MB provided you have a certain registry entry – MaxLogSize under MSDTC registry key.

For standalone servers, this is under HKEY_LOCAL_MACHINESOFTWAREMicrosoftMSDTC .

For Clustered DTC, it is at HKEY_LOCAL_MACHINEClusterResources<ResID>MSDTCPRIVATEMSDTC

Create a DWORD entry MaxLogSize and set it to 512 (decimal)

But What about the security settings ? IF I look I the services than I see a domain account running this services.

clip_image001[4]

But On the DCOMCNFG.exe I see no service account but when I change something here the service account is reset to the Networkservice.

clip_image002[4]

This is also a GUI bug If you look in the register you can see the service account is there and in the services it is also there.

So be carefull If you change something in the cluster MSDTC gui your services account will go to the default settings !

the NETWORKService

WordPress Tags: MSDTC,Logfile,want,file,Invalid,Registery,issue,Maximum,MaxLogSize,HKEY_LOCAL_MACHINE,SOFTWARE,Microsoft,Cluster,Resources,ResID,MSDTCPRIVATE,Create,DWORD,DCOMCNFG,service,Networkservice,settings,change,should,size,default,registry,entry,under,account,also

  • Tag