简体   繁体   English

Microsoft.Practices.EnterpriseLibrary.Common在IIS 8.5中不起作用,但它在IIS 7.0中工作

[英]Microsoft.Practices.EnterpriseLibrary.Common is not working in IIS 8.5 but its working in IIS 7.0

I have deployed my web application using by Microsoft.Practices.EnterpriseLibrary.Common dll and hosted in IIS 7.0 and its working fine (Able to access the DB) but same published code i am deploying in IIS 8.5 but its not working and i am getting bellow error. 我已经使用Microsoft.Practices.EnterpriseLibrary.Common dll部署了我的Web应用程序并在IIS 7.0中托管并且工作正常(能够访问数据库)但我在IIS 8.5中部署的相同发布代码但是它无法正常工作波纹管错误。

ERROR System.TypeInitializationException: The type initializer for 'Microsoft.Practices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.EnterpriseLibraryFactory' threw an exception. 错误System.TypeInitializationException:“Microsoft.Practices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.EnterpriseLibraryFactory”的类型初始值设定项引发异常。 ---> System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Practices.ObjectBuilder2, Version=2.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. ---> System.IO.FileNotFoundException:无法加载文件或程序集“Microsoft.Practices.ObjectBuilder2,Version = 2.2.0.0,Culture = neutral,PublicKeyToken = 31bf3856ad364e35”或其依赖项之一。 The system cannot find the file specified. 该系统找不到指定的文件。 at Microsoft.Practices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.EnterpriseLibraryFactory..cctor() --- End of inner exception stack trace --- at Microsoft.Practices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.EnterpriseLibraryFactory.BuildUp[T](IConfigurationSource configurationSource) at Microsoft.Practices.EnterpriseLibrary.Data.DatabaseFactory.CreateDatabase() 在Microsoft.Practices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.EnterpriseLibraryFactory..cctor()---内部异常堆栈跟踪结束---在Microsoft.Practices.EnterpriseLibrary.Common.Configuration.ObjectBuilder.EnterpriseLibraryFactory.BuildUp [T] (IConfigurationSource configurationSource)at Microsoft.Practices.EnterpriseLibrary.Data.DatabaseFactory.CreateDatabase()

This is an old question - but posting here for anyone looking for an answer. 这是一个老问题 - 但是在这里张贴给寻找答案的人。

Recently ran into this issue but with a Windows Service (of a legacy code/service). 最近遇到了这个问题,但使用Windows服务(遗留代码/服务)。 All we were trying to do was switch the Database server in the connection string from Server A to Server B. 我们所要做的就是将连接字符串中的数据库服务器从服务器A切换到服务器B.

Found the root cause to be that the SQL Authentication user id was not setup in Server B - seems obvious except that the error message wasn't. 找到了根本原因,即在服务器B中未设置SQL身份验证用户标识 - 除了错误消息之外,似乎很明显。 Anyways fixing the authentication issue addressed this exception for us. 无论如何修复身份验证问题为我们解决了这个例外。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 无法加载文件或程序集“Microsoft.Practices.EnterpriseLibrary.Common”或其依赖项之一 - Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.Common' or one of its dependencies 无法在WCF中加载文件或程序集'Microsoft.Practices.EnterpriseLibrary.Common - Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.Common in WCF '您必须添加对Microsoft.Practices.EnterpriseLibrary.Common的引用',即使汇编在GAC中 - 'You must add a reference to Microsoft.Practices.EnterpriseLibrary.Common' even though assembly is in the GAC 无法解决此参考。 无法找到程序集“ Microsoft.Practices.EnterpriseLibrary.Common” - Could not resolve this reference. Could not locate the assembly “Microsoft.Practices.EnterpriseLibrary.Common” httphandler拦截在IIS 7.0中不起作用 - httphandler intercept not working in IIS 7.0 无法加载文件或程序集“Microsoft.Practices.EnterpriseLibrary.Common,Version=6.0.0.0,Culture=neutral,PublicKeyToken=31bf3856ad364e35”或 - Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.Common, Version=6.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or OWIN Cookie身份验证无法在IIS 8.5上运行 - OWIN Cookie authentication not working on IIS 8.5 如何避免不引用“ Microsoft.Practices.EnterpriseLibrary.Common.Instrumentation.IInstrumentationEventProvider”? - How to avoid `Microsoft.Practices.EnterpriseLibrary.Common.Instrumentation.IInstrumentationEventProvider` is not referenced? AppDomain AssemblyResolve事件请求Microsoft.Practices.EnterpriseLibrary.Common.resources - AppDomain AssemblyResolve Event asks for Microsoft.Practices.EnterpriseLibrary.Common.resources IIS8.5中的PHP站点内的Application中的ASPX页面不起作用 - ASPX pages not working in Application within PHP site in IIS8.5
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM