This is a common question, but none of the answers seem to solve the issue. I get the usual: You have already activated rack 1.4.1, but your Gemfile requires rack 1.3.
This problem is also common when you clone the project from a repository (ejem. github), because it might have the Gemsfile.lock already. So the gems it has might be different than the ones your enviroment has already loaded. So, firts get a backup of your Gemsfile.lock, then remove it and run bundle install --without production .It will install all your dependecies according with the GemFile. Be aware that if the application is old it might not work with the environment on your machine.