-
Bug
-
Resolution: Fixed
-
High
-
None
-
None
-
None
-
72
-
Severity 3 - Minor
-
1
Issue Summary
Attachments are lost when migrating using the CMAC from server to cloud.
Environment
Confluence Cloud
Steps to Reproduce
- Set up Confluence Server (5.10 to latest) with a production (i.e. non-H2) database
- Set up a Space, create a page and attach multiple images to the page
- Install the latest Cloud Migration Assistant for Confluence)
- Create and run a new plan to migrate the new space, and no users
- Wait for the plan to be successfully completed
- Review the imported data in the cloud
Expected Results
All images appear correctly
Actual Results
Attachments are broken.
Images do not display. Attachments may give an error with
`Attachment File Not Found` `The attachment you were trying to download could not be found in the attachment file store. Either the file has been deleted manually or there was an error in removing the record of the attachment from Confluence.` `If this attachment is no longer required you can delete it from Confluence on the attachments page. Otherwise, you will need to attach a new copy.` `<< Back to attachments page`
The below exception is thrown in the log file:
message: Requested attachments not found in Filestore, so serving it locally. attachmentId: xxxxxxxx
Notes
The cases reported, affected only space migration that was done using the Confluence Migration Assist for Cloud app, if we use the "Import a Confluence Space" feature from the Adminstration section, the issue it is not reproducible.
If all the attachments are missing in a space, it is likely a different issue such as the export from an older, unsupported version of Confluence.
On Confluence Cloud the attachments that are missing can be identified with as having no propertyname = 'FILESTORE_ID' in the contentproperties table, but having other propertyname data such as FILESIZE.
One notable cause we've discovered is related to this issue
which has been fixed in Confluence 6.15.3 and above. If the attachments are attached to a page, and the page has drafts and is deleted, then the attachments are not necessarily deleted if they are referenced in the draft. If those attachments are then referenced on another page in another space then they won't migrate.
Workaround
1. Clear the MIG_ATTACHMENT table prior to remigrating any spaces
2. Delete and re-import the affected space.
Notes for Support Engineers
If a customer reports this case, please provide for the developers
- A full Confluence Support Zip
- The ... > Storage Format of a page from Confluence Server and Confluence Cloud
- The URL of the Page in Confluence Server and in Confluence Cloud
- From Confluence Server the output of
Confluence Server
select * from mig_attachments; select * from mig_cloud_site; select content.*, contentproperties.*, spaces.*, mig_attachment.* from public.content join public.contentproperties on content.contentid = contentproperties.contentid join public.spaces on content.spaceid = spaces.spaceid left outer join public.mig_attachment on content.contentid = mig_attachment.attachmentid where content.contenttype = 'ATTACHMENT' and content.prevver is null order by content.contentid desc; select mig_step.planid, mig_step.starttime, mig_task.executionstatus, mig_step.steptype, mig_step.stepconfig, mig_task.spacekey from mig_step left join mig_task on mig_task.id = mig_step.taskid where steptype='CONFLUENCE_IMPORT';
- From Confluence Cloud the output of
Confluence Cloud
select content.*, contentproperties.*, spaces.* from content join contentproperties on content.contentid = contentproperties.contentid join public.spaces on content.spaceid = spaces.spaceid where content.contenttype = 'ATTACHMENT' and content.prevver is null order by content.contentid desc;
- relates to
-
MIG-193 Missing attachments in Confluence after migrating via Assistant
- Closed
-
MOVE-7639 Loading...
- depended on by
-
CMP-1761 Loading...
- is related to
-
MOVE-708 Loading...
- mentioned in
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...