Sign up ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have gone through a lot of blogs and tutorials (including Beginning Rails 3) and now I have a messed up Ubuntu (It runs on VMWare) that I do not like it.

Main problem is that based on Beginning Rails 3 I have installed Ruby 1.9.1 but Rails 3 insists that it needs Ruby 1.9.2 to run ... and I have failed till this moment to handle that. RVM installation failed too (some where in the process, the progress percentage freezes on 17%).

I am a windows guy and a .NET developer (nuts if you prefer). But this amount of time for just getting started is a nightmare!

And since I do not know how to clean up Ubuntu I think I should install a new Ubuntu!


share|improve this question
I'd recommend this book for help on installation – Sathya Dec 1 '10 at 13:34
Thankyou very much! – Kaveh Shahbazian Dec 1 '10 at 14:29

3 Answers 3

up vote 0 down vote accepted

sudo apt-get install ruby1.9.1 installs 1.9.2 on Debian. Weird? It's because 1.9.1 is ABI version; the package version field correctly states that it is 1.9.2.

share|improve this answer
Thanks but it says: sudo: aptitude: command not found. – Kaveh Shahbazian Dec 1 '10 at 11:56
Sorry, I've completely forgot about the last modification in Ubuntu which removes aptitude from default install; you should use apt-get instead. – whitequark Dec 1 '10 at 12:01
Thanks; I have done that but ruby -v gives me ruby 1.9.1p376... but which ruby returns the correct path /usr/local/bin/ruby. Did I forget something? – Kaveh Shahbazian Dec 1 '10 at 12:52
if you installed ruby via apt-get, it definetly doesnt install itself into /usr/local .. you propably have installed ruby to /usr/local by some other means and your $PATH has /usr/local/bin before /usr/bin. Try: "/usr/bin/ruby -v" and "/usr/local/bin/ruby -v" and check the versions.. – rasjani Dec 1 '10 at 21:22
Thanks; /usr/bin/ruby -v gives me 1.8.7 and /usr/local/bin/ruby -v gives 1.9.1p378 - I thought apt-get would overwrite /usr/local/bin/ruby, shouldn't it? – Kaveh Shahbazian Dec 1 '10 at 22:18

The solution to getting ruby 1.9.2 installed is to use RVM. RVM, the ruby version manager, makes it very easy to install and use the latest version of Ruby. I've written a short tutorial on getting it up and running:

After you're up and running you tell RVM to always use 1.9.2:

rvm --default use 1.9.2

after getting ruby installed through rvm. It's pretty simple to get rails going by installing the gem:

gem install rails
share|improve this answer

Best way to have multiple ruby version is to use rvm. after installing rvm you can install multiple ruby version simply by

rvm install 1.8.7
rvm install 1.9.2
rvm install jruby

switching is even more easy, type (in terminal)

rvm use 1.8.7 --default #to use rvm for this terminal session and also sets ruby 1.8.7 as default ruby version
ruby -v #should give ruby version set for current session
ruby use 1.9.2 #sets different ruby to be used for this session

for complete installation instruction see here

share|improve this answer
Please don't always post the exact same answer to all questions. This one already had an answer suggesting using RVM (as well as several others to which you've posted this very same text). – slhck Aug 8 '11 at 13:49
@slhck has concisely made the point already, but I thought I'd just step up and strengthen this warning a little. Copy-paste answers are generally not welcome here, you can provide the same details in more than one answer across the site, but tailor each answer them to the question posed, and don't obviously duplicate previous older answers on the questions you are tackling. – DMA57361 Aug 8 '11 at 14:04

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.