Attachments 404
Added by Kyle O about 12 years ago
Hi,
I upgraded from redmine 2.0.4 to 2.2.4 and now old attachments yield a 404. The files are stored in redmine_dir/files. The files are there. The database has the appropriate reference to the file, yet I still get a 404.
Help is very much appreciated
Thanks,
Kyle
Example:
redmine.mydomain.com/attachments/download/3446/C20457_Status_order_after_TORI_and_DAY_tradeON.erl
404
The page you were trying to access doesn't exist or has been removed.
mysql:mysql> select * from attachments where id='3446';
3446 | 13429 | Issue | C20457_Status_order_after_TORI_and_DAY_tradeON.erl | 130326114617_C20457_Status_order_after_TORI_and_DAY_tradeON.erl | 7619 | text/x-erlang | d41d8cd98f00b204e9800998ecf8427e | 0 | 109 | 2013-03-26 11:46:18 |
filesystem:
$ ls la /var/www/redmine-2.2.4/files/130326114617_C20457_Status_order_after_TORI_and_DAY_tradeON.erl 1 www-data www-data 7619 2013-04-01 12:43 /var/www/redmine-2.2.4/files/130326114617_C20457_Status_order_after_TORI_and_DAY_tradeON.erl
-rw-rw-r-
Log:
Started GET "/attachments/download/3446/C20457_Status_order_after_TORI_and_DAY_tradeON.erl" for 10.10.162.162 at 2013-04-01 14:36:36 -0400
Processing by AttachmentsController#download as HTML
Parameters: {"id"=>"3446", "filename"=>"C20457_Status_order_after_TORI_and_DAY_tradeON.erl"}
Current user: kyleo (id=26)
Rendered common/error.html.erb within layouts/base (0.1ms)
Rendered plugins/redmine_backlogs/app/views/hooks/_rb_include_scripts.html.erb (2.9ms)
Filter chain halted as :file_readable rendered or redirected
Completed 404 Not Found in 201ms (Views: 193.1ms | ActiveRecord: 3.2ms)
Started GET "/rb/server_variables.js" for 10.10.162.162 at 2013-04-01 14:36:36 -0400
Processing by RbServerVariablesController#index as JS
Current user: kyleo (id=26)
DEPRECATION WARNING: Passing a template handler in the template name is deprecated. You can simply remove the handler name or pass render :handlers => [:erb] instead. (called from realtime at /usr/local/rvm/rubies/ruby-1.9.3-p392/lib/ruby/1.9.1/benchmark.rb:295)
Rendered plugins/redmine_backlogs/app/views/rb_server_variables/show.js.erb (3.1ms)
Completed 200 OK in 6ms (Views: 3.8ms | ActiveRecord: 0.1ms)
Replies (1)
RE: Attachments 404
-
Added by Mark Moorcroft over 11 years ago
I am having the same exact problem. Was this ever resolved? I was trying to migrate redmine data from version 1.x to 3.x. The files are in place and the mysql query shows the file name correctly just as Kyle was finding.
Never mind, I had a directive left over from last week pointing attachments to another directory. Once I removed it things started working.