Jira Data center 7.10.2 on AWS
Postresql - RDS
Last couple days we are having issues with attachments. Frequently Attachment configuration in admin console become disabled. Even after we enable we get following errors.
During attachment action on issue we get:
-
File "Confluence-con.jpg" was not uploaded
An error occured while attaching Confluence-con.jpg: Could not save attachment data from stream.
--------------
Log reports following trace - Any help will be appreciated.
2018-11-03 00:45:46,063 HealthCheck:thread-2 WARN ServiceRunner [c.a.t.j.healthcheck.support.AttachmentHealthCheck] There was a RuntimeException when testing the attachment {0}
java.lang.NullPointerException
at com.atlassian.jira.issue.attachment.AttachmentKeys.from(AttachmentKeys.java:34)
at com.atlassian.jira.issue.attachment.AttachmentKeys.from(AttachmentKeys.java:30)
at com.atlassian.jira.issue.attachment.AttachmentKeyMapper.fromAttachment(AttachmentKeyMapper.java:5)
at com.atlassian.jira.issue.attachment.BackwardCompatibleAttachmentStore.getAttachment(BackwardCompatibleAttachmentStore.java:210)
at com.atlassian.jira.issue.managers.DefaultAttachmentManager.streamAttachmentContent(DefaultAttachmentManager.java:727)
... 3 filtered
at java.lang.reflect.Method.invoke(Method.java:498)
at com.atlassian.plugin.util.ContextClassLoaderSettingInvocationHandler.invoke(ContextClassLoaderSettingInvocationHandler.java:26)
at com.sun.proxy.$Proxy24.streamAttachmentContent(Unknown Source)
... 3 filtered
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)
at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.doInvoke(ServiceInvoker.java:56)
at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:60)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:70)
at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:53)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.eclipse.gemini.blueprint.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:57)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133)
at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)
at com.sun.proxy.$Proxy2278.streamAttachmentContent(Unknown Source)
at com.atlassian.troubleshooting.jira.healthcheck.support.AttachmentHealthCheck.canFindAndOpenAttachment(AttachmentHealthCheck.java:120)
at com.atlassian.troubleshooting.jira.healthcheck.support.AttachmentHealthCheck.doCheck(AttachmentHealthCheck.java:82)
at com.atlassian.troubleshooting.jira.healthcheck.support.AbstractSupportHealthCheck.check(AbstractSupportHealthCheck.java:23)
at com.atlassian.troubleshooting.healthcheck.impl.PluginSuppliedSupportHealthCheck.check(PluginSuppliedSupportHealthCheck.java:49)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
2018-11-03 00:45:46,065 HealthCheck:thread-2 ERROR ServiceRunner [c.a.t.j.healthcheck.support.AbstractSupportHealthCheck] Unhandled error during healthcheck
java.lang.NullPointerException
at com.atlassian.troubleshooting.jira.healthcheck.support.AttachmentHealthCheck.doCheck(AttachmentHealthCheck.java:96)
at com.atlassian.troubleshooting.jira.healthcheck.support.AbstractSupportHealthCheck.check(AbstractSupportHealthCheck.java:23)
at com.atlassian.troubleshooting.healthcheck.impl.PluginSuppliedSupportHealthCheck.check(PluginSuppliedSupportHealthCheck.java:49)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
2018-11-03 00:45:46,066 HealthCheckWatchdog:thread-4 WARN ServiceRunner [c.a.t.healthcheck.concurrent.SupportHealthCheckTask] Unable to complete execution of health check Attachments due to an exception
java.util.concurrent.ExecutionException: java.lang.NullPointerException
at java.util.concurrent.FutureTask.report(FutureTask.java:122)
at java.util.concurrent.FutureTask.get(FutureTask.java:206)
at com.atlassian.troubleshooting.healthcheck.concurrent.SupportHealthCheckTask.getFutureWithTimeout(SupportHealthCheckTask.java:88)
at com.atlassian.troubleshooting.healthcheck.concurrent.SupportHealthCheckTask.lambda$runAsync$0(SupportHealthCheckTask.java:68)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.NullPointerException
at com.atlassian.troubleshooting.jira.healthcheck.support.AttachmentHealthCheck.doCheck(AttachmentHealthCheck.java:96)
at com.atlassian.troubleshooting.jira.healthcheck.support.AbstractSupportHealthCheck.check(AbstractSupportHealthCheck.java:23)
at com.atlassian.troubleshooting.healthcheck.impl.PluginSuppliedSupportHealthCheck.check(PluginSuppliedSupportHealthCheck.java:49)
... 4 more
2018-11-03 00:45:46,215 HealthCheck:thread-2 WARN ServiceRunner [o.a.h.client.protocol.ResponseProcessCookies] Invalid cookie header: "Set-Cookie: AWSALB=aEQF2cM8BFVvboGNsUCuWxR0MsWKIUwitKpprfc1AGouezTEKF9anHkLVS5TmUQ0afQ8SmEt0AJ+r0TRsSUeoOK6S8P3Us4e6VXAH4YEfltyLPMwCwKtr5f67fy4; Expires=Sat, 10 Nov 2018 00:45:46 GMT; Path=/". Invalid 'expires' attribute: Sat, 10 Nov 2018 00:45:46 GMT
2018-11-03 00:45:46,399 HealthCheck:thread-1 WARN ServiceRunner [o.a.h.client.protocol.ResponseProcessCookies] Invalid cookie header: "Set-Cookie: AWSALB=8T2MguidPoplxj2MsMd3kNU67c7iAJejaKYE6yKEm3Mmp+vwkoeVk0gyUnINhmoIdnCrpIRgU31PoQ+4iM+vhfknaSjJYIVuYxjYeIovmV0QXgqd4gVNHjo34D6H; Expires=Sat, 10 Nov 2018 00:45:46 GMT; Path=/". Invalid 'expires' attribute: Sat, 10 Nov 2018 00:45:46 GMT
2018-11-03 00:45:46,413 HealthCheck:thread-1 WARN ServiceRunner [o.a.h.client.protocol.ResponseProcessCookies] Invalid cookie header: "Set-Cookie: AWSALB=udeiOEbofWGAb5qfQUnZaa6D9PPAxeOTsSmTFvgnLqfWa9UgMS3r7i0F5nmWemqW7RACtjkWQoihu0YBPVK3lHh5IsOi/zlsQe2yU0X4/oedPLwjiXxjBgQGFrOJ; Expires=Sat, 10 Nov 2018 00:45:46 GMT; Path=/". Invalid 'expires' attribute: Sat, 10 Nov 2018 00:45:46 GMT
2018-11-03 00:45:46,617 HealthCheck:thread-1 WARN ServiceRunner [o.a.h.client.protocol.ResponseProcessCookies] Invalid cookie header: "Set-Cookie: AWSALB=x2W0XC6pwjhZWX5clsb66s00D9lUCGxqSn7mk5rSYWyRaqRUVdMxHvwWAh2+dequouQ5Av8kt6nKEAsxMhyi/tQDBIH3cpielOqvUPmQrVpoD15rePm9prS6eLAh; Expires=Sat, 10 Nov 2018 00:45:46 GMT; Path=/". Invalid 'expires' attribute: Sat, 10 Nov 2018 00:45:46 GMT
------------
When I try to import a project with attachments using project configurator it fails on permission issues and import has following errors in each of the attchments
---
ERROR 01:50:04,167 Unable to create issue file attachment with name 'DevCloud PCFaaS Connectivity.pptx'.
com.atlassian.jira.web.util.AttachmentException: Got error while saving attachment DevCloud PCFaaS Connectivity.pptx: Got exception while saving attachment in attachment store. Exception: Could not save attachment data from stream. caused by: Permission denied
at com.atlassian.jira.issue.managers.DefaultAttachmentManager$4.apply(DefaultAttachmentManager.java:477)
at com.atlassian.jira.issue.managers.DefaultAttachmentManager$4.apply(DefaultAttachmentManager.java:472)
at com.atlassian.fugue.Either$LeftProjection.map(Either.java:713)
at com.atlassian.jira.issue.managers.DefaultAttachmentManager.raiseExceptionOnError(DefaultAttachmentManager.java:472)
at com.atlassian.jira.issue.managers.DefaultAttachmentManager.createAttachmentCopySourceFile(DefaultAttachmentManager.java:226)
at com.atlassian.jira.imports.project.DefaultProjectImportPersister.createAttachment(DefaultProjectImportPersister.java:439)
at com.atlassian.jira.imports.project.handler.AttachmentPersisterHandler$1.run(AttachmentPersisterHandler.java:92)
at com.atlassian.jira.util.concurrent.BoundedExecutor$1.run(BoundedExecutor.java:50)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: com.atlassian.jira.issue.attachment.AttachmentWriteException: Could not save attachment data from stream.
at com.atlassian.jira.issue.attachment.store.LocalTemporaryFileStore.copyStreamToFile(LocalTemporaryFileStore.java:50)
at com.atlassian.jira.issue.attachment.store.LocalTemporaryFileStore.createTemporaryFile(LocalTemporaryFileStore.java:42)
at com.atlassian.jira.issue.attachment.store.DefaultFileSystemAttachmentStore$6.call(DefaultFileSystemAttachmentStore.java:237)
at com.atlassian.jira.issue.attachment.store.DefaultFileSystemAttachmentStore$6.call(DefaultFileSystemAttachmentStore.java:234)
at com.atlassian.util.concurrent.Executors$DefaultSubmitter$CallableRunner.run(Executors.java:62)
at com.atlassian.util.concurrent.LimitedExecutor$Runner.run(LimitedExecutor.java:93)
... 3 more
Caused by: java.io.IOException: Permission denied
at java.io.UnixFileSystem.createFileExclusively(Native Method)
at java.io.File.createTempFile(File.java:2024)
at com.atlassian.jira.issue.attachment.store.LocalTemporaryFileStore.copyStreamToFile(LocalTemporaryFileStore.java:47)
... 8 more