看來,啓用「發送診斷數據到應用見解」,並添加SDK到項目應該是足以收集依賴關係數據。
但是,包含在Azure Cloud Service PaaS診斷插件v1.10.1.1中的Status Monitor的當前安裝程序是中斷。我嘗試使用以前版本的插件(v.1.10.0.0)的安裝程序 - 它完美地工作。
從插件的最新版本運行\ StatusMonitor應用\ ApplicationInsightsAgent.msi記錄以下異常:
Calling custom action CustomActions!CustomActions.CustomActions.SetEnvironmentVariables
Error: could not load custom action class CustomActions.CustomActions from assembly: CustomActions
System.IO.FileLoadException: Could not load file or assembly 'CustomActions, Version=2.4.0.18059, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. Strong name validation failed. (Exception from HRESULT: 0x8013141A)
File name: 'CustomActions, Version=2.4.0.18059, Culture=neutral, PublicKeyToken=31bf3856ad364e35' ---> System.Security.SecurityException: Strong name validation failed. (Exception from HRESULT: 0x8013141A)
我打開那個CustomActions.dll並通過SN爲它檢查強名稱。
sn.exe -vf CustomActions.dll
CustomActions.dll is a delay-signed or test-signed assembly
從v1.10.0.0爲CustomActions.dll
相同的檢查顯示
Assembly 'CustomActions.dll' is valid
顯然,有人在MS忘記簽署發佈之前該DLL,所以狀態監視器是對CS不再正確安裝虛擬機。向MS支持部門報告,希望他們能儘快解決。
一種解決方法可以手動添加缺少的角色開始的註冊表項,而W3SVC尚未啓動:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W3SVC\@Environment
型多字符串值的
與價值
COR_ENABLE_PROFILING=1
COR_PROFILER={324F817A-7420-4E6D-B3C1-143FBED6D855}
MicrosoftInstrumentationEngine_Host={CA487940-57D2-10BF-11B2-A3AD5A13CBC0}
生reg文件是:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W3SVC]
"Environment"=hex(7):43,00,4f,00,52,00,5f,00,45,00,4e,00,41,00,42,00,4c,00,45,\
00,5f,00,50,00,52,00,4f,00,46,00,49,00,4c,00,49,00,4e,00,47,00,3d,00,31,00,\
00,00,43,00,4f,00,52,00,5f,00,50,00,52,00,4f,00,46,00,49,00,4c,00,45,00,52,\
00,3d,00,7b,00,33,00,32,00,34,00,46,00,38,00,31,00,37,00,41,00,2d,00,37,00,\
34,00,32,00,30,00,2d,00,34,00,45,00,36,00,44,00,2d,00,42,00,33,00,43,00,31,\
00,2d,00,31,00,34,00,33,00,46,00,42,00,45,00,44,00,36,00,44,00,38,00,35,00,\
35,00,7d,00,00,00,4d,00,69,00,63,00,72,00,6f,00,73,00,6f,00,66,00,74,00,49,\
00,6e,00,73,00,74,00,72,00,75,00,6d,00,65,00,6e,00,74,00,61,00,74,00,69,00,\
6f,00,6e,00,45,00,6e,00,67,00,69,00,6e,00,65,00,5f,00,48,00,6f,00,73,00,74,\
00,3d,00,7b,00,43,00,41,00,34,00,38,00,37,00,39,00,34,00,30,00,2d,00,35,00,\
37,00,44,00,32,00,2d,00,31,00,30,00,42,00,46,00,2d,00,31,00,31,00,42,00,32,\
00,2d,00,41,00,33,00,41,00,44,00,35,00,41,00,31,00,33,00,43,00,42,00,43,00,\
30,00,7d,00,00,00,00,00
安裝狀態監視器可以幫助我的本地機器。狀態監視器也通過天藍色的基礎設施安裝在雲服務虛擬機上,但該設置似乎不完整。僅僅因爲狀態監視器的一些不完整安裝而導致整個應用程序的手動檢測將需要相當多的工作,並且不會幫助通過EF完成的查詢:( – PashaPash
將問題追溯到由MS使用的狀態監視器的錯誤安裝程序來預先配置Cloud Service發佈了可能的解決方法作爲答案。 – PashaPash