-
Notifications
You must be signed in to change notification settings - Fork 558
Description
Issue report
I came across this issue trying to get our Rails app running on a colleagues Windows machine. I know it's probably low priority (can't imagine there's a huge amount of users with this setup) but thought I'd post it incase it's something that's worth fixing (or at least be of use for the next person trying to find a fix).
I worked around this by forcing Passenger to use tcp sockets instead of unix sockets by setting _PASSENGER_FORCE_HTTP_SESSION to true.
Question 1: What is the problem?
Passenger fails with Address already in use when running under Ubuntu WSL
Address already in use - listen(2) (Errno::EADDRINUSE)
/usr/lib/ruby/vendor_ruby/phusion_passenger/request_handler.rb:303:in `listen'
/usr/lib/ruby/vendor_ruby/phusion_passenger/request_handler.rb:303:in `block in create_unix_socket_on_filesystem'
/usr/lib/ruby/vendor_ruby/phusion_passenger/utils.rb:65:in `block in retry_at_most'
/usr/lib/ruby/vendor_ruby/phusion_passenger/utils.rb:63:in `times'
/usr/lib/ruby/vendor_ruby/phusion_passenger/utils.rb:63:in `retry_at_most'
/usr/lib/ruby/vendor_ruby/phusion_passenger/request_handler.rb:299:in `create_unix_socket_on_filesystem'
/usr/lib/ruby/vendor_ruby/phusion_passenger/request_handler.rb:101:in `initialize'
/usr/share/passenger/helper-scripts/rack-preloader.rb:135:in `new'
/usr/share/passenger/helper-scripts/rack-preloader.rb:135:in `negotiate_spawn_command'
/usr/share/passenger/helper-scripts/rack-preloader.rb:158:in `<module:App>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:30:in `<module:PhusionPassenger>'
/usr/share/passenger/helper-scripts/rack-preloader.rb:29:in `<main>'
Question 2: Passenger version and integration mode:
We tried with open source 5.1.11 standalone and via Apache 2.4.18
(also tried with the latest 5.2.0 standalone and had the same issue)
Question 3: OS or Linux distro, platform (including version):
Windows 10 Pro. v 1709. build 16299.192
Windows Subsystem for Linux (using Ubuntu)
Question 4: Passenger installation method:
Your answer:
[X] RubyGems + Gemfile
[ ] RubyGems, no Gemfile
[ ] Phusion APT repo
[ ] Phusion YUM repo
[ ] OS X Homebrew
[ ] source tarball
[ ] Other, please specify:
Question 5: Your app's programming language (including any version managers) and framework (including versions):
Ruby 2.4.2
Rails 4.2.10
Node.js 8.9.4
Question 6: Are you using a PaaS and/or containerization? If so which one?
Windows Subsystem for Linux (using Ubuntu)