Safe to clear out/delete the contents of the temp directory inside the data folder?

5 posts by 2 authors in: Forums > CMS Builder
Last Post: October 4, 2022   (RSS)

By Codee - September 29, 2022

Hello,

Is it safe to delete the contents of the temp directory inside the data folder in CMSB?

Thanks in advance.

By daniel - October 3, 2022

Hi Codee,

Yes, the temp directory is intended for files that could be deleted at any time, so it should generally be safe to clear it out (except for the ".htaccess" and "index.html" files; these are important for security). It is possible that custom code could be using it for more "permanent" storage, but it would be irregular. As an extra precaution, you could skip deleting any recently created files which would reduce the chances of deleting something that's still in use.

Thanks,

Daniel
Technical Lead
interactivetools.com

By daniel - October 4, 2022

Hi Codee,

Without examining the site directly it's difficult to say that the files are 100% safe to delete, but I can say that I've never come across an issue caused by someone clearing their temp folder. The most common use for this folder is to temporarily store files as they're being uploaded or created, however, sometimes the "cleanup" process is interrupted or prevented for some reason, and the temporary file is not deleted automatically.

Can you tell me a few example filenames that are in your temp folder? If they end in ".tmp" then they are genuine temp files and can be deleted.

Thanks,

Daniel
Technical Lead
interactivetools.com

By Codee - October 4, 2022

Nearly ALL of them are graphics files I was uploading during testing with the webp converter (it's on another post on this forum and you helped me out with it). I knew what they were and was instinctively just going to delete but thought I'd better ask first (which I did). My hesitancy is because on the newer Corel programs (on my pc) the original graphics are autosaved into a special Corel folder...With all the wonderful improvements to CMSB I just wanted to be sure that they didn't need to be saved.  

Thanks, I'll clear most of them out. 

Cheers!