I am new here, so be careful.
I recently created a new VPS to run the ruby-on-rails site. I installed the following applications with versions, as already mentioned. I get a Bad Gateway error. I browsed the web pages and stackoverflow, but could not isolate the discussion of this error.
Can someone shed some light on this, please. Thanks for your submissions. Alf
- Server: ubuntu 14.04
- Ruby: 2.2
- Rails: 4.2
- nginx: 1.6.0
- Passenger: 4.0.46
Error logs - with the __ drives __ drive option set to 7. The main bits are below, I can also download the txt file if I can figure out how to do this.
The main error code that I can determine is this. It starts in an infinite loop after the request:
2015-01-14 16:38:49.7008 2348/7fa01e892700 agents/HelperAgent/RequestHandler.h:2626 ]: [Client 20] End of (unbuffered) client body reached; done sending data to application
App 2367 stderr: [ 2015-01-14 16:38:49.7012 2442/0x007f052879f318(Main thread) request_handler.rb:181 ]: Entering request handler main loop
App 2367 stderr: /usr/local/lib/ruby/gems/2.2.0/gems/passenger-4.0.46/lib/phusion_passenger/request_handler.rb:356:in `trap'
App 2367 stderr: :
App 2367 stderr: Invalid argument - SIGKILL
App 2367 stderr: (
App 2367 stderr: Errno::EINVAL
App 2367 stderr: )
App 2367 stderr: from /usr/local/lib/ruby/gems/2.2.0/gems/passenger-4.0.46/lib/phusion_passenger/request_handler.rb:356:in `block in reset_signal_handlers'
App 2367 stderr: from /usr/local/lib/ruby/gems/2.2.0/gems/passenger-4.0.46/lib/phusion_passenger/request_handler.rb:354:in `each_key'
App 2367 stderr: from /usr/local/lib/ruby/gems/2.2.0/gems/passenger-4.0.46/lib/phusion_passenger/request_handler.rb:354:in `reset_signal_handlers'
App 2367 stderr: from /usr/local/lib/ruby/gems/2.2.0/gems/passenger-4.0.46/lib/phusion_passenger/request_handler.rb:182:in `main_loop'
App 2367 stderr: from /usr/local/lib/ruby/gems/2.2.0/gems/passenger-4.0.46/helper-scripts/rack-preloader.rb:161:in `'
App 2367 stderr: from /usr/local/lib/ruby/gems/2.2.0/gems/passenger-4.0.46/helper-scripts/rack-preloader.rb:29:in `'
, , nginx/:
[ 2015-01-14 16:38:46.8338 2348/7fa0209bf700 Pool2/SmartSpawner.h:353 ]: [App 2367 stdin >>]
App 2367 stderr: /usr/local/lib/ruby/gems/2.2.0/gems/activesupport-4.1.1/lib/active_support/values/time_zone.rb:285: warning: circular argument reference - now
[ 2015-01-14 16:38:48.0003 2348/7fa020aa3700 Pool2/Pool.h:836 ]: Analytics collection time...
[ 2015-01-14 16:38:48.0021 2348/7fa020aa3700 Pool2/Pool.h:942 ]: Analytics collection done; next analytics collection in 4.998 sec
App 2367 stderr: /usr/bin/env:
App 2367 stderr: ruby
App 2367 stderr: : No such file or directory
App 2367 stderr:
[ 2015-01-14 16:38:49.6243 2348/7fa0209bf700 Pool2/Spawner.h:790 ]: [App 2367 stdout] !> Ready
[ 2015-01-14 16:38:49.6245 2348/7fa0209bf700 Pool2/Spawner.h:790 ]: [App 2367 stdout] !> socket: unix:/tmp/passenger.1.0.2344/generation-0/backends/preloader.2367
[ 2015-01-14 16:38:49.6247 2348/7fa0209bf700 Pool2/Spawner.h:790 ]: [App 2367 stdout] !>
nginx /etc/init.d/nginx script, :
case "$1" in
start)
echo -n "Starting $DESC: "
start-stop-daemon --start --quiet --pidfile /opt/nginx/logs/$NAME.pid \
--exec $DAEMON -- $DAEMON_OPTS
echo "$NAME."
;;