Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Permission denied when building native extensions with ruby 2.1.0 #93

Open
ghost opened this issue Feb 28, 2014 · 6 comments
Open

Permission denied when building native extensions with ruby 2.1.0 #93

ghost opened this issue Feb 28, 2014 · 6 comments

Comments

@ghost
Copy link

ghost commented Feb 28, 2014

It seems like there is a problem with the permissions inside the extensions directory when installing a gem which builds a native extension. This does not happen with 2.0.0-p451.

platform: ubuntu 13.10

~$ rbenv -v
rbenv 0.4.0-89-g14bc162

~$ gem install bson_ext
Building native extensions.  This could take a while...
ERROR:  While executing gem ... (Errno::EACCES)
  Permission denied @ dir_s_mkdir - /opt/rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/extensions/x86_64-linux/2.1.0-static/bson_ext-1.9.2

$ ls -ald /opt/rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/extensions/x86_64-linux/
drwxr-sr-x 3 rbenv rbenv 4096 Feb 24 16:37 /opt/rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/extensions/x86_64-linux/
@lucke84
Copy link

lucke84 commented Apr 2, 2014

+1

@aderyabin
Copy link

I have the same issue!

@Freyskeyd
Copy link

same here

@conradwt
Copy link

conradwt commented Sep 2, 2014

Has this issue been resolved because I'm seeing similar issues when I attempt to install nokogiri using bundler? BTW, I provisioned the server using root user and deployed with Capistrano 3.2.1 using the deploy user. At this time, the deploy user is a member of the rbenv group.

@sdarwin
Copy link

sdarwin commented Feb 16, 2016

to fix the problem manually (adjusting the ruby version or replacing it with a variable) :

chmod -R g+w /opt/rbenv/versions/2.2.3

@gsaslis
Copy link

gsaslis commented Jun 28, 2016

same problem here with 2.3.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants