1

I'm trying to install rvm on redhat 5.5 and I'm getting this error:

[mc@owl-ci ~]$ bash < <( curl http://rvm.beginrescueend.com/releases/rvm-install-head )
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   979  100   979    0     0   8168      0 --:--:-- --:--:-- --:--:--  318k
Cloning into rvm...
remote: Counting objects: 18463, done.
remote: Compressing objects: 100% (4985/4985), done.
remote: Total 18463 (delta 12517), reused 17903 (delta 12002)
Receiving objects: 100% (18463/18463), 3.19 MiB, done.
Resolving deltas: 100% (12517/12517), done.
mkdir: cannot create directory `/archives': Permission denied
mkdir: cannot create directory `/src': Permission denied
mkdir: cannot create directory `/log': Permission denied
mkdir: cannot create directory `/gems': Permission denied
mkdir: cannot create directory `/man': Permission denied
mkdir: cannot create directory `/rubies': Permission denied
mkdir: cannot create directory `/config': Permission denied
mkdir: cannot create directory `/user': Permission denied

I've install rvm before on different machines with no problems.

I'm confused on why it's trying to create directories under the root path, I thought everything went under ~/.rvm (therefore shouldn't have problems with permission)

Austin
  • 3,860
  • 3
  • 23
  • 25
  • 1
    Maybe you have a ~/.rvmrc or /etc/rvmrc that sets $rvm_path? (that's what I could figure from the install script) – StackExchange saddens dancek Mar 23 '11 at 22:54
  • It's the install script that's failing (it runs the install script from the bottom of the rvm-install-head script) – Austin Mar 23 '11 at 23:01
  • True. I haven't ever used rvm but i tried installing. I get the same errors and some more after that, but in the end I get an installation in ~/.rvm -- well, at least there's something in there. I guess you should report a bug, it can't be normal to get errors during an install. – StackExchange saddens dancek Mar 23 '11 at 23:22

3 Answers3

8

Only use RVM 1.5.1+ or latest head.

You may now install as user or root. Do not use the system-wide script any longer.

bash < <( curl -s -k https://rvm.beginrescueend.com/install/rvm )

For the most recent information and best practices on the correct way to install RVM, please read the documentation website. Also be sure to read the RVM basics documentation.

~Wayne

Wayne E. Seguin
  • 1,601
  • 1
  • 11
  • 11
  • Welcome Wayne, haven't seen you on here before, but your presence and knowledge will be a great asset to the site. There's a lot of RVM questions, and new users who can gain from your knowledge! RVM rocks! – the Tin Man Mar 24 '11 at 03:42
2

Okay so apparently my old answer wouldn't actually give you a functioning rvm installation. There appears to be a very recent bug that I will report. In the meantime, follow the instructions here:

http://rvm.io/rvm/install/

Under the section "Installing / updating the latest rvm from the latest source tarball"

Old Answer:

Try downloading the rvm install script: curl http://rvm.beginrescueend.com/releases/rvm-install-head > rvm-install-head

Then find the line: rvm_path="${rvm_path:-"$HOME/.rvm"}"

and add "export" in the front: export rvm_path="${rvm_path:-"$HOME/.rvm"}"

Save and run the modified file: bash < rvm-install-head

mpapis
  • 52,729
  • 14
  • 121
  • 158
Dave
  • 36
  • 2
  • The old answer got me farther than before and looked to work. But yes, it didn't give me a functioning rvm install. I'll look into those instructions. Thanks for all your help! – Austin Mar 23 '11 at 23:40
  • 1
    New answer works with one gotcha: the post-install message says to place [[ -s "$rvm_path/scripts/rvm" ]] && source "$rvm_path/scripts/rvm" at the bottom of bash profile but $rvm_path isn't defined, so this is the correct one (which is on the website instructions): [[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" – Austin Mar 23 '11 at 23:44
0

It looks like 1.3.0 is broken for the moment. Checkout 1.2.9 in ~/.rvm/src/rvm for a working version.

asm
  • 718
  • 7
  • 9