Ruby 2.2.0 installation errror on Ubuntu 14.04 x64 1GB RAM

January 28, 2015 3.1k views

Hi,

I have Ubuntu 14.04 x64 1GB RAM and existing Wordpress application on my server.
I want to install RoR and create temporary application on RoR.

Now I am using this guide to install ROR:

https://www.digitalocean.com/community/tutorials/how-to-deploy-a-rails-app-with-passenger-and-nginx-on-ubuntu-14-04

At step sudo make install where I am installing ruby I got this error:

Target: x86_64-linux-gnu 
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.8.2-19ubuntu1' --with-bugurl=file:///usr/share/doc/gcc-4.8/README.Bugs --enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.8 --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.8 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libmudflap --enable-plugin --with-system-zlib --disable-browser-plugin --enable-java-awt=gtk --enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64/jre --enable-java-home --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64 --with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.8-amd64 --with-arch-directory=amd64 --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --enable-objc-gc --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu 
Thread model: posix 
gcc version 4.8.2 (Ubuntu 4.8.2-19ubuntu1) 
making enc 
make[1]: Entering directory `/home/edgars/ruby/ruby-2.2.0' 
make[1]: Nothing to be done for `enc'. 
make[1]: Leaving directory `/home/edgars/ruby/ruby-2.2.0' 
making srcs under enc 
make[1]: Entering directory `/home/edgars/ruby/ruby-2.2.0' 
make[1]: Nothing to be done for `srcs'. 
make[1]: Leaving directory `/home/edgars/ruby/ruby-2.2.0' 
generating transdb.h 
transdb.h unchanged 
making trans 
make[1]: Entering directory `/home/edgars/ruby/ruby-2.2.0' 
make[1]: Nothing to be done for `./enc/trans'. 
make[1]: Leaving directory `/home/edgars/ruby/ruby-2.2.0' 
making encs 
make[1]: Entering directory `/home/edgars/ruby/ruby-2.2.0' 
make[1]: Leaving directory `/home/edgars/ruby/ruby-2.2.0' 
generating makefile exts.mk 
Failed to configure -test-/win32/console. It will not be installed. 
Failed to configure -test-/win32/dln. It will not be installed. 
Failed to configure -test-/win32/dln/empty. It will not be installed. 
Failed to configure -test-/win32/fd_setsize. It will not be installed. 
Failed to configure dbm. It will not be installed. 
Failed to configure gdbm. It will not be installed. 
Failed to configure tk. It will not be installed. 
Failed to configure tk/tkutil. It will not be installed. 
Failed to configure win32. It will not be installed. 
Failed to configure win32ole. It will not be installed. 
make[1]: Entering directory `/home/edgars/ruby/ruby-2.2.0' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/array/resize' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/array/resize' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bignum' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bignum' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bug-3571' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bug-3571' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bug-3662' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bug-3662' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bug-5832' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bug-5832' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bug_reporter' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/bug_reporter' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/class' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/class' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/debug' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/debug' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/exception' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/exception' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/fatal' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/fatal' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/file' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/file' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/float' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/float' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/funcall' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/funcall' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/hash' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/hash' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/iseq_load' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/iseq_load' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/iter' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/iter' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/load/dot.dot' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/load/dot.dot' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/marshal/compat' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/marshal/compat' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/marshal/usr' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/marshal/usr' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/method' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/method' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/num2int' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/num2int' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/path_to_class' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/path_to_class' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/postponed_job' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/postponed_job' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/printf' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/printf' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/proc' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/proc' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/rational' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/rational' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/recursion' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/recursion' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/st/foreach' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/st/foreach' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/st/numhash' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/st/numhash' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/st/update' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/st/update' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/string' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/string' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/struct' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/struct' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/symbol' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/symbol' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/tracepoint' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/tracepoint' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/typeddata' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/typeddata' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/wait_for_single_fd' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/wait_for_single_fd' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/win32/console' 
make[2]: Nothing to be done for `all'. 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/win32/console' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/win32/dln' 
make[2]: Nothing to be done for `all'. 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/win32/dln' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/win32/dln/empty' 
make[2]: Nothing to be done for `all'. 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/win32/dln/empty' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/win32/fd_setsize' 
make[2]: Nothing to be done for `all'. 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/-test-/win32/fd_setsize' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/bigdecimal' 
installing default bigdecimal libraries 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/bigdecimal' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/continuation' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/continuation' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/coverage' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/coverage' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/date' 
installing default date_core libraries 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/date' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/dbm' 
make[2]: Nothing to be done for `all'. 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/dbm' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/digest' 
installing digest libraries 
installing default digest libraries 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/digest' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/bubblebabble' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/bubblebabble' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/md5' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/md5' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/rmd160' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/rmd160' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/sha1' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/sha1' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/sha2' 
installing default sha2 libraries 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/digest/sha2' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/etc' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/etc' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/fcntl' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/fcntl' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/fiber' 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/fiber' 
make[2]: Entering directory `/home/edgars/ruby/ruby-2.2.0/ext/fiddle' 
linking shared-object fiddle.so 
/usr/bin/ld: ./libffi-3.2.1/.libs/libffi.a(raw_api.o): relocation R_X86_64_32S against `.rodata' can not be used when making a shared object; recompile with -fPIC 
./libffi-3.2.1/.libs/libffi.a: error adding symbols: Bad value 
collect2: error: ld returned 1 exit status 
make[2]: *** [../../.ext/x86_64-linux/fiddle.so] Error 1 
make[2]: Leaving directory `/home/edgars/ruby/ruby-2.2.0/ext/fiddle' 
make[1]: *** [ext/fiddle/all] Error 2 
make[1]: Leaving directory `/home/edgars/ruby/ruby-2.2.0' 
make: *** [build-ext] Error 2

As there no specific error message, google cant help me.

Any solution on this ?

Thanks in advance.

3 Answers

I got some resulution. Now accessing my_ip:8080 I got internal error.

In Nginx files I can see

2015/01/28 15:00:58 [alert] 17752#0: *19 Cannot stat '/home/edgars/Proj/config.ru; This error means that the Nginx worker process (PID 17752, running as UID 33) does not have permission to access this file. Please read the manual to learn how to fix this problem: section 'Troubleshooting' -> 'Upon accessing the web app, Nginx reports a "Permission denied" error'; Extra info, client: 212.93.115.122, server: 104.131.95.146, request: "GET / HTTP/1.1", host: "104.131.95.146:8080"

There is also Ruby on Rails as one click install app. It uses nginx as web server.

You're probably missing libffi-dev:

$ sudo apt-get install libffi-dev

fixed it for me

Have another answer? Share your knowledge.