The installer is trying to upgrade the DB but hitting this fault:
The database failed to upgrade. ERROR: The database configuration
failed with the following message:
'DFumbracoUserdefaultToLiveEditing' is not a constraint. Could not
drop constraint. See previous errors. Please check log file for
additional information (can be found in
'/App_Data/Logs/UmbracoTraceLog.txt')
The log file has this to go on:
2014-12-01 13:50:56,282 [8] INFO
Umbraco.Core.Persistence.Migrations.MigrationRunner - [Thread 41]
Executing sql statement 46: ALTER TABLE [umbracoUser] DROP CONSTRAINT
[DFumbracoUserdefaultToLiveEditing] 2014-12-01 13:50:56,287 [8] INFO
Umbraco.Core.Persistence.UmbracoDatabase - [Thread 41] at
System.Data.SqlClient.SqlConnection.OnError(SqlException exception,
Boolean breakConnection, Action1 wrapCloseInAction) at
System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject
stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at
System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior,
SqlCommand cmdHandler, SqlDataReader dataStream,
BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject
stateObj, Boolean& dataReady) at
System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String
methodName, Boolean async, Int32 timeout, Boolean asyncWrite) at
System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource1
completion, String methodName, Boolean sendToPipe, Int32 timeout,
Boolean asyncWrite) at
System.Data.SqlClient.SqlCommand.ExecuteNonQuery() at
StackExchange.Profiling.Data.ProfiledDbCommand.ExecuteNonQuery() at
Umbraco.Core.Persistence.PetaPocoCommandExtensions.<>cDisplayClass1.0()
at
Umbraco.Core.Persistence.FaultHandling.RetryPolicy.ExecuteAction[TResult](Func1
func) at Umbraco.Core.Persistence.Database.Execute(String sql,
Object[] args) 2014-12-01 13:50:56,287 [8] ERROR
Umbraco.Core.DatabaseContext - [Thread 41] Database configuration
failed System.Data.SqlClient.SqlException (0x80131904):
'DF_umbracoUser_defaultToLiveEditing' is not a constraint. Could not
drop constraint. See previous errors. at
System.Data.SqlClient.SqlConnection.OnError(SqlException exception,
Boolean breakConnection, Action1 wrapCloseInAction) at
System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject
stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at
System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior,
SqlCommand cmdHandler, SqlDataReader dataStream,
BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject
stateObj, Boolean& dataReady) at
System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String
methodName, Boolean async, Int32 timeout, Boolean asyncWrite) at
System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource1
completion, String methodName, Boolean sendToPipe, Int32 timeout,
Boolean asyncWrite) at
System.Data.SqlClient.SqlCommand.ExecuteNonQuery() at
StackExchange.Profiling.Data.ProfiledDbCommand.ExecuteNonQuery() at
Umbraco.Core.Persistence.PetaPocoCommandExtensions.<>c__DisplayClass1.<ExecuteNonQueryWithRetry>b__0()
at
Umbraco.Core.Persistence.FaultHandling.RetryPolicy.ExecuteAction[TResult](Func1
func) at Umbraco.Core.Persistence.Database.Execute(String sql,
Object[] args) at
Umbraco.Core.Persistence.Migrations.MigrationRunner.ExecuteMigrations(IMigrationContext
context, Database database) at
Umbraco.Core.Persistence.Migrations.MigrationRunner.Execute(Database
database, DatabaseProviders databaseProvider, Boolean isUpgrade) at
Umbraco.Core.DatabaseContext.UpgradeSchemaAndData()
ClientConnectionId:66fc30a0-622a-4f6c-9e85-643b709ab042 2014-12-01
13:50:56,287 [8] INFO Umbraco.Core.DatabaseContext - [Thread 41] The
database schema validation produced the following summary: The
following tables were found in the database, but are not in the
current schema: sysdiagrams,cmsMacroProperty The following columns
were found in the database, but are not in the current schema:
sysdiagrams,name,sysdiagrams,principalid,sysdiagrams,diagramid,sysdiagrams,version,sysdiagrams,definition,cmsDataType,controlId,umbracoUser,userDefaultPermissions,umbracoUser,defaultToLiveEditing,cmsDataType,propertyEditorAlias,cmsMacroProperty,id,cmsMacroProperty,editorAlias,cmsMacroProperty,macro,cmsMacroProperty,macroPropertySortOrder,cmsMacroProperty,macroPropertyAlias,cmsMacroProperty,macroPropertyName,cmsTagRelationship,propertyTypeId
The following constraints (Primary Keys, Foreign Keys and Indexes)
were found in the database, but are not in the current schema:
FKcmsTagRelationshipumbracoNodeid,FKcmsContentVersioncmsContentnodeId,FKcmsDocumentcmsContentnodeId,FKcmsDocumentcmsTemplatenodeId,FKcmsDocumentTypecmsContentTypenodeId,FKcmsDocumentTypecmsTemplatenodeId,FKcmsDataTypePreValuescmsDataTypenodeId,FKcmsLanguageTextcmsDictionaryid,FKcmsMacroPropertycmsMacroid,FKcmsMemberTypecmsContentTypenodeId,FKcmsMembercmsContentnodeId,FKcmsContentXmlcmsContentnodeId,FKcmsPreviewXmlcmsContentnodeId,FKcmsPreviewXmlcmsContentVersionVersionId,FKcmsPropertyTypeGroupcmsContentTypenodeId,FKcmsPropertyTypecmsDataTypenodeId,FKcmsPropertyTypecmsContentTypenodeId,FKcmsTagscmsTags,FKcmsTagRelationshipcmsContent,FKcmsTagRelationshipcmsPropertyType,FKcmsContentTypeAllowedContentTypecmsContentType,FKcmsContentTypeAllowedContentTypecmsContentType1,PKsysdiagrC2B05B61236943A5,PKcmsPreviewXml,PKcmsMacroProperty,PKcmsContentPreviewXml,IXumbracoNodeTrashed,IXumbracoNodeParentId,IXumbracoNodeObjectType,IXcmsTemplatenodeId,IXcmsContent,IXcmsContentVersionContentId,IXcmsContentVersionVersionId,IXcmsDocument,IXcmsDocumentpublished,IXcmsDocumentnewest,IXcmsContentType,IXcmsContentTypeicon,IXcmsDataTypenodeId,IXcmsDictionaryid,IXumbracoLanguagelanguageISOCode,IXumbracoLog,IXcmsMacroPropertyAlias,IXcmsMacroPropertyAlias,IXcmsPropertyData,IXcmsPropertyData1,IXcmsPropertyData2,IXcmsPropertyData3,IXcmsTags,IXumbracoUserLoginsIndex,IXumbracoUseruserLogin,IXcmsTaskTypealias,IXcomputerName,IXumbracoServerisActive
The following indexes were found in the database, but are not in the
current schema:
UKprincipalname,umbracoUserLoginsIndex,IXumbracoNodeTrashed,IXcmsContentVersionContentId,IXcmsDocumentpublished,IXcmsDocumentnewest,IXcmsMacroPropertyAlias,IXcmsMacroPropertyAlias,IXcmsTags,IXumbracoUserLoginsIndex
The following unknown constraints (Primary Keys, Foreign Keys and
Indexes) were found in the database, but are not in the current
schema: UKprincipal_name
2014-12-01 13:50:56,288 [8] ERROR
Umbraco.Web.Install.Controllers.InstallApiController - [Thread 41]
Installation step DatabaseUpgrade failed.
System.Reflection.TargetInvocationException: Exception has been thrown
by the target of an invocation. --->
Umbraco.Web.Install.InstallException: The database failed to upgrade.
ERROR: The database configuration failed with the following message:
'DFumbracoUserdefaultToLiveEditing' is not a constraint. Could not
drop constraint. See previous errors. Please check log file for
additional information (can be found in
'/AppData/Logs/UmbracoTraceLog.txt') at
Umbraco.Web.Install.InstallSteps.DatabaseUpgradeStep.Execute(Object
model) --- End of inner exception stack trace --- 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) at
Umbraco.Web.Install.Controllers.InstallApiController.PostPerformInstall(InstallInstructions
installModel) 2014-12-01 13:50:56,288 [8] INFO
Umbraco.Web.Install.Controllers.InstallApiController - [Thread 41]
Step completed (took 148ms) 2014-12-01 13:50:56,288 [8] ERROR
Umbraco.Web.Install.Controllers.InstallApiController - [Thread 41] An
error occurred during installation step DatabaseUpgrade
System.Reflection.TargetInvocationException: Exception has been thrown
by the target of an invocation. --->
Umbraco.Web.Install.InstallException: The database failed to upgrade.
ERROR: The database configuration failed with the following message:
'DFumbracoUserdefaultToLiveEditing' is not a constraint. Could not
drop constraint. See previous errors. Please check log file for
additional information (can be found in
'/AppData/Logs/UmbracoTraceLog.txt') at
Umbraco.Web.Install.InstallSteps.DatabaseUpgradeStep.Execute(Object
model) --- End of inner exception stack trace --- 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) at
Umbraco.Web.Install.Controllers.InstallApiController.PostPerformInstall(InstallInstructions
installModel)
It looks like it's confused by the table sysDiagrams (which I can easily delete - pretty sure I added that looking at the constraints just now), and macroPropertyType.
Can anyone suggest what I need to do here? I can't remove macroPropertyType due to it's own relationships with the macroProperty and macro tables.
The latest one available in the repository v7.1.9. The release notes against it just refer me back to the main v7 upgrade path with me coming from v6.1.2. Your link does the same thing and I've followed it through as far as I can tell.
o.Core.DatabaseContext - [Thread 7] The database schema validation
produced the following summary: The following tables were found in
the database, but are not in the current schema: cmsMacroProperty
Even having deleted that database though, the problem remains.
We have an Umbraco Database version 6.1.6, and trying to update causes the same error mentioned in this thread. I tried updating from 6.1.6 to 7.0.0, 6.1.6 to 7.0.4, 6.1.6 to 7.1.0, 6.1.6 to 7.2 and they all cause the same error.
The database configuration failed with the following message: 'DF_umbracoUser_defaultToLiveEditing' is not a constraint. Could not drop constraint.
Any help is greatly appreciated, we really want to use the new grid introduced in 7.2 without having to rebuild the whole site on the newer version of Umbraco.
I finally got 7.2 to install. I had to modify the database to add some constraints that were missing.
alter Table [umbracoUser] add CONSTRAINT [DF_umbracoUser_defaultToLiveEditing] DEFAULT (0) for [defaultToLiveEditing]
alter Table [cmsMacroProperty] add CONSTRAINT [DF_cmsMacroProperty_macroPropertyHidden] DEFAULT (0) for [macroPropertyHidden]
These two columns did have a default value or binding, so I had to manually get rid of those bindings before I could add these constraints.
After I ran that script, the upgrade to 7.2 worked perfectly.
I'll leave this here in case other people need help with this.
Upgrading from 6.1.2 - DB error
Hi,
So I'm upgrading from version 6.1.2 and have followed the instructions on http://our.umbraco.org/documentation/Installation/Upgrading/general/. Everything seems to have gone OK until the Finalise stage.
The installer is trying to upgrade the DB but hitting this fault:
The log file has this to go on:
It looks like it's confused by the table sysDiagrams (which I can easily delete - pretty sure I added that looking at the constraints just now), and macroPropertyType.
Can anyone suggest what I need to do here? I can't remove macroPropertyType due to it's own relationships with the macroProperty and macro tables.
A little stumped.
Hi Richard
What version of Umbraco are you upgrading to? Make sure to read these documents as well http://our.umbraco.org/documentation/Installation/Upgrading/version-specific
/Jan
Hi Jan,
The latest one available in the repository v7.1.9. The release notes against it just refer me back to the main v7 upgrade path with me coming from v6.1.2. Your link does the same thing and I've followed it through as far as I can tell.
Not sure what I've missed or maybe misunderstood.
It seems to fail with the message:
INFO Umbrac
Even having deleted that database though, the problem remains.
I'll keep plugging away.
For anyone hitting this same problem in the future, I'll keep the thread going.
The message seems to be quite specific and Googling isn't coming up with much in the way of an explanation.
Going to attempt to upgrade to v7.0 instead and then on to v7.1.9 from there. Hoping the step change will make the difference.
I'll update further once I've tried that.
We have an Umbraco Database version 6.1.6, and trying to update causes the same error mentioned in this thread. I tried updating from 6.1.6 to 7.0.0, 6.1.6 to 7.0.4, 6.1.6 to 7.1.0, 6.1.6 to 7.2 and they all cause the same error.
Any help is greatly appreciated, we really want to use the new grid introduced in 7.2 without having to rebuild the whole site on the newer version of Umbraco.
I finally got 7.2 to install. I had to modify the database to add some constraints that were missing.
These two columns did have a default value or binding, so I had to manually get rid of those bindings before I could add these constraints.
After I ran that script, the upgrade to 7.2 worked perfectly.
I'll leave this here in case other people need help with this.
is working on a reply...