尝试从IIS运行DotNetNuke 7.1时出现以下错误。'/ DotNetNuke_Community'应用程序中的服务器错误
Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.
Source Error: Line 572: //first call GetProviderPath - this insures that the Database is Initialised correctly
Line 573: //and also generates the appropriate error message if it cannot be initialised correctly
Line 574: string strMessage = DataProvider.Instance().GetProviderPath();
Line 575: //get current database version from DB
Line 576: if (!strMessage.StartsWith("ERROR:"))
我尝试下载并解压缩源代码到一个文件夹,然后运行后,从Visual Studio 2012上运行它,但我得到了同样的错误(还VS负荷约13它的实例的内置Web服务器这不可能是正确的)。
显然,数据库有问题。从我以前阅读的内容来看,应该有一个启动配置页面(用于第一次运行项目时配置设置)。
我确实看过IIS的本地版本(在Windows 8上运行),并且它在那里创建了很好的网站,但是由于某些原因,内部web服务器试图运行(并且在外部IIS上运行的选项是灰色的出)。
任何人遇到这个问题与DNN社区版?我尝试以管理员身份运行并设置权限,但没有任何运气。
有什么办法解决这个问题?
我怀疑App_Data下名为“Database.mdf”的文件是罪魁祸首。当我尝试编辑或单击它时,我收到错误消息“数据库文件与SQL的当前实例不兼容”。 我把它加载到另一台机器上的SQL2012上,发现它只是一个空的数据库。 我将尝试在开发机器上加载SQL2012 express版本。 – MC9000
安装SQL2012 Express并不能帮助VS2012读取文件(我推测这是行不通的,但试过了)。 我发现连接字符串的4个位置,所以我创建了一个新的空数据库和用户,更改了所有4个连接字符串(文档错误地指出连接字符串在web.config文件中 - 它们实际上是在release.config和development的.config)。 我正在重命名配置文件,看看这是否工作.... – MC9000