Can attachment-*.tmp files in <confluence_install>\temp folder be deleted?

Jonny Polivka
Contributor
October 29, 2021

We have close to 22 GB of attachment-*.tmp files in <confluence_install>\temp folder, can theses be deleted?    Second to that, can the whole folder be cleaned?

Found some similar questions and KB pages but they old and don't really answer the question.

Running 6.15.6. 

(Goal is to clean up what ever needs to be done before we upgrade to 7.13.x.)

 

Thanks.

2 answers

2 accepted

1 vote
Answer accepted
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 29, 2021

Yes, and not just before an upgrade, you can clear it any time.  Confluence will just re-create anything it needs.  Leave the directory itself there, but feel free to kill all the files and sub-directories it contains.

Just make sure Confluence is not running at the time of delete.  You won't damage your data by leaving it running, but some active processes might break for your people.

Jonny Polivka
Contributor
November 1, 2021

Thanks Nic.

Can it be assumed if the last modified timestamp of the file is a few months old that they can be deleted without issue while the service is running?  

(I'm just itching to delete something but I guess I can hold off till I start the upgrade process.  )

Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 1, 2021

No, but the older they are, the more likely that they won't be in use any more.  Anything dated before the last restart is perfectly safe to kill off without worrying.

I'd check with lsof before deleting more recent temporary files - if a file isn't actively in use, or it's a day old, you can be mostly sure not going to a problem if you remove it (worst case, Confluence does a bit more work recreating what it needs!)

Like Jonny Polivka likes this
1 vote
Answer accepted
Joshua Sneed Contegix
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 29, 2021

Hi Jonny,

Short answer, yes. Long answer, you don't need to as the temp directory will be cleaned by the app. Cheers!

Jonny Polivka
Contributor
November 1, 2021

Thanks Joshua. 

I did read that the files are to be cleaned up but from my research it sounded like there was a bug(?) that was addressed in 7.2.  (https://jira.atlassian.com/browse/CONFSERVER-41622 - see bottom comments) 

Joshua Sneed Contegix
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 1, 2021

Welcome Jonny!
Good catch. Read Nic's post from 10/29 for info around better practices. It does look like periodic maintenance may be necessary in your case, but an upgrade looks to be the solution. Cheers!

Like Jonny Polivka likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
6.15.5
TAGS
AUG Leaders

Atlassian Community Events