2
votes

I am trying to install ruby using rvm. I get the following error on the below command -

rvm install 1.9.3

Extracting rubygems-latest-1.8 ...

ERROR: Error running 'gunzip < /usr/share/ruby-rvm/archives/rubygems-latest-1.8.tgz | tar xf - -C /usr/share/ruby-rvm/src', please read /usr/share/ruby-rvm/log/ruby-1.9.3-p194/rubygems.extract.log

Installing rubygems for /usr/share/ruby-rvm/rubies/ruby-1.9.3-p194/bin/ruby

ERROR: Error running 'GEM_PATH="/usr/share/ruby-rvm/gems/ruby-1.9.3-p194:/usr/share/ruby-rvm/gems/ruby-1.9.3-p194@global:/usr/share/ruby-rvm/gems/ruby-1.9.3-p194:/usr/share/ruby-rvm/gems/ruby-1.9.3-p194@global" GEM_HOME="/usr/share/ruby-rvm/gems/ruby-1.9.3-p194" "/usr/share/ruby-rvm/rubies/ruby-1.9.3-p194/bin/ruby" "/usr/share/ruby-rvm/src/rubygems-latest-1.8/setup.rb"', please read /usr/share/ruby-rvm/log/ruby-1.9.3-p194/rubygems.install.log

Below is the extract from the log file -

[2012-07-25 09:29:03] gunzip < /usr/share/ruby-rvm/archives/rubygems-latest-1.8.tgz | tar xf - -C /usr/share/ruby-rvm/src

gzip: stdin: not in gzip format tar: This does not look like a tar archive tar: Exiting with failure status due to previous errors [2012-07-25 09:31:08] gunzip < /usr/share/ruby-rvm/archives/rubygems-latest-1.8.tgz | tar xf - -C /usr/share/ruby-rvm/src

gzip: stdin: not in gzip format tar: This does not look like a tar archive tar: Exiting with failure status due to previous errors

1
Per the instructions, what do you see in /usr/share/ruby-rvm/log/ruby-1.9.3-p194/rubygems.extract.log?Phrogz
I have added the details from the log file in the question.murtaza52
Could it be the rvm itself? I have v1.6.9 that I installed through apt. stackoverflow.com/questions/8398479/…murtaza52
Possible duplicate of rvm install: ruby installation error; looks like a reinstall of RVM may fix your woes.Phrogz

1 Answers

4
votes

you are using version of RVM broken by packaging for Ubuntu, use this answer to fix: https://stackoverflow.com/a/9056395/497756