Problems while upgrading from 1.0.5 to 1.2 - content-type header returned as text/plain and html rendering as plain text in browser.

Added by Anoop John over 11 years ago

I had an updated 1.0.5 installation which I tried to upgrade to 1.20 branch.

I did the following

In redmine root folder

svn switch http://redmine.rubyforge.org/svn/branches/1.2-stable
svn update
rake db:migrate RAILS_ENV=production
rake db:migrate:upgrade_plugin_migrations RAILS_ENV=production
rake db:migrate_plugins RAILS_ENV=production
rake tmp:cache:clear
rake tmp:sessions:clear

There were no errors during this process.

However when I try to access the application from the browser it looks like the content is served from the server with text/plain as content type and hence the html is shown as plain text in the browser. For the home page (/) it offers to download the content and says that the content type is unix-directory.

Here are the details about the installation. Can you please guide me in the right direction to troubleshoot/fix this issue.

About your application's environment
Ruby version 1.8.7 (i686-linux)
RubyGems version 1.3.7
Rack version 1.1
Rails version 2.3.11
Active Record version 2.3.11
Active Resource version 2.3.11
Action Mailer version 2.3.11
Active Support version 2.3.11
Application root /home/projects/rails_apps/redminedev
Environment production
Database adapter mysql
Database schema version 20110511000000

About your Redmine plugins
Timesheet Plugin 0.6.0
Stuff To Do Plugin 0.4.0

Replies (6)

RE: Problems while upgrading from 1.0.5 to 1.2 - content-type header returned as text/plain and html rendering as plain text in browser. - Added by Nicolas Kopp about 11 years ago

We have the same issue here. We tried to upgrade from 1.1.2.

We are running a Mongrel-Cluster on Apache on a Win 2003 Server. After successfull redmine upgrade Apache served plain text. Restart of Apache/Mongrel/The whole Server had no effect. Rollback to 1.1.2 worked like a charm. Sticking with 1.1.2 now until someone figured out a solution.

Apache 2.2.19
Ruby version 1.8.7
Rack version 1.1
Rails version 2.3.11
Active Record version 2.3.11
Active Resource version 2.3.11
Action Mailer version 2.3.11
Active Support version 2.3.11

Database via mysql
no plugins

Cheers
Nicolas

RE: Problems while upgrading from 1.0.5 to 1.2 - content-type header returned as text/plain and html rendering as plain text in browser. - Added by Vimal Joseph about 11 years ago

I'm using mongrel/apache/cpanel to run redmine. When I tried to access the installation directly via redmine.host.com:120001 it worked, but when I tried to redirect redmine.host.com via htaccess, using Rewrite URL option in the rails application setup in cpanel, every request reaches the /public directory. I can access files from the directory directly, but redmine is not working. I also added a .htaccess file in the public directory, but it is not making any change.

I dont have any issue with 1.0.5 version, the issue start when I tried to upgrade to 1.2

RE: Problems while upgrading from 1.0.5 to 1.2 - content-type header returned as text/plain and html rendering as plain text in browser. - Added by Hajime Fujita about 11 years ago

I'm running redmine with mongrel, and had the very same issue discussed here.

I found a workaround and it worked for me:
http://stackoverflow.com/questions/2911852/problems-running-ruby-on-rails-apps-on-shared-hosted-server/4876718#4876718

(Actually I had to comment out the "if" statement at the beginning of https://gist.github.com/471663)

Hope this helps.

(1-6/6)