• Replace Ruby 1.8.x with version 1.9.x

    We recently replaced ruby 1.8.6 on a Ubuntu 8.04 Server with Ruby 1.9.1. Follow these steps to remove the old ruby from the system, but be warned that it may not be as simple for you.

    First thing was to remove the old ruby1.8. We had installed this from the Ubuntu package installer so removing it was as simple as running:

    sudo apt-get uninstall ruby

    or

    sudo apt-get uninstall ruby1.8


    If you wish you can also remove any redundant packages with:

    sudo apt-get autoremove

    Now download, make and install the latest stable ruby release. You can find the latest release here https://www.ruby-lang.org/en/downloads/. Do the following to download and install the latest ruby:

    
    cd ~/sources
    sudo wget ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.1-p129.tar.gz 
    sudo tar -xzvf ruby-1.9.1-p129.tar.gz
    cd ruby-1.9.1-p129/
    sudo ./configure
    sudo make
    sudo make install
    

    Now make sure you reinstall rails.

    sudo gem install rails

    One nice feature of the new ruby 1.9 is you will no longer need to install rubygems (version 2.3.3 is current on ruby 1.9.1-p129) as they are now built into ruby.

    ***update***
    I found a post by Benedict Eastaugh that has a more in depth write up on this here. Well worth a read especially if you have problems with Mongrel and ruby 1.9.




    Share

    Leave a reply