JIRA Project Import warns that there are more than twenty attachment entries that do not exist

Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.

Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Summary

Problem

When attempting to run a project import, the pre-import validation shows the following error message:

1 There are more than twenty attachment entries that do not exist in the attachment directory. See your logs for full details.

The following appears in the atlassian-jira.log:

1 2 2016-05-25 07:53:07,478 JiraTaskExectionThread-70 WARN xxxxxxx 473x1692930x2 mi449q xxxx,xxxx /secure/admin/ProjectImportSelectProject.jspa [imports.project.handler.AttachmentFileValidatorHandler]  The attachment 'ATTACHMENT_FILE_NAME.extension' does not exist at '/jira/atlassian/application-data/jira/import/attachments/PROJECT_KEY/PROJECT_KEY-xxx/xxxxx'. It will not be imported.

Diagnosis

Diagnostic Steps

  • Based on the error message in the atlassian-jira.log:

    1 2 The attachment 'ATTACHMENT_FILE_NAME.extension' does not exist at  '/jira/atlassian/application-data/jira/import/attachments/PROJECT_KEY/PROJECT_KEY-xxx/xxxxx'. It will not be imported.

    The PROJECT_KEY value in the log entry does not actually match the import's target project key.

    For example, the target project to import into has key JSP, while the error message in the log shows some other project key, such as GHS.

Cause

  1. In the target instance, the target project's key has been renamed to match the key of the source project.

    ℹ️ See Editing A Project Key for information on changing a project's key.

  2. To identify if the target project's key has been renamed, the following SQL can be used:

    1 SELECT pkey, ORIGINALKEY FROM project;

    The pkey column is the project's current key, while ORIGINALKEY is the project's previous key.

  3. The importer tool is not able to import the attachments properly due to the target project key being renamed.

Solution

Resolution

Delete the target project and re-create it with the correct project key, instead of renaming it.

  1. As the target project has to be empty for project import to be valid, deleting and re-creating should be fast.

  2. Note that all schemes will have to be re-associated to the newly created project.

    ℹ️ See Restoring Project from Backup for full details.

Updated on April 8, 2025

Still need help?

The Atlassian Community is here for you.