Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/database/9.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Database 在umbraco安装期间无法连接到数据库_Database_Umbraco7 - Fatal编程技术网

Database 在umbraco安装期间无法连接到数据库

Database 在umbraco安装期间无法连接到数据库,database,umbraco7,Database,Umbraco7,我有一个干净的项目,我正在努力开始。我还创建了一个干净的数据库 两者都在我的电脑上本地运行 我可以使用linqpad连接到我的数据库,没有任何问题。 但当我尝试“定制”并设置microsoft SQL server时,它会说 无法连接到数据库 在控制台中,我得到一个500内部服务器错误,在: :62164/install/api/PostValidateDatabaseConnection 我能做什么 编辑 尝试使用自定义连接字符串时,我得到以下结果: at System.Runtime

我有一个干净的项目,我正在努力开始。我还创建了一个干净的数据库

两者都在我的电脑上本地运行

我可以使用linqpad连接到我的数据库,没有任何问题。 但当我尝试“定制”并设置microsoft SQL server时,它会说

无法连接到数据库

在控制台中,我得到一个500内部服务器错误,在:

:62164/install/api/PostValidateDatabaseConnection
我能做什么

编辑 尝试使用自定义连接字符串时,我得到以下结果:

   at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
   at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at Umbraco.Web.Install.Controllers.InstallApiController.ExecuteStep(InstallSetupStep step, JToken instruction)
 2017-09-12 09:16:22,389 [P1996/D2/T11] INFO  Umbraco.Web.Install.Controllers.InstallApiController - Step completed (took 32ms)
 2017-09-12 09:16:22,390 [P1996/D2/T11] ERROR Umbraco.Web.Install.Controllers.InstallApiController - An error occurred during installation step DatabaseConfigure
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object.
   at Umbraco.Core.DatabaseContext.SaveConnectionString(String connectionString, String providerName)
   at Umbraco.Core.DatabaseContext.ConfigureDatabaseConnection(String connectionString)
   at Umbraco.Web.Install.InstallSteps.DatabaseConfigureStep.ConfigureConnection(DatabaseModel database)
   at Umbraco.Web.Install.InstallSteps.DatabaseConfigureStep.Execute(DatabaseModel database)
   --- End of inner exception stack trace ---

即使使用自定义连接字符串,如果仍然出现500个错误,我认为您的安装有问题,您应该尝试从头开始重新安装Umbraco

是否使用自定义连接字符串进行了尝试?如果是,你能把它粘贴到这里吗?我没有,而且我目前不知道字符串的格式应该是什么?你在使用哪个数据库服务器?这是sqlexpress的连接字符串示例:server=127.0.0.1\sqlexpress;数据库=YOURDB;用户id=您的用户id;password='YOURPASSWORD'它是在microsoft sql server management studio 17中本地创建的数据库,这将是连接字符串i quess:server=DESKTOP-GR1B3N9\SQLEXPRESS;数据库=冒险LRP_网站;用户id=adventurelrp\u用户\u登录;password='YOURPASSWORD'对不起,我不知道,真奇怪。。您是否尝试从头重新安装它?