Friday, January 13, 2012

Overcoming RVM Command Not Found Error in Ubuntu 11.04 Server


I faced this weird issue of rvm command not being found, inspite of installing it quite a few times.

Please find details wrt the issue:-

I am trying to set up RVM On Ubuntu 11.04 Server.

Making use of a multi user install..

The error I am currently getting is:-

    $  sudo bash -s stable < <(curl -s )
    -sh: Syntax error: redirection unexpected

I am not sure whats wrong with the command, as I am using an exact copy of the command from the [RVM installation guide]

Any inputs, could be really helpful..

When I login as root, I am able to atleast run the command and install rvm. But the rvm gives me a command not found.

    root@host:/home/s244574# sudo bash -s stable < <(curl -s )
    Downloading RVM from wayneeseguin branch stable
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
    100  796k  100  796k    0     0   139k      0  0:00:05  0:00:05 --:--:--  261k
    Upgrading the RVM installation in /root/.rvm/
    installing - /root/.rvm/man/man1/rvm.1.gz -
    installing - /root/.rvm/man/man1/rvm.1 -
        RVM system user group 'rvm' exists, proceeding with installation.
    Upgrade Notes:
      * No new notes to display.
    # RVM:  Shell scripts enabling management of multiple ruby environments.
    # RTFM:
    # HELP: (#rvm on
    # Screencast:
    # In case of any issues read output of 'rvm requirements' and/or 'rvm notes'
    Upgrade of RVM in /root/.rvm/ is complete.
    # root,
    #   Thank you for using RVM!
    #   I sincerely hope that RVM helps to make your life easier and more enjoyable!!!
    # ~Wayne
    root@host:/home/s244574# rvm
    No command 'rvm' found, but there are 19 similar ones
    rvm: command not found

Few points to note, wrt what I tried:-

Initially, rvm was installed for me in the path:-


but somehow rvm command doesn't seem to recognize the path where it is insalled, if I am guessing correctly.

I also tried [install if root only] , the installation path changes(to /root/.rvm/ ) but still I face the same issue.

I have a user, with loginname "user1" is there a way, I can let the user1 identify the rvm path, which has the post installation files, so that the command can be recognized

Thank you..


The Fix which did the trick for me:-

source ~/.bash_profile 

No comments:

Post a Comment