我使用的Visual Studio Express的2012,和Windows Azure的SDK用於.NET v11.0.5022,它安裝IIS快遞8.當我嘗試運行Windows Azure的應用程序,IISConfigurator.exe會崩潰Windows Azure的應用程序崩潰IISConfigurator.exe
這是日誌文件
IISConfigurator Information: 0 : [00011404:00000001, 2012/07/17 19:18:56.304] Started
iisconfigurator with args /start
IISConfigurator Information: 0 : [00011404:00000001, 2012/07/17 19:18:56.32] StartForeground selected. Check if an instance is already running
IISConfigurator Information: 0 : [00011404:00000001, 2012/07/17 19:18:56.341] Starting service WAS
IISConfigurator Information: 0 : [00011404:00000001, 2012/07/17 19:18:56.51] Starting service w3svc
IISConfigurator Information: 0 : [00011404:00000001, 2012/07/17 19:18:56.516] Starting service apphostsvc
IISConfigurator Information: 0 : [00011404:00000001, 2012/07/17 19:18:56.583] Unhandled exception: IsTerminating 'True', Message 'System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Web.Administration, Version=7.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
File name: 'Microsoft.Web.Administration, Version=7.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.HostingEnvironment.ConfigureAnonymousAuthentication(String configPath)
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.HostingEnvironment.Initialize(Boolean setupRewrite, String configPath)
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.HostingEnvironment.Initialize(Boolean setupRewrite, String configPath)
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.IISConfigurator.Initialize()
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.WCFServiceHost.Open()
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.Program.StartForgroundProcess()
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.Program.DoActions(String[] args)
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.Program.Main(String[] args)
WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
'
IISConfigurator Information: 0 : [00010228:00000001, 2012/07/17 19:19:07.934] Started iisconfigurator with args /start
IISConfigurator Information: 0 : [00010228:00000001, 2012/07/17 19:19:07.941] StartForeground selected. Check if an instance is already running
IISConfigurator Information: 0 : [00010228:00000001, 2012/07/17 19:19:07.963] Starting service WAS
IISConfigurator Information: 0 : [00010228:00000001, 2012/07/17 19:19:08.032] Starting service w3svc
IISConfigurator Information: 0 : [00010228:00000001, 2012/07/17 19:19:08.037] Starting service apphostsvc
IISConfigurator Information: 0 : [00010228:00000001, 2012/07/17 19:19:08.106] Unhandled exception: IsTerminating 'True', Message 'System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Web.Administration, Version=7.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.
File name: 'Microsoft.Web.Administration, Version=7.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.HostingEnvironment.ConfigureAnonymousAuthentication(String configPath)
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.HostingEnvironment.Initialize(Boolean setupRewrite, String configPath)
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.HostingEnvironment.Initialize(Boolean setupRewrite, String configPath)
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.IISConfigurator.Initialize()
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.WCFServiceHost.Open()
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.Program.StartForgroundProcess()
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.Program.DoActions(String[] args)
at Microsoft.WindowsAzure.ServiceRuntime.IISConfigurator.Program.Main(String[] args)
WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
'
看來應用程序試圖綁定到IIS版本7.0,其中IIS版本7.9.0.0(IIS 8候選發佈版)安裝。
什麼辦法可以解決這個問題?
謝謝,許明。我想堅持一些簡單的事情,並避免管理IISExpress的麻煩。另外,我希望能夠嚴格遵循Azure示例,因此我可以排除構建過程失敗時的原因。 – hanxue 2012-07-18 22:46:58
然後請嘗試重新安裝Windows Azure SDK和IIS Express以查看是否有幫助。 – 2012-07-19 14:34:16
安裝IIS管理控制檯和IIS HWC後,問題奇蹟般消失。見http://goo.gl/K3ZAJ的細節 我很想去錯誤的底部,因爲我看到了很多在互聯網上類似的帖子。希望這個錯誤可以避免爲其他人 – hanxue 2012-07-20 02:09:12