Stop-Dtc
Stop-Dtc
Stop-Dtc stops the DTC instance specified by the DtcName parameter.
Syntax
Parameter Set: Default
Stop-Dtc [-DtcName <String> ] [-Recursive] [ <CommonParameters>]
Detailed Description
Stop-Dtc stops the DTC instance specified by the DtcName parameter.
Parameters
-DtcName<String>
Specifies the DTC instance to stop. If this parameter is null or set to Local, this will stop the Local DTC instance.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
|
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-Recursive
Specifies to stop any services relying on the specified DTC instance, such as SQL Server, etc.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
|
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
<CommonParameters>
This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters
Examples
Stopping a DTC instance.
For the purpose of this example the Local DTC instance is used, however you can stop any instance by changing the value of the DtcName parameter
1. Get-Dtc -DtcName Local to view the Local DTC instance's Status.
PS C:\> Get-Dtc -DtcName Local
__GENUS : 2
__CLASS : DtcInstance
__SUPERCLASS :
__DYNASTY : DtcInstance
__RELPATH :
__PROPERTY_COUNT : 7
__DERIVATION : {}
__SERVER :
__NAMESPACE :
__PATH :
DtcName : Local
KtrmEndpointCid : b6628c9f-46ff-404d-a0fa-62657cb828af
OleTxEndpointCid : f3027ea1-4ee5-45b5-a01c-06f41221111b
Status : Started
UisEndpointCid : e9385758-8092-4dd7-8b09-587aa427a58e
VirtualServerName : CSDVM736403-GU
XAEndpointCid : ced49d85-82a9-49d9-a6ee-8c5b4bd7b5bd
2. Since the Status shows that the instance is started, it is safe to Stop-Dtc -DtcName Local.
PS C:\> Stop-Dtc -DtcName Local
3. Get-Dtc -DtcName Local one last time to confirm that the DTC instance is stopped.
PS C:\> Get-Dtc -DtcName Local
__GENUS : 2
__CLASS : DtcInstance
__SUPERCLASS :
__DYNASTY : DtcInstance
__RELPATH :
__PROPERTY_COUNT : 7
__DERIVATION : {}
__SERVER :
__NAMESPACE :
__PATH :
DtcName : Local
KtrmEndpointCid : b6628c9f-46ff-404d-a0fa-62657cb828af
OleTxEndpointCid : f3027ea1-4ee5-45b5-a01c-06f41221111b
Status : Stopped
UisEndpointCid : e9385758-8092-4dd7-8b09-587aa427a58e
VirtualServerName : CSDVM736403-GU
XAEndpointCid : ced49d85-82a9-49d9-a6ee-8c5b4bd7b5bd