升级到Visual Studio 2015和Azure Sdk 2.8.2后,Azure Worker角色无法启动

时间:2016-02-11 05:51:05

标签: c# azure visual-studio-2015

我的Web应用程序曾经在Visual Studio 2012和Azure Sdk 2.5上正常工作,并希望升级到Visual Studio 2015和Azure Sdk 2.8.2。

它构建没有任何问题,并且在模拟器中运行没有问题。

当我部署到Windows Azure时,我收到此消息的角色 -

"回收(等待角色开始......网站已部署。[2016-02-11 ...])"

我在远程登录的Windows事件查看器中找到了以下错误消息...

错误消息1:

 System 

 Provider 

 [ Name]  Application Error 

  EventID 1000 

 [ Qualifiers]  0 

  Level 2 

  Task 100 

 Keywords 0x80000000000000 

 TimeCreated 

 [ SystemTime]  2016-02-11T05:43:24.000000000Z 

 EventRecordID 8425 

 Channel Application 

 Computer RD00155DF88E6C 

 Security 


 EventData 

 WaWorkerHost.exe 
 2.7.1198.742 
 5637c827 
 KERNELBASE.dll 
 6.2.9200.17366 
 554d4531 
 e0434352 
 000000000004aea8 
 884 
 01d1648f1e7cfdf5 
 E:\base\x64\WaWorkerHost.exe 
 D:\Windows\system32\KERNELBASE.dll 
 5d28a4a7-d082-11e5-9403-00155df88e6c 

错误消息2:

System 

 Provider 

 [ Name]  .NET Runtime 

 EventID 1026 

 [ Qualifiers]  0 

 Level 2 

 Task 0 

 Keywords 0x80000000000000 

 TimeCreated 

 [ SystemTime]  2016-02-11T05:43:24.000000000Z 

 EventRecordID 8424 

 Channel Application 

 Computer RD00155DF88E6C 

 Security 


 EventData 

 Application: WaWorkerHost.exe Framework Version: v4.0.30319 Description:      The process was terminated due to an unhandled exception. Exception Info: System.TypeInitializationException Stack: at Microsoft.WindowsAzure.ServiceRuntime.Implementation.Loader.RoleRuntimeBridge.<InitializeRole>b__0() at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean) at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean) at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object) at System.Threading.ThreadHelper.ThreadStart()  

任何帮助将不胜感激!!

1 个答案:

答案 0 :(得分:0)

确保您的项目引用了SDK程序集的升级版本,如Microsoft.WindowsAzure.Diagnostics和Microsoft.WindowsAzure.ServiceRuntime。显然,将解决方案升级到最新的SDK不会更新程序集引用。您可能还必须更新配置文件以获得正确的程序集版本。