Closed grandchild closed 5 years ago
Hi @grandchild and sorry for the delay to answer this.
If you try unset rvm_path
(maybe with rvmsudo
) and then try again, it works?
Wondering if it's related to https://github.com/rvm/rvm/issues/3977
@grandchild I'm closing this due the lack of feedback. If you have anything new to share, please, feel free to re-open this issue.
@raelgc No it doesn't work
I am having this issue with a fresh rvm install on Ubuntu 19.04.
This is weird: when I run apt-get install -y rvm
from a root shell, with all traces of my non-root username (jik
) eradicated from the environment, when the post-install script runs it still says Creating local gemsets for jik
. Where does it get that jik
from, and why is it trying to create local gemsets for a different user from the user running the post-install script?
Has to be stored in rvm folder, try 'grep -rn jik $rvm_path' of it finds anything then please cross report to rvm/rvm
On Sat, Jul 20, 2019, 06:06 Jonathan Kamens notifications@github.com wrote:
This is weird: when I run apt-get install -y rvm from a root shell, with all traces of my non-root username (jik) eradicated from the environment, when the post-install script runs it still says Creating local gemsets for jik. Where does it get that jik from, and why is it trying to create local gemsets for a different user from the user running the post-install script?
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/rvm/ubuntu_rvm/issues/32?email_source=notifications&email_token=AAALXNSP6SQRJHYSINCJIFTQAKFNHA5CNFSM4GKRDBA2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD2NGBHY#issuecomment-513433759, or mute the thread https://github.com/notifications/unsubscribe-auth/AAALXNUYUWOMDKJ7B5M25FTQAKFNHANCNFSM4GKRDBAQ .
?Has to be stored in rvm folder, try grep -rn jik $rvm_path
of it finds anything then please cross report to rvm/rvm
Nope, that's not it.
The post-install script is looking at the sudo
group in /etc/group
and trying to install for everyone in that group using su
, assuming incorrectly that the rvm
stuff in the environment will be preserved across su
:
# Add sudoers to rvm group
users=`awk -F':' '/^sudo/{print $4}' /etc/group`
IFS=',' read -a array <<< "$users"
for u in "${array[@]}"
do
usermod -a -G rvm $u
if [ ! -f "/home/$u/.rvmrc" ]; then
echo "Creating local gemsets for $u"
su - $u -c 'rvm user gemsets'
fi
Pull request incoming momentarily.
This is fixed by PR #38
Trying to install the package on Ubuntu 16.04.5 LTS the following happens and the package installation basically fails:
Full log:
``` admin@server ~ $ sudo apt install software-properties-common Reading package lists... Done Building dependency tree Reading state information... Done software-properties-common is already the newest version (0.96.20.7). The following packages were automatically installed and are no longer required: linux-headers-4.4.0-138 linux-headers-4.4.0-138-generic linux-image-4.4.0-138-generic linux-image-extra-4.4.0-138-generic linux-signed-image-4.4.0-138-generic Use 'sudo apt autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. admin@server ~ $ sudo apt-add-repository -y ppa:rael-gc/rvm gpg: keyring `/tmp/tmphzbseomb/secring.gpg' created gpg: keyring `/tmp/tmphzbseomb/pubring.gpg' created gpg: requesting key F4E3FBBE from hkp server keyserver.ubuntu.com gpg: /tmp/tmphzbseomb/trustdb.gpg: trustdb created gpg: key F4E3FBBE: public key "Launchpad PPA for Rael" imported gpg: Total number processed: 1 gpg: imported: 1 (RSA: 1) OK admin@server ~ $ sudo apt update Get:1 http://ppa.launchpad.net/rael-gc/rvm/ubuntu xenial InRelease [18.0 kB] Get:2 http://security.ubuntu.com/ubuntu xenial-security InRelease [107 kB] Hit:3 http://us.archive.ubuntu.com/ubuntu xenial InRelease Hit:4 https://releases.wikimedia.org/debian jessie-mediawiki InRelease Get:5 http://us.archive.ubuntu.com/ubuntu xenial-updates InRelease [109 kB] Get:6 http://ppa.launchpad.net/rael-gc/rvm/ubuntu xenial/main amd64 Packages [592 B] Get:7 http://ppa.launchpad.net/rael-gc/rvm/ubuntu xenial/main i386 Packages [592 B] Get:8 http://ppa.launchpad.net/rael-gc/rvm/ubuntu xenial/main Translation-en [276 B] Get:9 http://us.archive.ubuntu.com/ubuntu xenial-backports InRelease [107 kB] Get:10 http://us.archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages [892 kB] Get:11 http://us.archive.ubuntu.com/ubuntu xenial-updates/main i386 Packages [790 kB] Get:12 http://us.archive.ubuntu.com/ubuntu xenial-updates/universe amd64 Packages [715 kB] Get:13 http://us.archive.ubuntu.com/ubuntu xenial-updates/universe i386 Packages [655 kB] Fetched 3,394 kB in 2s (1,584 kB/s) Reading package lists... Done Building dependency tree Reading state information... Done All packages are up to date. admin@server ~ $ sudo apt install rvm Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: linux-headers-4.4.0-138 linux-headers-4.4.0-138-generic linux-image-4.4.0-138-generic linux-image-extra-4.4.0-138-generic linux-signed-image-4.4.0-138-generic Use 'sudo apt autoremove' to remove them. The following additional packages will be installed: bison libbison-dev libgdbm-dev libncurses5-dev libsqlite3-dev sqlite3 Suggested packages: bison-doc ncurses-doc sqlite3-doc The following NEW packages will be installed: bison libbison-dev libgdbm-dev libncurses5-dev libsqlite3-dev rvm sqlite3 0 upgraded, 7 newly installed, 0 to remove and 0 not upgraded. Need to get 2,771 kB of archives. After this operation, 11.0 MB of additional disk space will be used. Do you want to continue? [Y/n] Get:1 http://ppa.launchpad.net/rael-gc/rvm/ubuntu xenial/main amd64 rvm all 1.29.4-1 [940 kB] Get:2 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 libbison-dev amd64 2:3.0.4.dfsg-1 [338 kB] Get:3 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 bison amd64 2:3.0.4.dfsg-1 [259 kB] Get:4 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 libgdbm-dev amd64 1.8.3-13.1 [35.9 kB] Get:5 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 libncurses5-dev amd64 6.0+20160213-1ubuntu1 [175 kB] Get:6 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 libsqlite3-dev amd64 3.11.0-1ubuntu1 [508 kB] Get:7 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 sqlite3 amd64 3.11.0-1ubuntu1 [515 kB] Fetched 2,771 kB in 1s (1,771 kB/s) Selecting previously unselected package libbison-dev:amd64. (Reading database ... 205411 files and directories currently installed.) Preparing to unpack .../libbison-dev_2%3a3.0.4.dfsg-1_amd64.deb ... Unpacking libbison-dev:amd64 (2:3.0.4.dfsg-1) ... Selecting previously unselected package bison. Preparing to unpack .../bison_2%3a3.0.4.dfsg-1_amd64.deb ... Unpacking bison (2:3.0.4.dfsg-1) ... Selecting previously unselected package libgdbm-dev. Preparing to unpack .../libgdbm-dev_1.8.3-13.1_amd64.deb ... Unpacking libgdbm-dev (1.8.3-13.1) ... Selecting previously unselected package libncurses5-dev:amd64. Preparing to unpack .../libncurses5-dev_6.0+20160213-1ubuntu1_amd64.deb ... Unpacking libncurses5-dev:amd64 (6.0+20160213-1ubuntu1) ... Selecting previously unselected package libsqlite3-dev:amd64. Preparing to unpack .../libsqlite3-dev_3.11.0-1ubuntu1_amd64.deb ... Unpacking libsqlite3-dev:amd64 (3.11.0-1ubuntu1) ... Selecting previously unselected package sqlite3. Preparing to unpack .../sqlite3_3.11.0-1ubuntu1_amd64.deb ... Unpacking sqlite3 (3.11.0-1ubuntu1) ... Selecting previously unselected package rvm. Preparing to unpack .../archives/rvm_1.29.4-1_all.deb ... Unpacking rvm (1.29.4-1) ... Processing triggers for man-db (2.7.5-1) ... Processing triggers for install-info (6.1.0.dfsg.1-5) ... Setting up libbison-dev:amd64 (2:3.0.4.dfsg-1) ... Setting up bison (2:3.0.4.dfsg-1) ... update-alternatives: using /usr/bin/bison.yacc to provide /usr/bin/yacc (yacc) in auto mode Setting up libgdbm-dev (1.8.3-13.1) ... Setting up libncurses5-dev:amd64 (6.0+20160213-1ubuntu1) ... Setting up libsqlite3-dev:amd64 (3.11.0-1ubuntu1) ... Setting up sqlite3 (3.11.0-1ubuntu1) ... Setting up rvm (1.29.4-1) ... Creating group 'rvm' Installing RVM to /usr/share/rvm/ Installation of RVM in /usr/share/rvm/ is almost complete: * First you need to add all users that will be using rvm to 'rvm' group, and logout - login again, anyone using rvm will be operating with `umask u=rwx,g=rwx,o=rx`. * To start using RVM you need to run `source /etc/profile.d/rvm.sh` in all your open shell windows, in rare cases you need to reopen all shell windows. * Please do NOT forget to add your users to the rvm group. The installer no longer auto-adds root or users to the rvm group. Admins must do this. Also, please note that group memberships are ONLY evaluated at login time. This means that users must log out then back in before group membership takes effect! Creating local gemsets for admin zsh:1: command not found: rvm dpkg: error processing package rvm (--configure): subprocess installed post-installation script returned error exit status 127 Errors were encountered while processing: rvm E: Sub-process /usr/bin/dpkg returned an error code (1) ```