У нас есть веб-ферма с 3 серверами, на которой запущено приложение ASP.Net 3.5 на IIS6, Windows server 2003. Мы только что установили обновление для приложения, и два из трех серверов были в порядке, но с третьим сразу начались проблемы. Пытаясь запустить сайт, мы видим это исключение в логах:
System.IO.FileLoadException: Could not load file or assembly 'System.EnterpriseServices.Wrapper.dll' or one of its dependencies. This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)
File name: 'System.EnterpriseServices.Wrapper.dll' ---> System.Runtime.InteropServices.COMException (0x800736B1): This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)
at System.Reflection.Assembly._nGetModules(Boolean loadIfNotFound, Boolean getResourceModules)
at System.Reflection.Assembly.nGetModules(Boolean loadIfNotFound, Boolean getResourceModules)
at System.Reflection.Assembly.GetTypes()
at System.Web.Mvc.ControllerTypeCache.GetAllControllerTypes(IBuildManager buildManager)
at System.Web.Mvc.ControllerTypeCache.EnsureInitialized(IBuildManager buildManager)
at System.Web.Mvc.DefaultControllerFactory.GetControllerTypeWithinNamespaces(String controllerName, HashSet`1 namespaces)
at System.Web.Mvc.DefaultControllerFactory.GetControllerType(String controllerName)
at System.Web.Mvc.DefaultControllerFactory.CreateController(RequestContext requestContext, String controllerName)
at System.Web.Mvc.MvcHandler.ProcessRequest(HttpContextBase httpContext)
at System.Web.Mvc.MvcHandler.ProcessRequest(HttpContext httpContext)
at System.Web.Mvc.MvcHandler.System.Web.IHttpHandler.ProcessRequest(HttpContext httpContext)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
и с этого момента:
System.Runtime.InteropServices.COMException (0x800736B1): This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)
at System.Reflection.Assembly._nGetModules(Boolean loadIfNotFound, Boolean getResourceModules)
at System.Reflection.Assembly.nGetModules(Boolean loadIfNotFound, Boolean getResourceModules)
at System.Reflection.Assembly.GetTypes()
at System.Web.Mvc.ControllerTypeCache.GetAllControllerTypes(IBuildManager buildManager)
at System.Web.Mvc.ControllerTypeCache.EnsureInitialized(IBuildManager buildManager)
at System.Web.Mvc.DefaultControllerFactory.GetControllerTypeWithinNamespaces(String controllerName, HashSet`1 namespaces)
at System.Web.Mvc.DefaultControllerFactory.GetControllerType(String controllerName)
at System.Web.Mvc.DefaultControllerFactory.CreateController(RequestContext requestContext, String controllerName)
at System.Web.Mvc.MvcHandler.ProcessRequest(HttpContextBase httpContext)
at System.Web.Mvc.MvcHandler.ProcessRequest(HttpContext httpContext)
at System.Web.Mvc.MvcHandler.System.Web.IHttpHandler.ProcessRequest(HttpContext httpContext)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
Пока я пробовал:
Так что я как бы застрял. Любые идеи?
Проблема в том, что разрешения в GAC каким-то образом были нарушены. Исправить:
shfusion.dll
с regsvr32, чтобы вы могли получить доступ c:\windows\assembly
shfusion.dll
Для удобства также запустите aspnet_regiis.exe -ga "UserAccount"
для исправления разрешений метабазы IIS.