JIRA application startup or shutdown displays llegalStateException zip file closed error
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
Symptoms
The following appears in the atlassian-jira.log
during startup or shutdown:
1
2
3
4
5
6
7
8
9
10
11
12
2012-05-04 13:33:46,966 main ERROR [osgi.container.felix.FelixOsgiContainerManager] JarContent: Unable to read bytes.
java.lang.IllegalStateException: zip file closed
at java.util.zip.ZipFile.ensureOpen(Unknown Source)
at java.util.zip.ZipFile.getEntry(Unknown Source)
at java.util.jar.JarFile.getEntry(Unknown Source)
at org.apache.felix.framework.util.JarFileX.getEntry(JarFileX.java:61)
at org.apache.felix.framework.cache.JarContent.getEntryAsBytes(JarContent.java:120)
at org.apache.felix.framework.ModuleImpl$ModuleClassLoader.findClass(ModuleImpl.java:1738)
at org.apache.felix.framework.ModuleImpl.findClassOrResourceByDelegation(ModuleImpl.java:716)
at org.apache.felix.framework.ModuleImpl.access$200(ModuleImpl.java:73)
at org.apache.felix.framework.ModuleImpl$ModuleClassLoader.loadClass(ModuleImpl.java:1690)
at java.lang.ClassLoader.loadClass(Unknown Source)
Cause
These log messages indicate a plugin has failed to unregister itself, either on startup or shutdown. There are several bugs that contribute to this behaviour, specifically:
JIRA Fisheye Plugin - JRASERVER-24453 - Unable to read bytes error on JIRA startup
Behaviours Plugin - JBHV-79
Script Runner - GRV-134
Resolution
If the workarounds in the provided bugs above do not resolve the issue, then we must identify the problematic plugin:
If the JIRA application is starting:
Disable all user plugins by enabling Safe Mode ('Administration' -> 'Manage Add-ons' (or 'Find New Add-ons') -> 'Enable Safe Mode');
Start enabling plugins one by one until the error message returns;
ℹ️ Try to enable the plugin which was having problem first.
If the JIRA application is not starting:
Backup and move all plugins out of the
$JIRA_HOME/plugins/installed-plugins
folder so that it is emptyStart JIRA
One by one, move each plugin back into the
installed-plugins
folder followed by a JIRA restart to confirm which plugin is causing the error
Was this helpful?