我们注意到DTC服务停止正常工作。 从ASP.NET应用程序login:
System.UnauthorizedAccessException: Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED)) at System.Transactions.Oletx.IDtcProxyShimFactory.ConnectToProxy(String nodeName, Guid resourceManagerIdentifier, IntPtr managedIdentifier, Boolean& nodeNameMatches, UInt32& whereaboutsSize, CoTaskMemHandle& whereaboutsBuffer, IResourceManagerShim& resourceManagerShim) at System.Transactions.Oletx.DtcTransactionManager.Initialize() at System.Transactions.Oletx.DtcTransactionManager.get_ProxyShimFactory()
在此状态下,DTC不能重新启动。 我们注意到Windows日志中的一些事件,所以我们尝试了不同的解 这是一个实际上帮助,但只有几个小时: https : //technet.microsoft.com/en-us/library/cc774114(v=ws.10).aspx 。 DTC重新启动,但随后出现以下问题,问题又回来了:
Source: Microsoft-Windows-MSDTC Client Date: 2017-03-16 09:25:19 Event ID: 4356 Task Category: MSDTC Proxy Description: Failed to initialize the MS DTC Communication Manager. Error Specifics: hr = 0x80070005, com\complus\dtc\dtc\cm\src\ccm.cpp:2118, CmdLine: C:\Windows\system32\msdtc.exe, Pid: 4252
重新启动DTC再次以错误结束,因此出现以下事件:
Source: Microsoft-Windows-MSDTC Date: 2017-03-16 10:20:41 Event ID: 4441 Task Category: SVC Description: A MS DTC component has encountered an internal error. The process is being terminated. Error Specifics: DtcSystemShutdown (com\complus\dtc\dtc\msdtc\src\msdtc.cpp@2485): Shutting down with an error Source: Microsoft-Windows-MSDTC Date: 2017-03-16 10:20:41 Event ID: 4439 Task Category: Unknown Description: Failed to verify MS DTC service account information. Internal Information : msdtc_trace : File: com\complus\dtc\shared\util\security.cpp, Line: 818, VerifyAccountInfo: CService::Create failed, hr=0x80070005. Source: Microsoft-Windows-MSDTC Client Date: 2017-03-16 10:20:41 Event ID: 4356 Task Category: MSDTC Proxy Description: Failed to initialize the MS DTC Communication Manager. Error Specifics: hr = 0x80070005, com\complus\dtc\dtc\cm\src\ccm.cpp:2118, CmdLine: C:\Windows\system32\msdtc.exe, Pid: 4252
DTC重新configuration有助于但不会很长时间。 更多关注的事件:
Log Name: Application Source: Microsoft-Windows-MSDTC Client Date: 2017-03-14 12:03:27 Event ID: 4156 Task Category: CM Description: String message: INFORMATIONAL: Negotiate Resources returned OUT OF RESOURCES IN SSTATE_UP. Source: Microsoft-Windows-Perflib Date: 2017-03-15 13:58:59 Event ID: 1008 Task Category: None Description: The Open Procedure for service "MSDTC" in DLL "C:\Windows\system32\msdtcuiu.DLL" failed. Performance data for this service will not be available. The first four bytes (DWORD) of the Data section contains the error code.
感谢来自微软支持的Martin Nolte和Feroz Khan,我们设法解决了这个问题。
确认问题没有与“红色箭头问题”连接。 运行dcomcnfg打开组件服务,看“Red Arrow”是否在“我的电脑”上。
如果您在数据库服务器上看到MSDTC红色箭头。 要纠正这个问题,请按照下面提到的步骤(或从https://blogs.msdn.microsoft.com/asiatech/2010/02/21/how-to-troubleshoot-the-red-arrow-issue-in -component-services-i / )
确保MSDTC服务已启动:
validation用户组是否具有读取HKEY_CLASSES_ROOT\CLSID下的子项的权限。 如果用户组没有读取子项的权限,则COM +系统应用程序服务可能会遇到启动困难并导致相同的“红色箭头”问题。 为了扩大对Users组的读取权限,我们可以按照这个步骤(首先我们应该备份HKEY_CLASSES_ROOT\CLSID ):
Regedt32 ,findHKEY_CLASSES_ROOT\CLSID CLSID ,单击菜单栏中的安全 – >权限 检查是否每个人都具有对C:\Windows\Registration及其子对象的读取权限。
MSDTC服务应允许经过身份validation的用户查询服务状态。 要检查这个,我们可以在命令窗口中运行这个命令:
sc sdshow msdtc
如果Authenticated Users组对MSDTC服务对象没有查询权限,这将导致大多数用户没有权限获取MSDTC服务状态,例如:
(A;;CR;;;AU)
我们需要运行这个命令来授予Authenticated用户足够的权限,然后重新启动DLLHOST.exe(在这之前,请备份“sc sdshow msdtc”的输出信息):
sc sdset msdtc D:(A;;CCLCSWRPLOCRRC;;;S-1-2-0) (A;;CCLCSWRPWPDTLOCRRC;;;SY)(A;;CCDCLCSWRPWPDTLOCRSDRCWDWO;;;BA) (A;;CCLCSWLOCRRC;;;IU)(A;;CCLCSWLOCRRC;;;SU)(A;;CCLCSWLOCRRC;;;AU) (A;;CCLCSWRPWPDTLOCRRC;;;PU)(A;;CCLCSWRPLORC;;;NS)S: (AU;FA;CCDCLCSWRPWPDTLOCRSDRCWDWO;;;WD)
如果上述步骤不起作用,则必须执行其他步骤,例如重buildCOM +目录并消除registry项损坏。
validationMSDTC服务的问题仍然存在。 如果是这样,请确保您没有为MSDTC设置组策略。
还原默认帐户: https : //technet.microsoft.com/en-us/library/cc774114(v=ws.10).aspx
如果您在dcomcnfg中将帐户设置为“networking服务”,则在HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSDTC\Security.下设置以下registry值: AccountName HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSDTC\Security.
要查看此registry值是否受到组策略的影响,可以执行以下步骤:
rsop.msc ,它将显示应用的组策略
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSDTC\Security任何定义吗? 要获取所有应用组策略,您需要下载
打开Powershell命令提示符并input以下命令:
Import-Module GroupPolicy Get-GPOReport -All -ReportType Html -Path AllGPOsReport.htm
为MSDTC设置默认组策略
iisreset /restart