Thursday, September 25, 2014

Install Ruby 2.1.3 Ubuntu 14.04

Install Ruby 2.1.3 Ubuntu 14.04


  1. Open your terminal
  2. One the menu select edit
  3. On the drop down menu select Profile preferences
  4. Inside the dialog box select the Title and Command
  5. Under 'command' check the Run command as a login shell
  6. Close and reopen the terminal


In the terminal

sudo apt-get install build-essential git-core curl libmysqlclient18 nodejs
curl -L get.rvm.io | bash -s satble
rvm install ruby -2.1.3

rvm use ruby -2.1.3

[2014-09-06 11:19:07] ERROR bad URI `\000\026\000\020\000'.


If you get 

[2014-09-06 11:19:07] ERROR bad URI `\000\026\000\020\000'.
[2014-09-06 11:19:07] ERROR bad URI `\000\026\000\020\000'.
[2014-09-06 11:19:07] ERROR bad Request-Line `\026\003\001\000�\001\000\000\177\003\001PHj�\031\006�L��'.
[2014-09-06 11:19:07] ERROR bad URI `\000\026\000\020\000'. 


You are probably requesting the page via SSL.

WEBrick does not understand SSL.  

Change the URL in your browser to use http instead of https.



I came across this error while running my rails server

[2014-02-04 20:31:12] WARN  Could not determine content-length of response body. Set content-length of the response or set Response#chunked = true
[2014-02-04 20:31:12] WARN  Could not determine content-length of response body. Set content-length of the response or set Response#chunked = true
[2014-02-04 20:31:12] WARN  Could not determine content-length of response body. Set content-length of the response or set Response#chunked = true
[2014-02-04 20:31:12] WARN  Could not determine content-length of response body. Set content-length of the response or se


This is a problem of Webrick. you can use "Thin" instead.
Add this to Gemfile
gem 'thin'
then rails s will use thin instead of Webrick, and the warn will disappear.

You might also find This helpful.