Hello,
i've doing a migration from JIRA 4.1 to JIRA 4.4.5 to 6.4.7 and finaly to JIRA cloud.
after the export from 6.4.7 the attachments won't import. getting the following error:
attachements.zip contains a dir attachments with the projects.
the server is running on linux ubuntu when copying to my local windows 7 machine the zip errors because of long file names.
SOLUTION FOUND!
Hi Paulo,
I've already created my own solution. By making a cloud backup en exploring the backup file i found the filenames only have a id number from JIRA not a complete filename with file extention.
After making a python script thas renames all the file name from a complete name to a JIRA file id i can now import the attachments
part of my python script that renames all attachments:
is searches the attachment directory for sub directories when a file is found , the first char until "_" wil be the file name (JIRA file id)
def checkFileNames(): found = 0 reNamed = 0 errors = 0 print "$$$$$$$$$$$$$$ Starting to rename files $$$$$$$$$$$$$" for dirName,subdirList,fileList in os.walk(rootDir): for fname in fileList: found = found+1 if "_" in fname: fileId = (fname[0:fname.find('_')]) print fileId print dirName +" "+fname+" "+fileId+" "+str(subdirList) os.rename (dirName+'/'+fname, dirName+'/'+fileId) reNamed = reNamed+1 else: print "Error "+fname+" not contain _ or already done" errors = errors+1 print "\n Renaming DONE \n found "+str(found)+" files Renamed:"+str(reNamed)+" Errors:"+str(errors)
so the new file tree looks like:
Attachments.zip
|-- Attachments
|-- AAI
|-- (empty)
|-- AANVRAAG
|-- AANVRAAG-1
|-- 28193_Delivery Note-140010129VL-20141210-1131.pdf
|-- AANVRAAG-2
|-- (empty)
|-- AANVRAAG-3
|-- 28189_48822_48822___834174.pdf
|-- AANVRAAG-4
|-- 28190_Quotation-140010209AN-1-20141016-1652.pdf
|-- 28191_CVA goedkeuring JetBrains PhpStorm + Adobe Photoshop Ids xxxxxxxx.pdf
|-- 28268_Delivery Note-140010597VL-20141217-0853.pdf
|-- 28269_Levering PHPStorm.msg
|-- 28297_LicenseCertificate-R187901.pdf
Hope atlassian wil document this as a important solution to the import errors people have when migrating and wil change this as option in the cloud import tool.
Danny
The if block in the script needs to be modified
if
"_"
in fname:
needs to be changed to
if
"_"
in fname and "thumb" not in fname:
After making this change, if the thumbnails are still not visible; please contact Atlassian Support.
Vik
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Danny,
If you are still in trouble, just contact support. We can try running a rsync with your attachments and that should solve the problem.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Yes i'm sure is used the following structure
today i've tried again also i've made a small attachments.zip with the following:
(xxxxxxxx = name)
Two projectsnames AAI and AANVRAAG back-uped from the JIRA server
the following still give a error when uploading
Attachments.zip
|-- Attachments
|-- AAI
|-- (empty)
|-- AANVRAAG
|-- AANVRAAG-1
|-- 28193_Delivery Note-140010129VL-20141210-1131.pdf
|-- AANVRAAG-2
|-- (empty)
|-- AANVRAAG-3
|-- 28189_48822_48822___834174.pdf
|-- AANVRAAG-4
|-- 28190_Quotation-140010209AN-1-20141016-1652.pdf
|-- 28191_CVA goedkeuring JetBrains PhpStorm + Adobe Photoshop Ids xxxxxxxx.pdf
|-- 28268_Delivery Note-140010597VL-20141217-0853.pdf
|-- 28269_Levering PHPStorm.msg
|-- 28297_LicenseCertificate-R187901.pdf
Whats wrong with these files and directory?
please help we have 500+ users to migrate and need a solution otherwise we must look for another program.
Danny
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Danny,
Could you confirm that the attachments.zip file structure is the following:
attachments.zip
|-- Attachments
|-- Projects
In case you are sure everything is fine, then I would suggest you to open a support ticket under support.atlassian.net
Cheers,
Paulo
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.