Passenger is currently running the wrong version of Ruby. I have installed the newer version 2.1.5 but cannot get this command to finish compiling.
passenger-install-apache2-module
Passanger Version
Phusion Passenger version 4.0.55
Apache Version
Server version: Apache/2.4.7 (Ubuntu)
RVM Version
rvm 1.26.4 (latest) by Wayne E. Seguin <[email protected]>, Michal Papis <[email protected]> [https://rvm.io/]
Ruby Versions
rvm rubies
ruby-2.1.2 [ x86_64 ]
=* ruby-2.1.5 [ x86_64 ]
# => - current
# =* - current && default
# * - default
echo $PATH
/home/ubuntu/.rvm/gems/ruby-2.1.5/bin:/home/ubuntu/.rvm/gems/ruby-2.1.5@global/bin:/home/ubuntu/.rvm/rubies/ruby-2.1.5/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/home/ubuntu/.rvm/bin:/home/ubuntu/.rvm/bin
which gem
/home/ubuntu/.rvm/rubies/ruby-2.1.5/bin/gem
RVM INFO
ruby-2.1.5:
system:
uname: "Linux ip-172-31-33-140 3.13.0-24-generic #46-Ubuntu SMP Thu Apr 10 19:11:08 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux"
system: "ubuntu/14.04/x86_64"
bash: "/bin/bash => GNU bash, version 4.3.11(1)-release (x86_64-pc-linux-gnu)"
zsh: " => not installed"
rvm:
version: "rvm 1.26.4 (latest) by Wayne E. Seguin <[email protected]>, Michal Papis <[email protected]> [https://rvm.io/]"
updated: "14 hours 8 minutes 49 seconds ago"
path: "/home/ubuntu/.rvm"
ruby:
interpreter: "ruby"
version: "2.1.5p273"
date: "2014-11-13"
platform: "x86_64-linux"
patchlevel: "2014-11-13 revision 48405"
full_version: "ruby 2.1.5p273 (2014-11-13 revision 48405) [x86_64-linux]"
homes:
gem: "/home/ubuntu/.rvm/gems/ruby-2.1.5"
ruby: "/home/ubuntu/.rvm/rubies/ruby-2.1.5"
binaries:
ruby: "/home/ubuntu/.rvm/rubies/ruby-2.1.5/bin/ruby"
irb: "/home/ubuntu/.rvm/rubies/ruby-2.1.5/bin/irb"
gem: "/home/ubuntu/.rvm/rubies/ruby-2.1.5/bin/gem"
rake: "/home/ubuntu/.rvm/gems/ruby-2.1.5/bin/rake"
environment:
PATH: "/home/ubuntu/.rvm/gems/ruby-2.1.5/bin:/home/ubuntu/.rvm/gems/ruby-2.1.5@global/bin:/home/ubuntu/.rvm/rubies/ruby-2.1.5/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/home/ubuntu/.rvm/bin:/home/ubuntu/.rvm/bin"
GEM_HOME: "/home/ubuntu/.rvm/gems/ruby-2.1.5"
GEM_PATH: "/home/ubuntu/.rvm/gems/ruby-2.1.5:/home/ubuntu/.rvm/gems/ruby-2.1.5@global"
MY_RUBY_HOME: "/home/ubuntu/.rvm/rubies/ruby-2.1.5"
IRBRC: "/home/ubuntu/.rvm/rubies/ruby-2.1.5/.irbrc"
RUBYOPT: ""
gemset: ""
/etc/apache2/mods-available/passenger.conf
<IfModule mod_passenger.c>
PassengerRoot /usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini
PassengerRuby /home/ubuntu/.rvm/gems/ruby-2.1.5/wrappers/ruby
</IfModule>
/etc/apache2/mods-enabled/passenger.conf
PassengerDefaul Ruby /usr/bin/ruby
/etc/apache2/mods-available/passenger.load
LoadModule passenger_module /usr/lib/apache2/modules/mod_passenger.so
/etc/apache2/mods-enabled/passenger.load
LoadModule passenger_module /usr/lib/apache2/modules/mod_passenger.so
/etc/apache2/apache2.conf
LoadModule passenger_module /home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/buildout/apache2/mod_passenger.so
<IfModule mod_passenger.c>
PassengerRoot /home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45
PassengerDefaultRuby /home/ubuntu/.rvm/gems/ruby-2.1.2/wrappers/ruby
</IfModule>
The Problem
I would like to run passenger-install-apache2-module un order to get generate the mod_passenger.so for the the ruby version so that I can set it in the apache2.conf.
Currently
locate mod_passenger.so
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/buildout/apache2/mod_passenger.so
The Error
When I go into the new ruby gem folder and try to run the install passenger command. It compiles for a very long time and then says broken pipe. I've tried the following commands and have gotten the same error
rvmsudo /home/ubuntu/.rvm/gems/ruby-2.1.5/gems/passenger-4.0.55/bin/passenger-install-apache2-module
sudo /home/ubuntu/.rvm/gems/ruby-2.1.5/gems/passenger-4.0.55/bin/passenger-install-apache2-module
/home/ubuntu/.rvm/gems/ruby-2.1.5/gems/passenger-4.0.55/bin/passenger-install-apache2-module
rvmsudo /home/ubuntu/.rvm/gems/ruby-2.1.5/bin/passenger-install-apache2-module
sudo /home/ubuntu/.rvm/gems/ruby-2.1.5/bin/passenger-install-apache2-module
/home/ubuntu/.rvm/gems/ruby-2.1.5/bin/passenger-install-apache2-module
I have uninstalled and installed passenger between efforts as well. Here is the error.
Welcome to the Phusion Passenger Apache 2 module installer, v4.0.55.
This installer will guide you through the entire installation process. It
shouldn't take more than 3 minutes in total.
Here's what you can expect from the installation process:
1. The Apache 2 module will be installed for you.
2. You'll learn how to configure Apache.
3. You'll learn how to deploy a Ruby on Rails application.
Don't worry if anything goes wrong. This installer will advise you on how to
solve any problems.
Press Enter to continue, or Ctrl-C to abort.
--------------------------------------------
Which languages are you interested in?
Use <space> to select.
If the menu doesn't display correctly, press '!'
(*) Ruby
( ) Python
> ( ) Node.js
( ) Meteor
--------------------------------------------
Checking for required software...
* Checking for C compiler...
Found: yes
Location: /usr/bin/cc
* Checking for C++ compiler...
Found: yes
Location: /usr/bin/c++
* Checking for Curl development headers with SSL support...
Found: yes
curl-config location: /usr/bin/curl-config
Header location: /usr/include/curl/curl.h
Version: libcurl 7.35.0
Usable: yes
Supports SSL: yes
* Checking for OpenSSL development headers...
Found: yes
Location: /usr/include/openssl/ssl.h
* Checking for Zlib development headers...
Found: yes
Location: /usr/include/zlib.h
* Checking for Apache 2...
Found: yes
Location of httpd: /usr/sbin/apache2
Apache version: 2.4.7
* Checking for Apache 2 development headers...
Found: yes
Location of apxs2: /usr/bin/apxs2
* Checking for Rake (associated with /home/ubuntu/.rvm/gems/ruby-2.1.5/wrappers/ruby)...
Found: yes
Location: /home/ubuntu/.rvm/gems/ruby-2.1.5/wrappers/rake
* Checking for OpenSSL support for Ruby...
Found: yes
* Checking for RubyGems...
Found: yes
* Checking for Ruby development headers...
Found: yes
Location: /home/ubuntu/.rvm/rubies/ruby-2.1.5/include/ruby-2.1.0/ruby.h
* Checking for rack...
Found: yes
* Checking for Apache Portable Runtime (APR) development headers...
Found: yes
Location: /usr/bin/apr-1-config
Version: 1.5.1
* Checking for Apache Portable Runtime Utility (APU) development headers...
Found: yes
Location: /usr/bin/apu-1-config
Version: 1.5.3
--------------------------------------------
Sanity checking Apache installation...
All good!
--------------------------------------------
Compiling and installing Apache 2 module...
cd /home/ubuntu/.rvm/gems/ruby-2.1.5/gems/passenger-4.0.55
# /home/ubuntu/.rvm/gems/ruby-2.1.5/wrappers/rake RELEASE=yes apache2:clean apache2
rm -rf buildout/cache
rm -rf buildout/common/libboost_oxt.a buildout/common/libboost_oxt
rm -f buildout/common/libpassenger_common/Logging.o buildout/common/libpassenger_common/Exceptions.o buildout/common/libpassenger_common/Utils/SystemTime.o buildout/common/libpassenger_common/Utils/StrIntUtils.o buildout/common/libpassenger_common/Utils/IOUtils.o buildout/common/libpassenger_common/Utils.o
rm -f buildout/common/libpassenger_common/Utils/Base64.o buildout/common/libpassenger_common/Utils/CachedFileStat.o buildout/common/libpassenger_common/Utils/LargeFiles.o buildout/common/libpassenger_common/ApplicationPool2/Implementation.o buildout/common/libpassenger_common/ApplicationPool2/AppTypes.o buildout/common/libpassenger_common/AgentsStarter.o buildout/common/libpassenger_common/AgentsBase.o buildout/common/libpassenger_common/Utils/MD5.o buildout/common/libpassenger_common/Utils/fib.o buildout/common/libpassenger_common/Utils/jsoncpp.o
rm -f buildout/common/libpassenger_common/agents/LoggingAgent/FilterSupport.o
rm -rf buildout/common/libpassenger_common
rm -rf buildout/agents/
rm -rf buildout/apache2/module_libboost_oxt.a buildout/apache2/module_libboost_oxt
rm -f buildout/apache2/module_libpassenger_common/Logging.o buildout/apache2/module_libpassenger_common/Exceptions.o buildout/apache2/module_libpassenger_common/Utils/SystemTime.o buildout/apache2/module_libpassenger_common/Utils/StrIntUtils.o buildout/apache2/module_libpassenger_common/Utils/IOUtils.o buildout/apache2/module_libpassenger_common/Utils.o
rm -f buildout/apache2/module_libpassenger_common/Utils/Base64.o buildout/apache2/module_libpassenger_common/Utils/CachedFileStat.o buildout/apache2/module_libpassenger_common/Utils/LargeFiles.o buildout/apache2/module_libpassenger_common/ApplicationPool2/Implementation.o buildout/apache2/module_libpassenger_common/ApplicationPool2/AppTypes.o buildout/apache2/module_libpassenger_common/AgentsStarter.o buildout/apache2/module_libpassenger_common/AgentsBase.o buildout/apache2/module_libpassenger_common/Utils/MD5.o buildout/apache2/module_libpassenger_common/Utils/fib.o buildout/apache2/module_libpassenger_common/Utils/jsoncpp.o
rm -f buildout/apache2/module_libpassenger_common/agents/LoggingAgent/FilterSupport.o
rm -rf buildout/apache2/module_libpassenger_common
rm -rf buildout/apache2/Configuration.o buildout/apache2/Bucket.o buildout/apache2/Hooks.o buildout/apache2/mod_passenger.o buildout/apache2/mod_passenger.so
mkdir -p buildout/apache2/module_libpassenger_common
c++ -Iext -Iext/common -Iext/libev -fPIC -DLINUX -D_REENTRANT -D_GNU_SOURCE -I/usr/include/apr-1.0 -I/usr/include/apr-1.0 -I/usr/include -pipe -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -I/usr/include/apache2 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -fcommon -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -Wno-attributes -ggdb -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -std=gnu++11 -Wno-unused-local-typedefs -DHASH_NAMESPACE="__gnu_cxx" -DHASH_MAP_HEADER="<hash_map>" -DHASH_MAP_CLASS="hash_map" -DHASH_FUN_H="<hash_fun.h>" -o buildout/apache2/module_libpassenger_common/Logging.o -c ext/common/Logging.cpp
c++ -Iext -Iext/common -Iext/libev -fPIC -DLINUX -D_REENTRANT -D_GNU_SOURCE -I/usr/include/apr-1.0 -I/usr/include/apr-1.0 -I/usr/include -pipe -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -I/usr/include/apache2 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -fcommon -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -Wno-attributes -ggdb -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -std=gnu++11 -Wno-unused-local-typedefs -DHASH_NAMESPACE="__gnu_cxx" -DHASH_MAP_HEADER="<hash_map>" -DHASH_MAP_CLASS="hash_map" -DHASH_FUN_H="<hash_fun.h>" -o buildout/apache2/module_libpassenger_common/Exceptions.o -c ext/common/Exceptions.cpp
mkdir -p buildout/apache2/module_libpassenger_common/Utils
c++ -Iext -Iext/common -Iext/libev -fPIC -DLINUX -D_REENTRANT -D_GNU_SOURCE -I/usr/include/apr-1.0 -I/usr/include/apr-1.0 -I/usr/include -pipe -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -I/usr/include/apache2 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -fcommon -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -Wno-attributes -ggdb -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -std=gnu++11 -Wno-unused-local-typedefs -DHASH_NAMESPACE="__gnu_cxx" -DHASH_MAP_HEADER="<hash_map>" -DHASH_MAP_CLASS="hash_map" -DHASH_FUN_H="<hash_fun.h>" -o buildout/apache2/module_libpassenger_common/Utils/SystemTime.o -c ext/common/Utils/SystemTime.cpp
c++ -Iext -Iext/common -Iext/libev -fPIC -DLINUX -D_REENTRANT -D_GNU_SOURCE -I/usr/include/apr-1.0 -I/usr/include/apr-1.0 -I/usr/include -pipe -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -I/usr/include/apache2 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -fcommon -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -Wno-attributes -ggdb -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -std=gnu++11 -Wno-unused-local-typedefs -DHASH_NAMESPACE="__gnu_cxx" -DHASH_MAP_HEADER="<hash_map>" -DHASH_MAP_CLASS="hash_map" -DHASH_FUN_H="<hash_fun.h>" -o buildout/apache2/module_libpassenger_common/Utils/StrIntUtils.o -c ext/common/Utils/StrIntUtils.cpp
c++ -Iext -Iext/common -Iext/libev -fPIC -DLINUX -D_REENTRANT -D_GNU_SOURCE -I/usr/include/apr-1.0 -I/usr/include/apr-1.0 -I/usr/include -pipe -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -I/usr/include/apache2 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -fcommon -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -Wno-attributes -ggdb -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -std=gnu++11 -Wno-unused-local-typedefs -DHASH_NAMESPACE="__gnu_cxx" -DHASH_MAP_HEADER="<hash_map>" -DHASH_MAP_CLASS="hash_map" -DHASH_FUN_H="<hash_fun.h>" -o buildout/apache2/module_libpassenger_common/Utils/IOUtils.o -c ext/common/Utils/IOUtils.cpp
c++ -Iext -Iext/common -Iext/libev -fPIC -DLINUX -D_REENTRANT -D_GNU_SOURCE -I/usr/include/apr-1.0 -I/usr/include/apr-1.0 -I/usr/include -pipe -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -I/usr/include/apache2 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -fcommon -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -Wno-attributes -ggdb -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -std=gnu++11 -Wno-unused-local-typedefs -DHASH_NAMESPACE="__gnu_cxx" -DHASH_MAP_HEADER="<hash_map>" -DHASH_MAP_CLASS="hash_map" -DHASH_FUN_H="<hash_fun.h>" -o buildout/apache2/module_libpassenger_common/Utils.o -c ext/common/Utils.cpp
mkdir -p buildout/apache2/module_libpassenger_common/ApplicationPool2
c++ -Iext -Iext/common -Iext/libev -fPIC -DLINUX -D_REENTRANT -D_GNU_SOURCE -I/usr/include/apr-1.0 -I/usr/include/apr-1.0 -I/usr/include -pipe -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -I/usr/include/apache2 -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -fcommon -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -Wno-attributes -ggdb -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -std=gnu++11 -Wno-unused-local-typedefs -DHASH_NAMESPACE="__gnu_cxx" -DHASH_MAP_HEADER="<hash_map>" -DHASH_MAP_CLASS="hash_map" -DHASH_FUN_H="<hash_fun.h>" -o buildout/apache2/module_libpassenger_common/ApplicationPool2/AppTypes.o -c ext/common/ApplicationPool2/AppTypes.cpp
Write failed: Broken pipe
Passenger Error Log Here is most of what passenger says in the browser, as you can see it is still running 2.1.2
Your Ruby version is 2.1.2, but your Gemfile specified 2.1.5 (Bundler::RubyVersionMismatch)
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/bundler-1.7.4/lib/bundler/definition.rb:385:in `validate_ruby!'
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/bundler-1.7.4/lib/bundler.rb:117:in `setup'
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/bundler-1.7.4/lib/bundler/setup.rb:17:in `<top (required)>'
/home/ubuntu/.rvm/rubies/ruby-2.1.2/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:128:in `require'
/home/ubuntu/.rvm/rubies/ruby-2.1.2/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:128:in `rescue in require'
/home/ubuntu/.rvm/rubies/ruby-2.1.2/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:39:in `require'
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/lib/phusion_passenger/loader_shared_helpers.rb:258:in `block in run_load_path_setup_code'
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/lib/phusion_passenger/loader_shared_helpers.rb:361:in `running_bundler'
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/lib/phusion_passenger/loader_shared_helpers.rb:256:in `run_load_path_setup_code'
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/helper-scripts/rack-preloader.rb:100:in `preload_app'
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/helper-scripts/rack-preloader.rb:158:in `<module:App>'
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/helper-scripts/rack-preloader.rb:29:in `<module:PhusionPassenger>'
/home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/helper-scripts/rack-preloader.rb:28:in `<main>'
Application root
/etc/projects/myapp
Environment (value of RAILS_ENV, RACK_ENV, WSGI_ENV, NODE_ENV and PASSENGER_APP_ENV)
production
Ruby interpreter command
/home/ubuntu/.rvm/gems/ruby-2.1.2/wrappers/ruby
User and groups
uid=1000(ubuntu) gid=1000(ubuntu) groups=1000(ubuntu),4(adm),20(dialout),24(cdrom),25(floppy),27(sudo),29(audio),30(dip),44(video),46(plugdev),102(netdev)
Environment variables
APACHE_PID_FILE = /var/run/apache2/apache2.pid
rvm_bin_path = /home/ubuntu/.rvm/bin
GEM_HOME = /home/ubuntu/.rvm/gems/ruby-2.1.2
APACHE_RUN_USER = www-data
SHELL = /bin/bash
IRBRC = /home/ubuntu/.rvm/rubies/ruby-2.1.2/.irbrc
PYTHONUNBUFFERED = 1
PASSENGER_DEBUG_DIR = /tmp/passenger.spawn-debug.XXXXdOCV4S
SERVER_PORT = 80
MY_RUBY_HOME = /home/ubuntu/.rvm/rubies/ruby-2.1.2
USER = ubuntu
DOCUMENT_ROOT = /etc/projects/myapp/public
_system_type = Linux
REQUEST_URI = /
rvm_path = /home/ubuntu/.rvm
IN_PASSENGER = 1
RACK_ENV = production
REMOTE_PORT = 49231
rvm_prefix = /home/ubuntu
PATH = /home/ubuntu/.rvm/gems/ruby-2.1.2/bin:/home/ubuntu/.rvm/gems/ruby-2.1.2@global/bin:/home/ubuntu/.rvm/rubies/ruby-2.1.2/bin:/home/ubuntu/.rvm/gems/ruby-2.1.5/bin:/home/ubuntu/.rvm/gems/ruby-2.1.5@global/bin:/home/ubuntu/.rvm/rubies/ruby-2.1.5/bin:/home/ubuntu/.rvm/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
APACHE_LOG_DIR = /var/log/apache2
WSGI_ENV = production
SERVER_ADMIN = [no address given]
PWD = /etc/projects/myapp
LANG = C
APACHE_RUN_GROUP = www-data
NODE_PATH = /home/ubuntu/.rvm/gems/ruby-2.1.2/gems/passenger-4.0.45/node_lib
_system_arch = x86_64
NODE_ENV = production
_system_version = 14.04
REMOTE_ADDR = 108.49.67.170
rvm_version = 1.26.4 (latest)
SERVER_NAME = 54.191.134.234
HOME = /home/ubuntu
SHLVL = 0
RAILS_ENV = production
rvm_ruby_string = ruby-2.1.5
SERVER_SOFTWARE = Apache/2.4.7 (Ubuntu)
LOGNAME = ubuntu
QUERY_STRING =
SERVER_ADDR = 172.31.33.140
GEM_PATH = /home/ubuntu/.rvm/gems/ruby-2.1.2:/home/ubuntu/.rvm/gems/ruby-2.1.2@global
SERVER_PROTOCOL = HTTP/1.1
PASSENGER_APP_ENV = production
rvm_delete_flag = 0
APACHE_RUN_DIR = /var/run/apache2
APACHE_LOCK_DIR = /var/lock/apache2
REQUEST_METHOD = GET
RUBY_VERSION = ruby-2.1.5
_system_name = Ubuntu
_ORIGINAL_GEM_PATH = /home/ubuntu/.rvm/gems/ruby-2.1.2:/home/ubuntu/.rvm/gems/ruby-2.1.2@global
Ulimits
Unknown
System metrics
------------- General -------------
Kernel version : 3.13.0-24-generic
Uptime : 121d 19h 35m 27s
Load averages : 0.02%, 0.14%, 0.19%
Fork rate : unknown
------------- CPU -------------
Number of CPUs : 1
Average CPU usage : 0% -- 0% user, 0% nice, 0% system, 100% idle
CPU 1 : 0% -- 0% user, 0% nice, 0% system, 100% idle
I/O pressure : 0%
CPU 1 : 0%
Interference from other VMs: 0%
CPU 1 : 0%
------------- Memory -------------
RAM total : 588 MB
RAM used : 96 MB (16%)
RAM free : 492 MB
Swap total : 1023 MB
Swap used : 57 MB (6%)
Swap free : 966 MB
Swap in : unknown
Swap out : unknown
General Ruby interpreter information
RUBY_VERSION = 2.1.2
RUBY_PLATFORM = x86_64-linux
RUBY_ENGINE = ruby
RubyGems version = 2.4.2
Ruby configuration (RbConfig::CONFIG)
DESTDIR =
MAJOR = 2
MINOR = 1
TEENY = 0
PATCHLEVEL = 95
INSTALL = /usr/bin/install
EXEEXT =
prefix = /home/ubuntu/.rvm/rubies/ruby-2.1.2
ruby_install_name = ruby
RUBY_INSTALL_NAME = ruby
RUBY_SO_NAME = ruby
exec = exec
ruby_pc = ruby-2.1.pc
PACKAGE = ruby
BUILTIN_TRANSSRCS = newline.c
USE_RUBYGEMS = YES
MANTYPE = doc
NROFF = /usr/bin/nroff
vendorarchhdrdir = /home/ubuntu/.rvm/rubies/ruby-2.1.2/include/ruby-2.1.0/vendor_ruby/x86_64-linux
sitearchhdrdir = /home/ubuntu/.rvm/rubies/ruby-2.1.2/include/ruby-2.1.0/site_ruby/x86_64-linux
rubyarchhdrdir = /home/ubuntu/.rvm/rubies/ruby-2.1.2/include/ruby-2.1.0/x86_64-linux
vendorhdrdir = /home/ubuntu/.rvm/rubies/ruby-2.1.2/include/ruby-2.1.0/vendor_ruby
sitehdrdir = /home/ubuntu/.rvm/rubies/ruby-2.1.2/include/ruby-2.1.0/site_ruby
rubyhdrdir = /home/ubuntu/.rvm/rubies/ruby-2.1.2/include/ruby-2.1.0
RUBY_SEARCH_PATH =
UNIVERSAL_INTS =
UNIVERSAL_ARCHNAMES =
configure_args = '--prefix=/usr/local/rvm/rubies/ruby-2.1.2' '--enable-load-relative' '--sysconfdir=/etc' '--disable-install-doc' '--enable-shared'
vendorarchdir = /home/ubuntu/.rvm/rubies/ruby-2.1.2/lib/ruby/vendor_ruby/2.1.0/x86_64-linux
vendorlibdir = /home/ubuntu/.rvm/rubies/ruby-2.1.2/lib/ruby/vendor_ruby/2.1.0
vendordir = /home/ubuntu/.rvm/rubies/ruby-2.1.2/lib/ruby/vendor_ruby
I've been looking at a lot of material that seemed to help, but I've kept running into the same issue in the end. https://rvm.io/deployment/passenger Is it possible to change Passenger Ruby version without recompiling? http://terratakashi.logdown.com/posts/190823-use-different-rvm-gemset-for-rails-app-on-apache-server
I'm inexperienced when it comes to the ops work and server work so I'm not sure if memory allocation or usage could be part of the issue, and if it is then I'm not sure how to work around that or fix it...
Swap
Filename Type Size Used Priority
/swap file 1048572 58752 -1
Any guidance would be great!
UPDATE
I never got the compiler to complete but at some point along doing the following steps per @BMW guidance, I reloaded the server and the site no longer had Passenger and Gemfile ruby version conflicts. My apache.conf is still not accurate, but things are working so :)
ubuntu@ip-172-31-33-140:/etc/apache2$ source $HOME/.rvm/scripts/rvm
ubuntu@ip-172-31-33-140:/etc/apache2$ sudo /home/ubuntu/.rvm/gems/ruby-2.1.5/bin/passenger-install-apache2-module
/usr/bin/env: ruby_executable_hooks: No such file or directory
which passenger-config
/home/ubuntu/.rvm/gems/ruby-2.1.5/bin/passenger-config
rvm use 2.1.5
Using /home/ubuntu/.rvm/gems/ruby-2.1.5
/home/ubuntu/.rvm/gems/ruby-2.1.5/bin/passenger-config --ruby-command
passenger-config was invoked through the following Ruby interpreter:
Command: /home/ubuntu/.rvm/gems/ruby-2.1.5/wrappers/ruby
Version: ruby 2.1.5p273 (2014-11-13 revision 48405) [x86_64-linux]
To use in Apache: PassengerRuby /home/ubuntu/.rvm/gems/ruby-2.1.5/wrappers/ruby
To use in Nginx : passenger_ruby /home/ubuntu/.rvm/gems/ruby-2.1.5/wrappers/ruby
To use with Standalone: /home/ubuntu/.rvm/gems/ruby-2.1.5/wrappers/ruby /home/ubuntu/.rvm/gems/ruby-2.1.5/gems/passenger-4.0.55/bin/passenger start
## Notes for RVM users
Do you want to know which command to use for a different Ruby interpreter? 'rvm use' that Ruby interpreter, then re-run 'passenger-config --ruby-command'.
passenger-install-apache2-module
with sudo command – BMWsource "$HOME/.rvm/scripts/rvm
; then runsudo /home/ubuntu/.rvm/gems/ruby-2.1.5/bin/passenger-install-apache2-module
– BMW