Frequent "No route to host - connect(2) (Errno::EHOSTUNREACH)" error messages

1,229 views
Skip to first unread message

ragh...@i10n.com

unread,
Aug 6, 2014, 6:28:51 AM8/6/14
to phusion-...@googlegroups.com
Hello Everybody

I am hosting Redmine via Passenger.
I have hosted multiple versions of redmine in our server without any problems.
But in one specific version of redmine installation, passenger is frequently showing the error message present in the subject line,
When i try to start it multiple times, it starts and works for a few minutes and stops automatically to show that error message.

Tinco Andringa

unread,
Aug 6, 2014, 6:59:50 AM8/6/14
to phusion-...@googlegroups.com
Hi, can you show us a bit more of the logs around the message?
> --
> You received this message because you are subscribed to the Google Groups
> "Phusion Passenger Discussions" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to phusion-passen...@googlegroups.com.
> To post to this group, send email to phusion-...@googlegroups.com.
> Visit this group at http://groups.google.com/group/phusion-passenger.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/phusion-passenger/e21388c0-e699-4c8e-a609-fce062faeab1%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

ragh...@i10n.com

unread,
Aug 6, 2014, 7:10:12 AM8/6/14
to phusion-...@googlegroups.com
Here it is.

  1. /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/command.rb:218:in `initialize': No route to host - connect(2) (Errno::EHOSTUNREACH)
  2.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/command.rb:218:in `new'
  3.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/command.rb:218:in `ping_nginx'
  4.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller.rb:693:in `call'
  5.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller.rb:693:in `run_ping_command'
  6.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller.rb:383:in `block (2 levels) in start_without_locking'
  7.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller.rb:498:in `wait_until'
  8.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller.rb:377:in `block in start_without_locking'
  9.         from /usr/local/rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/timeout.rb:69:in `timeout'
  10.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller.rb:355:in `start_without_locking'
  11.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller.rb:217:in `block in start'
  12.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller/lock_file.rb:68:in `block in exclusive_lock'
  13.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller/lock_file.rb:63:in `open'
  14.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller/lock_file.rb:63:in `exclusive_lock'
  15.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.1.4/lib/daemon_controller.rb:216:in `start'
  16.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/start_command.rb:334:in `start_nginx'
  17.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/start_command.rb:71:in `run'
  18.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/main.rb:93:in `block in run_command'
  19.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/main.rb:48:in `block in each_command'
  20.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/main.rb:43:in `each'
  21.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/main.rb:43:in `each_command'
  22.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/main.rb:91:in `run_command'
  23.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/main.rb:62:in `run!'
  24.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/lib/phusion_passenger/standalone/main.rb:39:in `run!'
  25.         from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-3.0.11/bin/passenger:32:in `<top (required)>'
  26.         from /usr/local/rvm/gems/ruby-1.9.3-p448/bin/passenger:19:in `load'
  27.         from /usr/local/rvm/gems/ruby-1.9.3-p448/bin/passenger:19:in `<main>'
  28.         from /usr/local/rvm/gems/ruby-1.9.3-p448/bin/ruby_noexec_wrapper:14:in `eval'
  29.         from /usr/local/rvm/gems/ruby-1.9.3-p448/bin/ruby_noexec_wrapper:14:in `<main>'

ragh...@i10n.com

unread,
Aug 6, 2014, 7:11:33 AM8/6/14
to phusion-...@googlegroups.com
Command used to start it 

passenger start -a 0.0.0.0 -p 3001 -d -e production


On Wednesday, August 6, 2014 4:29:50 PM UTC+5:30, Tinco Andringa (Phusion) wrote:

ragh...@i10n.com

unread,
Aug 6, 2014, 7:16:25 AM8/6/14
to phusion-...@googlegroups.com
Even if i change the port from 3001 to something else, it would work for two minutes. Thats it.,
Then it would automatically be stopped to show this error message in passenger's log file.

Tinco Andringa

unread,
Aug 6, 2014, 8:04:03 AM8/6/14
to phusion-...@googlegroups.com
Hi, it looks like it might be a bug, but you're running a very old
version of passenger. Could you try running the latest version of
Passenger 4 instead? There are many bugfixes and general improvements
made since Passenger 3.0.11

Kind regards,
Tinco
> https://groups.google.com/d/msgid/phusion-passenger/a214ba31-8acc-4a8f-81d9-fb6e11678587%40googlegroups.com.
>
> For more options, visit https://groups.google.com/d/optout.



--
Phusion | Web application deployment, scaling and monitoring solutions

Web: http://www.phusion.nl/
E-mail: in...@phusion.nl
Chamber of commerce no: 08173483 (The Netherlands)

ragh...@i10n.com

unread,
Aug 6, 2014, 9:01:38 AM8/6/14
to phusion-...@googlegroups.com, ti...@phusion.nl
I have just updated passenger to the latest version.
I am still getting the same error.

/usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/helper-scripts/prespawn:111:in `initialize': No route to host - connect(2) (Errno::EHOSTUNREACH)
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/helper-scripts/prespawn:111:in `new'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/helper-scripts/prespawn:111:in `connect'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/helper-scripts/prespawn:87:in `socket'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/helper-scripts/prespawn:91:in `head_request'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/helper-scripts/prespawn:153:in `<main>'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.2.0/lib/daemon_controller.rb:218:in `block in start'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.2.0/lib/daemon_controller/lock_file.rb:68:in `block in exclusive_lock'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.2.0/lib/daemon_controller/lock_file.rb:63:in `open'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.2.0/lib/daemon_controller/lock_file.rb:63:in `exclusive_lock'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/daemon_controller-1.2.0/lib/daemon_controller.rb:217:in `start'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/lib/phusion_passenger/standalone/start_command.rb:532:in `start_nginx'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/lib/phusion_passenger/standalone/start_command.rb:73:in `run'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/lib/phusion_passenger/standalone/main.rb:91:in `run_command'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/lib/phusion_passenger/standalone/main.rb:61:in `run!'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/lib/phusion_passenger/standalone/main.rb:38:in `run!'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/gems/passenger-4.0.48/bin/passenger:44:in `<top (required)>'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/bin/passenger:19:in `load'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/bin/passenger:19:in `<main>'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/bin/ruby_executable_hooks:15:in `eval'
        from /usr/local/rvm/gems/ruby-1.9.3-p448/bin/ruby_executable_hooks:15:in `<main>'

ragh...@i10n.com

unread,
Aug 7, 2014, 1:00:46 AM8/7/14
to phusion-...@googlegroups.com, ti...@phusion.nl
Please assist me soon,
The passenger web server is being used in Redmine.

ragh...@i10n.com

unread,
Aug 8, 2014, 2:21:44 AM8/8/14
to phusion-...@googlegroups.com, ti...@phusion.nl
I was able to resolve the issue finally.
The culprit was malformed firewall rules.

Tinco Andringa

unread,
Aug 8, 2014, 7:16:43 AM8/8/14
to ragh...@i10n.com, phusion-...@googlegroups.com
Thanks for letting us know, nice job for figuring it out :)

Btw, if you would like to have guaranteed response times on questions
like this please consider buying passenger enterprise. We do often
check and respond to questions on this list and reply as quick as we
can, but if guaranteed response times is what you need you're best off
checking our support offerings.

Kind regards,
Tinco
Reply all
Reply to author
Forward
0 new messages