v7 to v12 Migration - Content not importing
I am migrating a site with around ~23,000 content nodes and 30,000 media nodes. The media appears to import fine but the content does not.
During the content import, the root nodes get logged as follows:
Document {ContentName} (id={ContentId}) has been published.
where ContentId is always zero?
I wondering if this is the source of my issues because this happens for all top-level nodes from the original v7 site and all subsequent imports fail with publish errors because the parent is not published.
Failed to publish FailedPublishPathNotPublished
I will update the issue as/when I do find anything further but in the meantime if anyone has any ideas I'd welcome them.
I'm sorry I don't have any specific tips for you @ProNotion, however I can tell you that I was in a similar boat last week. I was having all manner of difficulty migrating from 7 to 10 and experiencing issues such as:
- Content being migrated into Umbraco but not properly placed in the hierarchy of the site (parent node missing or not published).
- Content being migrated into Umbraco as not published.
A couple of troubleshooting tips I recommend:
- My Umbraco 7 Backoffice and DB I assume, had a lot of saved-but-unpublished pages. To be clear: these pages were published and live on the site. They just had been saved with updates. Their current version was not published. I think the export for these pages resulted in a value in the XML specifically stating it was unpublished, so uSync.Migrations did not publish them.
- Some of my document types were not migrating correctly. Work on those first before you ever touch content, or you'll get nowhere!
- Be careful with trying to do partial imports. Example: I got my content types properly imported, but I was having trouble with the content. The media worked fine. I deleted media to make future imports quicker. Here's where I made a mistake: I deleted the
data typesandcontent types. Well - if yourtypesaren't there, uSync.Migrations won't know how to refactor your content appropriately. Really ignorant mistake on my part.
Thanks for the info @markadrake
I am having slightly more success migrating to v10 first rather than trying to jump straight to v12. I'd actually got quite a bit further on my own before discovering this package, having attempted to implement something similar myself. uSync is far superior so hoping I can put my previous efforts down to a lesson learnt and finish the job with uSync and contribute anything I can back to the migration project in return.
I've unfortunately got to work on this over the weekend so will hopefully be able to report back with more findings in the next few days.
Hi @ProNotion Could you fix this?
I'm having an issue where neither the content nor the settings are migrated. The packer is able to create the zip successfully, can see a list of content files, contentTypes, docTypes, etc. but running a report or importing the changes does nothing. It fails to detect the changes.
Surprisingly it works well with the local db! The live db is not massive, would hardly have 2000 nodes so not expecting that to be a problem.
@KevinJump Can you think of a reason? Am migrating v8.18 to v10.7.
Thanks
I don't think the packer is required for v8 is it? I could be wrong but thought that was only required for v7 migrations.
@ProNotion The packer is recommended - https://github.com/Jumoo/uSyncMigrations/blob/main/GETTING-STARTED.md#step-one--pick-a-packer
@KevinJump I'm revisiting this in the hope of trying to cut out v10 in my migration process because of the added time overhead but this still seems to be an issue and wondered if you had any ideas on where to start looking at tackling it or if it is a dead end because its possibly occurring within uSync and not uSync migration. The packer file works just fine in v10, in v12 I can get content types, media types and media imported. Content is imported but not available and my suspicion is because the umbracoDocument table is empty.
{"@t":"2024-04-18T09:02:01.9266193Z","@mt":"Document {ContentName} (id={ContentId}) has been published.","ContentName":"Slideshows","ContentId":0,"SourceContext":"Umbraco.Cms.Core.Services.ContentService","ActionId":"4bf375a9-6ac9-4da9-aa95-76484c0e5913","ActionName":"uSync.BackOffice.Controllers.uSyncDashboardApiController.ImportHandler (uSync.BackOffice)","RequestId":"4000009a-0008-f300-b63f-84710c7967bb","RequestPath":"/umbraco/backoffice/usync/usyncdashboardapi/ImportHandler","ProcessId":58616,"ProcessName":"iisexpress","ThreadId":35,"ApplicationId":"70db158a02c3b1c83279642af486f7e5db1ff92b","MachineName":"PN-MEGATRON","Log4NetLevel":"INFO ","HttpRequestId":"91442be2-ae50-4d43-9229-45f07f5c1eed","HttpRequestNumber":10,"HttpSessionId":"b829631a-03e4-e0ba-bfb6-eade6a1ad829"}
{"@t":"2024-04-18T09:02:01.7160329Z","@mt":"Document {ContentName} (id={ContentId}) cannot be published: {Reason}","ContentName":"Box sliders","ContentId":0,"Reason":"parent is not published","SourceContext":"Umbraco.Cms.Core.Services.ContentService","ActionId":"4bf375a9-6ac9-4da9-aa95-76484c0e5913","ActionName":"uSync.BackOffice.Controllers.uSyncDashboardApiController.ImportHandler (uSync.BackOffice)","RequestId":"4000009a-0008-f300-b63f-84710c7967bb","RequestPath":"/umbraco/backoffice/usync/usyncdashboardapi/ImportHandler","ProcessId":58616,"ProcessName":"iisexpress","ThreadId":35,"ApplicationId":"70db158a02c3b1c83279642af486f7e5db1ff92b","MachineName":"PN-MEGATRON","Log4NetLevel":"INFO ","HttpRequestId":"91442be2-ae50-4d43-9229-45f07f5c1eed","HttpRequestNumber":10,"HttpSessionId":"b829631a-03e4-e0ba-bfb6-eade6a1ad829"}
Hummm,
i am not sure so it works in v10 (the content is imported and its all ok?) but in v12 its not ?
I am trying to remember the differences between the versions (there are very few) -
in v10 (and i think v12) there are two passes to the content import the first one creates the content nodes but the second one puts all the properties in and does the final save/publish, its possible something is breaking on the second one ?
If i was troubleshooting this _(you might have already done this) _
- once i have converted the files i would go into the migrated folder (in the
usync/migrated/{string}) and rename the content folder to something else. - then i would create a new content folder and copy over just a few of the content files (you will need the one at the root, as the parent)
- then run the import on just those few files see if anything happens, it will also give you just a lot less debugging.
I would look for any warnings or errors in the umbraco logs for this import they are likey to be the places where something going wrong will be logged.
I would also try v13 (although to be honest i haven't ran migrations on v13 in a while) just to see if it's a bug with v12, if it works in v10 and v13 then we obviously broke something big time in v12.
I am currently a bit v14 swamped! - but if i get some time i will confirm the status of migrations on v12 and v13 see if i can find anything out.
@KevinJump Interestingly it works when I simplified it down to the first 2 levels of the node structures.
In case it is relevant, the 2 nodes I imported also have ContentId: 0 in the logs so that's perhaps a red herring
{"@t":"2024-04-18T15:37:34.1083822Z","@mt":"Document {ContentName} (id={ContentId}) has been published.","ContentName":"UK","ContentId":0,"SourceContext":"Umbraco.Cms.Core.Services.ContentService","ActionId":"f5639b42-49ea-4b09-9397-9ec50c74fdf1","ActionName":"uSync.BackOffice.Controllers.uSyncDashboardApiController.ImportHandler (uSync.BackOffice)","RequestId":"400000c2-000c-ef00-b63f-84710c7967bb","RequestPath":"/umbraco/backoffice/usync/usyncdashboardapi/ImportHandler","ProcessId":41588,"ProcessName":"iisexpress","ThreadId":53,"ApplicationId":"70db158a02c3b1c83279642af486f7e5db1ff92b","MachineName":"PN-MEGATRON","Log4NetLevel":"INFO ","HttpRequestId":"fc2a26b2-74bc-4975-b0e5-9edb8c45047e","HttpRequestNumber":10,"HttpSessionId":"9c0abfcb-fb17-c399-7124-235af848faae"} {"@t":"2024-04-18T15:37:34.7323692Z","@mt":"Document {ContentName} (id={ContentId}) has been published.","ContentName":"United Kingdom","ContentId":0,"SourceContext":"Umbraco.Cms.Core.Services.ContentService","ActionId":"f5639b42-49ea-4b09-9397-9ec50c74fdf1","ActionName":"uSync.BackOffice.Controllers.uSyncDashboardApiController.ImportHandler (uSync.BackOffice)","RequestId":"400000c2-000c-ef00-b63f-84710c7967bb","RequestPath":"/umbraco/backoffice/usync/usyncdashboardapi/ImportHandler","ProcessId":41588,"ProcessName":"iisexpress","ThreadId":53,"ApplicationId":"70db158a02c3b1c83279642af486f7e5db1ff92b","MachineName":"PN-MEGATRON","Log4NetLevel":"INFO ","HttpRequestId":"fc2a26b2-74bc-4975-b0e5-9edb8c45047e","HttpRequestNumber":10,"HttpSessionId":"9c0abfcb-fb17-c399-7124-235af848faae"}
After importing the 2 nodes I restored the content folder and tried to import the remainder and after it finished I am still left with 2 nodes 🤔
my guess (and it is a guess) is that the other nodes are somehow orphaned . as in they don't have a parent node to be attached to? so they are not getting published because the parent somewhere is missing ?
Logically that would make sense but then why would the exact same pack work in v10 and why if I extract 2 files out of the content directory would that work fine but those same two nodes are not present when imported with everything else.
I wondering if this is the source of my issues because this happens for all top-level nodes from the original v7 site and all subsequent imports fail with publish errors because the parent is not published.
Failed to publish FailedPublishPathNotPublishedI will update the issue as/when I do find anything further but in the meantime if anyone has any ideas I'd welcome them.
Hi did you get around the Failed to publish FailedPublishPathNotPublished error ? :)
Hi did you get around the Failed to publish FailedPublishPathNotPublished error ? :)
Due to time pressures, no, I am still going v7 > v10 > v12 to avoid the issue. Sorry I can't be of more help. I would very much like to skip v10 but don't have the time to try and find a solution at present.
Hi did you get around the Failed to publish FailedPublishPathNotPublished error ? :)
Due to time pressures, no, I am still going v7 > v10 > v12 to avoid the issue. Sorry I can't be of more help. I would very much like to skip v10 but don't have the time to try and find a solution at present.
Fair :) I'm trying to convert the nested content in v13, only having this issue !..
So the error are not in v10 ?
@thomashdk My post was in relation to v12 and not v13 so I can't comment I'm afraid but at the moment no, I am not having the issue in v10.