System Error Uploading Profile Picture
Platform Notice: Data Center Only - This article only applies to Atlassian apps 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
When uploading a profile picture, the following appears in Confluence:
System Error
A system error has occurred - our apologies\!
Please contact your Confluence administrator to create a support issue on our support system at [http://support.atlassian.com] with the following information:
a description of your problem and what you were doing at the time it occurred
cut & paste the error and system information found below
attach the application server log file (if possible).
We will respond as promptly as possible.
Thank you\!
Cause:
java.lang.RuntimeException: There was a problem retrieving the previous version of the Attachment data for Attachment 'Attachment: null v.1 (179667215)'.
at com.atlassian.confluence.pages.persistence.dao.hibernate.HibernateAttachmentDataDao.saveDataForAttachmentVersion(HibernateAttachmentDataDao.java:141)
caused by: com.atlassian.confluence.pages.AttachmentDataNotFoundException: No AttachmentData object was returned when it was expected
at com.atlassian.confluence.pages.persistence.dao.hibernate.HibernateAttachmentDataDao.getAttachmentDataForAttachment(HibernateAttachmentDataDao.java:63)
Stack Trace: [hide\]
java.lang.RuntimeException: There was a problem retrieving the previous version of the Attachment data for Attachment 'Attachment: null v.1 (179667215)'.
at com.atlassian.confluence.pages.persistence.dao.hibernate.HibernateAttachmentDataDao.saveDataForAttachmentVersion(HibernateAttachmentDataDao.java:141)
at com.atlassian.confluence.pages.persistence.dao.hibernate.AbstractHibernateAttachmentDao.saveNewAttachmentVersion(AbstractHibernateAttachmentDao.java:204)
at com.atlassian.confluence.pages.DefaultAttachmentManager.saveNewAttachmentVersion(DefaultAttachmentManager.java:55)
at com.atlassian.confluence.pages.AbstractAttachmentManager.saveAttachment(AbstractAttachmentManager.java:89)
at com.atlassian.confluence.pages.DelegatorAttachmentManager.saveAttachment(DelegatorAttachmentManager.java:87)
at sun.reflect.GeneratedMethodAccessor1705.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
Cause
There was a problem retrieving the previous version of the Attachment data.
Resolution
Warning: Backup your database before proceeding.
Before running any SQL in this article, create a full backup of your Jira database. This is a database-level operation with no undo other than restoring from backup. Only proceed if you're comfortable running SQL directly against the Jira database, and test on a staging or cloned environment first, wherever possible.
List the affected profile pictures:
SELECT * from attachments where TITLE='<profile picture>' and CREATOR='<user>' and ATTACHMENT_COMMENT='Uploaded Profile Picture';Remove the record from the database:
DELETE FROM attachments where ATTACHMENTID='<attachmentid>';
Was this helpful?