title: how to install the latest version of rails on ubuntu 11.10?
body: <p>I want to install rails 3.2.1 on ubuntu 11.10.
  I already installed rbenv, ruby-build.</p>
  
  <p>When I run </p>
  
  <pre><code>gem install rails
  </code></pre>
  
  <p>it tells me</p>
  
  <pre><code>Successfully installed rails-3.2.1
  1 gem installed
  Installing ri documentation for rails-3.2.1...
  Installing RDoc documentation for rails-3.2.1...
  </code></pre>
  
  <p>then after rbenv rehash, if I run "rails", it cannot find the binary file. So I guess rails is NOT installed. How can I do?</p>
  
  <p>edit:</p>
  
  <pre><code>~ » gem environment                                                                                                                                                                                                                
  RubyGems Environment:
    - RUBYGEMS VERSION: 1.8.15
    - RUBY VERSION: 1.9.3 (2011-10-30 patchlevel 0) [x86_64-linux]
    - INSTALLATION DIRECTORY: /home/jafar/.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1
    - RUBY EXECUTABLE: /home/jafar/.rbenv/versions/1.9.3-p0/bin/ruby
    - EXECUTABLE DIRECTORY: /home/jafar/.rbenv/versions/1.9.3-p0/bin
    - RUBYGEMS PLATFORMS:
      - ruby
      - x86_64-linux
    - GEM PATHS:
       - /home/jafar/.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1
       - /home/jafar/.gem/ruby/1.9.1
    - GEM CONFIGURATION:
       - :update_sources =&gt; true
       - :verbose =&gt; true
       - :benchmark =&gt; false
       - :backtrace =&gt; false
       - :bulk_threshold =&gt; 1000
    - REMOTE SOURCES:
       - http://rubygems.org/
  </code></pre>
  
  <p>edit 2 :</p>
  
  <p>gem list tells me the rails gem is installed. When I search for the rails binary I find this :</p>
  
  <pre><code>~ » find . -name rails
  ./.oh-my-zsh/plugins/rails
  ./Downloads/robbyrussell-oh-my-zsh-3629270/plugins/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/railties-3.2.1/guides/code/getting_started/script/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/railties-3.2.1/bin/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/railties-3.2.1/lib/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/railties-3.2.1/lib/rails/generators/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/railties-3.2.1/lib/rails/generators/rails/app/templates/script/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/railties-3.2.1/lib/rails/generators/rails/plugin_new/templates/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/sass-rails-3.2.4/test/fixtures/engine_project/script/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/sass-rails-3.2.4/test/fixtures/engine_project/test/dummy/script/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/sass-rails-3.2.4/test/fixtures/scss_project/script/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/sass-rails-3.2.4/test/fixtures/sass_project/script/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/sass-rails-3.2.4/lib/sass/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/sass-rails-3.2.4/lib/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/activerecord-3.2.1/lib/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/actionmailer-3.2.1/lib/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/jquery-rails-2.0.0/lib/jquery/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/sass-3.1.12/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/coffee-rails-3.2.2/lib/coffee/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/gems/coffee-rails-3.2.2/lib/rails
  ./.rbenv/versions/1.9.3-p0/lib/ruby/gems/1.9.1/bin/rails
  </code></pre>
  
  <p>The rails binary should be in ~/.rbenv/shims but it's not. ~/.rbenv/shims is in my PATH</p>