Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Mihir Ajmera 24 posts 124 karma points
    20 days ago
    Mihir Ajmera
    0

    Content Migration Error From Umbraco version 7.14.0 to 8.1.0

    Hello All,

    I have a large scale content data available in the Umbraco 7.14.0 and it's around 12Lac+ entry available in the cmspropertyData table. As per new requirement, I try to update Umbraco version 7.14.0 to Umbraco 8.1+ version. For this, I set up all configuration, remove recycle bin entry, remove version history which requirement upgrade content migration in the Umbraco version 8.1.0.

    After, continue process on content migration which takes around 2 hr and getting me below error.

    The database failed to upgrade. ERROR: The database configuration failed with the following message: Cannot rename datatype alias "Umbraco.MediaPicker2" to "Umbraco.MediaPicker" because the target alias is already used.This is generally because when upgrading from a v7 to v8 site, the v7 site contains Data Types that reference old and already Obsolete Property Editors. Before upgrading to v8, any Data Types using property editors that are named with the prefix '(Obsolete)' must be migrated to the non-obsolete v7 property editors of the same type. Please check log file for additional information (can be found in '/App_Data/Logs/')
    

    So, anyone have any idea about how to solve this issue and do the process again with minimum time and migrate fully content without any error.

    Because. content was too large so every-time its take much time to process.

    Thanks in advance.

  • Shaishav Karnani from digitallymedia.com 277 posts 1264 karma points
    20 days ago
    Shaishav Karnani from digitallymedia.com
    0

    Hi Mihir,

    Your site was built on old version and seems to be migrated to v7.14. Therefore, it is using old Media Data Type. You need to upgrade old media to use new Media in v7.14 and if you are using any other Obsolete Data Type then please upgrade it too before moving to v8.

    If any data type that donot have matching with v8 data type for plugins then change it to label. So, that atleast you can move without any errors.

    Also I would suggest that before migrating you cleanup your database. So, that records get reduced. Old logs, old versions of content gets removed. Remove any item from Recycled bin.

    It's seems bit of work in your case given the volume.

    Do let me know how it goes?

    Cheers,

    Shaishav

  • Mihir Ajmera 24 posts 124 karma points
    20 days ago
    Mihir Ajmera
    0

    Hi Shaishav,

    I have no idea about upgrading old media type to new media type in v7.14 and Obsolete Data Type. can you share me any reference link so I can follow and do the appropriate process?

    My existing Umbraco version 7.14.0 which I need to upgrade 8.1+.

    I can`t identify the media type version so can you help me with this?

    Thanks.

    Mihir.

  • Shaishav Karnani from digitallymedia.com 277 posts 1264 karma points
    20 days ago
    Shaishav Karnani from digitallymedia.com
    1

    (Obsolete) Media Picker https://our.umbraco.com/Documentation/Getting-Started/Backoffice/Property-Editors/Built-in-Property-Editors/Media-Picker/old-media-picker

    It stores as ID or CSV where as (New) Media Picker stores values in UDI format.

    So, you need to convert any Document Type that uses (Obsolete) Media Picker to (New) Media Picker before migrating to v8. Can you check if you are using (Obsolete) data type in your project first?

  • Mihir Ajmera 24 posts 124 karma points
    20 days ago
    Mihir Ajmera
    0

    Hi Shaishav,

    Thanks for the reference link.

    I check all existing data type of media picker, content picker etc which are starting with "(Obsolete)" prefix so I replace those data type with newly data type just like (Obsolete) Media picker to "Media Picker".

    After again run the migration process then its work continues and gives another "cmsMacro" table column "macroSource" not accept null value which I also resolved it.

    Currently, it gives me below error which I try to solve.

    The database failed to upgrade. ERROR: The database configuration failed with the following message:  Invalid cast from 'System.DateTime' to 'System.ValueTuple`2[[System.Nullable`1[[System.DateTime, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],System.Nullable`1[[System.DateTime, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]'. 
    

    If you have any idea for above error then tell me so continue on next process for further migration?

    Thanks in advance.

  • Steve Megson 48 posts 320 karma points c-trib
    20 days ago
    Steve Megson
    1

    That looks like this bug, which was fixed in 8.1.2.

  • Mihir Ajmera 24 posts 124 karma points
    19 days ago
    Mihir Ajmera
    0

    Hi Shaishav,

    I try with latest release version Umbraco 8.1.4 which I think it solves the above error but somehow it gives me another error in the database with Foreign key release issues created. Please refer below error

    The database failed to upgrade. ERROR: The database configuration failed with the following message: The ALTER TABLE statement conflicted with the FOREIGN KEY constraint "FK_umbracoUser2NodeNotify_umbracoUser_id". The conflict occurred in database "umbracodb814", table "dbo.umbracoUser", column 'id'
    

    For this error, I checked the database entry of two tables and I got data from the Umbracouser table with Foreign key constraint so why this error come I don`t know.

    One thing I identify in the UmbracoUser table is with the latest Umbraco 8 Master Admin user created with -1(primary key) value and but in my case of Umbraco 7 admin user has 0(Primary key) value. So, I am not sure maybe this value changes effect to Foreign key relationship.

    If you have any idea about this then tell me so quick resolve and continue on the further process?

    Currently, I am stuck with this error your suggestion will be appreciated for the next process.

    Thanks in advance

  • Steve Megson 48 posts 320 karma points c-trib
    19 days ago
    Steve Megson
    100

    This does look like a bug. When the the superuser is moved to ID -1, umbracoUser2NodeNotify should be updated to reflect that.

    Here's the SQL the migration uses, with the missing update of umbracoUser2NodeNotify added. You should be able to run this before the migration to avoid the bug.

    umbracoUser set userLogin = userLogin + '__' where id=0
    
    set identity_insert umbracoUser on;
    
    insert into umbracoUser (id,
        userDisabled, userNoConsole, userName, userLogin, userPassword, passwordConfig,
        userEmail, userLanguage, securityStampToken, failedLoginAttempts, lastLockoutDate,
        lastPasswordChangeDate, lastLoginDate, emailConfirmedDate, invitedDate, 
        createDate, updateDate, avatar, tourData)    
    select
        -1 id,
        userDisabled, userNoConsole, userName, substring(userLogin, 1, len(userLogin) - 2) userLogin, userPassword, passwordConfig,
        userEmail, userLanguage, securityStampToken, failedLoginAttempts, lastLockoutDate,
        lastPasswordChangeDate, lastLoginDate, emailConfirmedDate, invitedDate, 
        createDate, updateDate, avatar, tourData
    from umbracoUser where id=0;
    
    set identity_insert umbracoUser off;
    
    update umbracoUser2UserGroup set userId=-1 where userId=0;
    update umbracoNode set nodeUser=-1 where nodeUser=0;
    update umbracoUserLogin set userId=-1 where userId=0;
    update umbracoUser2NodeNotify set userId=-1 where userId=0;
    update cmsPropertyData set userId=-1 where userId=0;
    
    delete from umbracoUser where id=0;
    
  • Mihir Ajmera 24 posts 124 karma points
    18 days ago
    Mihir Ajmera
    0

    Hello Steve Megson,

    Thanks for the quick solution it works fine.

    After resolved above error I do the same process again for content migration I got below numbers of type errors.

    1. Skipping validation of configuration for data type {NodeId} : {EditorAlias}. Please ensure that the configuration is valid. The site may fail to start and / or load data types and run.","@l":"Warning","NodeId":11037,"EditorAlias":"Umbraco.RadioButtonList","SourceContext":"Umbraco.Core.Migrations.Upgrade.V_8_0_0.DataTypeMigration",
    2. Skipping validation of configuration for data type {NodeId} : {EditorAlias}. Please ensure that the configuration is valid. The site may fail to start and / or load data types and run.","@l":"Warning","NodeId":16937,"EditorAlias":"Umbraco.DropDown.Flexible","SourceContext":"Umbraco.Core.Migrations.Upgrade.V_8_0_0.DataTypeMigration",
    3. Could not find an editor with alias {EditorAlias}, treating as Label. The site may fail to boot and / or load data types and run.","@l":"Warning","EditorAlias":"Umbraco.FolderBrowser","SourceContext":"Umbraco.Core.Models.DataType"
    4.  could not find parent id=7127.","@l":"Warning","SourceContext":"Umbraco.Web.PublishedCache.NuCache.ContentStore","ProcessId":45424,"ProcessName":"iisexpress","ThreadId":70,"AppDomainId":3,
    

    For above solution I follow one reference link (https://github.com/umbraco/Umbraco-CMS/commit/79159b684dabcbe8b54597691380bb17982285cf)

    and try to implement all property editor class in my App_Code folder and try to run the solution I got below error. enter image description here

    If you have any idea to resolve then tell me so I do next process.

    Thanks in advance.

  • Mihir Ajmera 24 posts 124 karma points
    18 days ago
    Mihir Ajmera
    0

    Hello All,

    I upgrade Umbraco version 7.14.0 to 8.1.4 latest version during content migration I got the below error

    Could not find an editor with alias {EditorAlias}, treating as Label. The site may fail to boot and / or load data types and run.","@l":"Warning","EditorAlias":"Umbraco.FolderBrowser","SourceContext":"Umbraco.Core.Models.DataType","ProcessId":21492,"ProcessName":"iisexpress","ThreadId":134,"AppDomainId":3,"AppDomainAppId":"LMW3SVC2ROOT","MachineName":"DEV02","Log4NetLevel":"WARN ","HttpRequestNumber":1,"HttpRequestId":"0be8ec2e-e5b8-424e-9ac3-bbca0ca5faad"}
    

    when I check in the latest database table Umbraco datatype of Umbraco 8.1.4 then I identify "Umbraco.FolderBrowser" datatype property remove it.

    So, anyone has an idea about how to replace this data type with other so configured properly in the latest version of Umbraco.

    Thanks in advance

  • Steve Megson 48 posts 320 karma points c-trib
    18 days ago
    Steve Megson
    0

    I don't think you need to replace Umbraco.FolderBrowser with anything. It has effectively been replaced by the Child Items tab in Umbraco 8, so you can just remove the property.

  • Mihir Ajmera 24 posts 124 karma points
    17 days ago
    Mihir Ajmera
    0

    Hi Steve Megson,

    As your suggestion, I remove the property from the data type and re-run the full content migration for only published data but still, I got the same error in the Umbraco version 8.1.4.

    Could not find an editor with alias {EditorAlias}, treating as Label. The site may fail to boot and / or load data types and run.","@l":"Warning","EditorAlias":"Umbraco.FolderBrowser","SourceContext":"Umbraco.Core.Models.DataType","ProcessId":21492,"ProcessName":"iisexpress","ThreadId":134,"AppDomainId":3,"AppDomainAppId":"LMW3SVC2ROOT","MachineName":"DEV02","Log4NetLevel":"WARN ","HttpRequestNumber":1,"HttpRequestId":"0be8ec2e-e5b8-424e-9ac3-bbca0ca5faad"}{"@t":"2019-09-05T09:38:13.2715601Z","@mt":"Skip item id=11225, both draft and published data are null.","@l":"Warning","SourceContext":"Umbraco.Web.PublishedCache.NuCache.ContentStore","ProcessId":21492,"ProcessName":"iisexpress","ThreadId":134,"AppDomainId":3,"AppDomainAppId":"LMW3SVC2ROOT","MachineName":"DEV02","Log4NetLevel":"WARN ","HttpRequestNumber":1,"HttpRequestId":"0be8ec2e-e5b8-424e-9ac3-bbca0ca5faad"}
    

    So any other idea you have then tell me so I can implement that solve the issues.

    Thanks in Advance

Please Sign in or register to post replies

Write your reply to:

Draft