Project Import failure due to required plugin custom field in Jira server
When trying to project import you hit an on-screen error that looks like the following despite having the same version of JIRA and plugins indicated.
The backup project 'JIRA' requires custom field named 'Date of First Response' with full key 'com.atlassian.jira.ext.charting:firstresponsedate'. In the current instance of JIRA the plugin is at version '1.5', but this custom field was not installed in the backup data. You may want to create an XML backup with this version of the plugin installed. The backup project 'JIRA' requires custom field named 'Time in Status' with full key 'com.atlassian.jira.ext.charting:timeinstatus'. In the current instance of JIRA the plugin is at version '1.5', but this custom field was not installed in the backup data. You may want to create an XML backup with this version of the plugin installed.
This usually happens because of inconsistencies in custom fields that plugins might or might not have created in your environments. There is currently a bug ticket for this issue. - JRA-28480Getting issue details... STATUS
Prior to going through this resolution, please ensure all requirements as listed in our Restoring a Project from Backup documentation have been met.
We will load different sets of data into a separate JIRA instance in order to minimize custom field issues that arise from differences in usage.
PRD = Production data backup
SRC = Source data backup
STG = Staging data backup
- Have a copy of your
<JIRA-home>/plugin/installed-pluginsfolder from production ready (plugins zip).
- Have a backup of your production data ready (PRD).
- Have a backup of your source data (SRC).
- Install JIRA on a separate staging instance and unpack the plugins zip from your production server in to the same location. We are trying to emulate your production instance.
- Import the XML backup from (SRC) to your staging instance.
- Make an XML backup of your staging instance, (STG).
- Shutdown your staging JIRA instance.
- Using the Connecting JIRA to a Database documentation, create a new database for your staging environment and point to it with the Using the JIRA Configuration Tool documentation.
- Restart your staging JIRA instance. This will rebuild the database structure, using the new database.
- Restore XML on the JIRA staging instance startup using the (PRD) backup.
- Import the project from the (STG) backup.
- After the (PRD) to staging import is successful, generate another backup (final).
- Backup your Production instance.
- Import the (final) backup into Production.
In some cases, after installing the required plugins in the source instance, a restart is required. Then, produce the backup and try the import again. If this does not fix the problem, please see the following.
- Get the ID of the problematic custom field in your target JIRA instance (Custom Field > Configure), the ID of that custom field will shown at the end of the URL.
- Edit the
entities.xmlof the backup, search and replace the ID of that custom field with ID retrieve from step 1.
- Save the
entities.xmlafter all the changes on the remaining custom field ID if has any.
- Perform the project import again using the edited