2

我最近将我们的 Azure SDK 升级到 1.8(从 1.6 开始)。在部署我们所有的网络和工作人员角色时,除了 1 之外,没有任何问题。

这 1 个 worker 角色是唯一的 1 个有 2 个实例(其余为单实例);所有 dll 都设置为 CopyLocal = "true",连接字符串与成功上线的工作角色相同,我看不出代码有任何区别。

当我远程桌面进入其中一个实例时引发的错误是:

Faulting application name: WaHostBootstrapper.exe, version: 6.0.6002.18488, time stamp: 0x50a71329
Faulting module name: ntdll.dll, version: 6.1.7601.17696, time stamp: 0x4e8147f0
Exception code: 0xc0000374
Fault offset: 0x00000000000a0d6f
Faulting process id: 0x7d8
Faulting application start time: 0x01ce24b6e86ff75c
Faulting application path: E:\base\x64\WaHostBootstrapper.exe
Faulting module path: D:\Windows\SYSTEM32\ntdll.dll
Report Id: 33abe8c7-90aa-11e2-b534-00155d3a2649

和:

A fatal error occurred when attempting to access the SSL server credential private key. 
The error code returned from the cryptographic module is 0x8009030d. 
The internal error state is 10001.

在 Azure 管理门户中,角色会经历以下循环:

  • 起始角色
  • 准备节点
  • 恢复角色

几个小时以来,我一直试图确定问题所在,但无济于事。

额外细节

下面是原始的 WaHostBoostrapperLog;有许多这样的日志,唯一的区别是每个日志中的 PID 都发生了变化。

<- WapXmlReadRoleModel=0x1
<- WapXmlReadContainerId=0x1
<- WapGetVirtualAccountName=0x1
<- WapGetAppCmdPath=0x1
<- WapSetDefaultEnvironment=0x1
<- WapXmlReadContainerId=0x1
<- WapGetVirtualAccountName=0x1
<- WapGetAppHostConfigPath=0x1
<- GetDebugger=0x1
<- GetStartupTaskDebugger=0x1
<- WapGetEnvironmentVariable=0x800700cb
<- WapGetEnvironmentVariable=0x800700cb
Executing Startup Task type=2 rolemodule=Diagnostics cmd="E:\plugins\Diagnostics\DiagnosticsAgent.exe" 
Executing "E:\plugins\Diagnostics\DiagnosticsAgent.exe" .
<- WapGetEnvironmentVariable=0x800700cb
<- WapGetEnvironmentVariable=0x800700cb
Registering client with PID 2180.
Client DiagnosticsAgent.exe (2180) registered.
Executing Startup Task type=0 rolemodule=Diagnostics cmd="E:\plugins\Diagnostics\DiagnosticsAgent.exe" /blockStartup
Executing "E:\plugins\Diagnostics\DiagnosticsAgent.exe" /blockStartup.
Registering client with PID 1468.
Client DiagnosticsAgent.exe (1468) registered.
Program "E:\plugins\Diagnostics\DiagnosticsAgent.exe" /blockStartup exited with 0. Working Directory = E:\plugins\Diagnostics
<- WapGetEnvironmentVariable=0x800700cb
<- WapGetEnvironmentVariable=0x800700cb
Executing Startup Task type=2 rolemodule=RemoteAccess cmd="E:\plugins\RemoteAccess\RemoteAccessAgent.exe" 
Executing "E:\plugins\RemoteAccess\RemoteAccessAgent.exe" .
<- WapGetEnvironmentVariable=0x800700cb
<- WapGetEnvironmentVariable=0x800700cb
Registering client with PID 988.
Client RemoteAccessAgent.exe (988) registered.
Executing Startup Task type=0 rolemodule=RemoteAccess cmd="E:\plugins\RemoteAccess\RemoteAccessAgent.exe" /blockStartup
Executing "E:\plugins\RemoteAccess\RemoteAccessAgent.exe" /blockStartup.
Registering client with PID 1624.
Client RemoteAccessAgent.exe (1624) registered.
Program "E:\plugins\RemoteAccess\RemoteAccessAgent.exe" /blockStartup exited with 0. Working Directory = E:\plugins\RemoteAccess
<- GetDebugger=0x1
<- GetRoleHostDebugger=0x1
<- WapXmlReadContainerId=0x1
<- WapGetVirtualAccountName=0x1
Executing base\x64\WaWorkerHost.exe .
Role host process PID: 2264.
Registering client with PID 2264.
Client WaWorkerHost.exe (2264) registered.
Client process 2264 is the role host.
Role host process registered.
Getting status from client DiagnosticsAgent.exe (2180).
Client reported status 0.
Getting status from client DiagnosticsAgent.exe (1468).
Failed to connect to client DiagnosticsAgent.exe (1468).
<- CRuntimeClient::OnRoleStatusCallback(0x000000000044EB40) =0x800706ba
Getting status from client RemoteAccessAgent.exe (988).
Client reported status 0.
Getting status from client RemoteAccessAgent.exe (1624).
Failed to connect to client RemoteAccessAgent.exe (1624).
<- CRuntimeClient::OnRoleStatusCallback(0x000000000044EBD0) =0x800706ba
Getting status from client WaWorkerHost.exe (2264).
Failed to connect to client WaWorkerHost.exe (2264).
<- CRuntimeClient::OnRoleStatusCallback(0x000000000044E5A0) =0x800706ba
4

1 回答 1

1

在对有效的工作角色和导致上述错误的角色进行并排比较之后;我注意到无法启动的角色对另一个工作角色和单元测试项目都有不必要的引用。

虽然这在 SDK (1.6) 的早期版本中默默工作;1.8 版本似乎与其中一个参考有问题。

删除不必要的引用后,角色上线没有问题。

如果你遇到我推荐的 WaHostBootstrapper:

  • 确保所有 dll 都设置为 CopyLocal = "true" (如本问题所示
  • 从项目中删除任何不必要的引用
  • 删除任何可能导致冲突的引用
于 2013-03-20T11:02:38.923 回答