Project

General

Profile

"Orphan" attachments in database - bug?

Added by Anton Antilopa over 10 years ago

On a few Redmine systems I've noticed some attachments without container id and some of those even without disk filename (some do have disk filename set and the file does exist). Is this a Redmine bug? These orphan attachmens appear both in Redmine 2.4 with MySQL and Redmine 2.5 with PostgreSQL on different Linux systems, so it shouldn't be system- or configuration-specific.


Replies (2)

RE: "Orphan" attachments in database - bug? - Added by Jan Niggemann (redmine.org team member) over 10 years ago

When a user attaches a file to an issue, a wiki page, etc., the file is immediately uploaded. Only later, when the form is submitted, it is attached.

From 2.3.0 upwards you can use the rake task rake redmine:attachments:prune to remove uploaded files left unattached for one day.

Edit: Remember to include your RAILS_ENV in the command and see RedmineRake for other rake tasks.

    (1-2/2)