Upgrade or Export Fails due to GenericDataSourceException Communications Link Failure
Symptoms
The below error has been seen during the export step of an in-place upgrade. Attempting an XML backup will yield the same error.
The following appears in the atlassian-jira.log
:
2013-01-18 09:00:46,463 main ERROR [atlassian.jira.upgrade.UpgradeManagerImpl] Error occurred during export before upgrade: com.atlassian.core.AtlassianCoreException: Error in action: com.atlassian.jira.action.admin.DataExport@128a9b7f, result: error
Error exporting data: org.ofbiz.core.entity.GenericDataSourceException: SQL Exception while executing the following:SELECT ID, groupid, FIELDTYPE, FIELD, OLDVALUE, OLDSTRING, NEWVALUE, NEWSTRING FROM changeitem (Communications link failure
The last packet successfully received from the server was 4,478 milliseconds ago. The last packet sent successfully to the server was 171,783 milliseconds ago.). If necessary, auto-export can be disabled; see http://www.atlassian.com/software/jira/docs/latest/upgrade/autoexport.html
com.atlassian.core.AtlassianCoreException: Error in action: com.atlassian.jira.action.admin.DataExport@128a9b7f, result: error
Error exporting data: org.ofbiz.core.entity.GenericDataSourceException: SQL Exception while executing the following:SELECT ID, groupid, FIELDTYPE, FIELD, OLDVALUE, OLDSTRING, NEWVALUE, NEWSTRING FROM changeitem (Communications link failure
Cause
The only known cause at this moment is due to a large database backup. JIRA may struggle communicating with the database management system while attempting to generating an XML backup of a large instance (>4 GB heap). Adding validation query as documented in Surviving Connection Closures and configuring the ulimit (Too many open files error in Jira server) will not correct this issue.
Workaround
Please disable the auto-export option by setting the property, jira.autoexport=false
in the $JIRAHOME/jira-config.properties
file and restarting JIRA. Please make a backup using your native db tools before attempting this.
See Making changes to the jira-config.properties
file for more information.