Jul 10
I had Rails 2.0.2 before i started my upgrade. When i executed the typical “sudo gem install rails”, i got the following error:
Bulk updating Gem source index for: http://gems.rubyforge.org/
Updating metadata for 13 gems from http://gems.rubyonrails.org/
………….
complete
Bulk updating Gem source index for: http://gems.rubyforge.org/
ERROR: Error installing rails:
invalid gem format for /Library/Ruby/Gems/1.8/cache/activesupport-2.1.0.gem
Steps to fix this:
- Remove all old activesupport gems from your Library
sudo rm -rf /Library/Ruby/Gems/1.8/cache/activesupport-2.1.0.gem
sudo rm -rf /Library/Ruby/Gems/1.8/cache/activesupport-2.0.2.gem
sudo rm -rf /Library/Ruby/Gems/1.8/cache/activesupport-2.0.991.gem - sudo gem update
- sudo gem install rails
This finally worked.

July 14th, 2008 at 8:50 am
Many thanks! This solved my problem upgrading from Rails 2.0.2 to 2.1.
August 15th, 2008 at 5:33 am
Thanks a lot. You saved me live
August 19th, 2008 at 10:53 am
Amazing, thank you so much for this!