尝试远程调试时找不到进程调度程序的可用套接字端口 [英] failed to find free socket port for process dispatcher when trying remote debug
问题描述
要点:
- Windows 10主机
- ubuntu流浪者盒子(virtualbox)作为来宾虚拟机
- 像这样使用无用的端口转发:
config.vm.network "forwarded_port", guest: 1234, host: 12340
- IDE:带有Ruby插件的IntelliJ IDEA
- windows 10 host machine
- ubuntu vagrant box (virtualbox) as guest vm
- using vagrant port forwarding as like this:
config.vm.network "forwarded_port", guest: 1234, host: 12340
- IDE: IntelliJ IDEA with Ruby plugin
问题:
我尝试按照无法找到进程分派器的可用套接字端口".看来这个问题是不是IntelliJ专用的,我当时能够使用最新的RubyMine进行复制.
I've tried to set up remote ruby debug following this guide and getting an error in IDE: "failed to find free socket port for process dispatcher". It looks this issue is not IntelliJ-specific, I was able to reproduce it with latest RubyMine as well.
从IDEA日志中获取
2017-07-07 21:53:03,515 [8879188] INFO - tion.impl.ExecutionManagerImpl - Failed to find free socket port for process dispatcher
com.intellij.execution.ExecutionException: Failed to find free socket port for process dispatcher
at org.jetbrains.plugins.ruby.ruby.debugger.RubyProcessDispatcher.<init>(RubyProcessDispatcher.java:46)
at org.jetbrains.plugins.ruby.ruby.debugger.RubyRemoteDebugRunner.doExecute(RubyRemoteDebugRunner.java:62)
...
Caused by: java.net.BindException: Address already in use: JVM_Bind
at java.net.TwoStacksPlainSocketImpl.socketBind(Native Method)
at java.net.TwoStacksPlainSocketImpl.socketBind(TwoStacksPlainSocketImpl.java:137)
...
我可以理解它说已经在使用的地址:JVM_Bind ,但是远程调试应该怎么工作呢? (我的意思是,有没有办法访问来宾虚拟机端口,而该端口以前没有转发过?显然没有)解决此问题的任何帮助.
I can understand it says Address already in use: JVM_Bind, but how remote debug supposed to work at all then? (I mean Is there any way to access guest vm port not forwarding it before? Clearly no) Any help to solve this issue is much appreciated.
推荐答案
对我来说,此问题是由于在后台打开的另一个调试会话引起的.为防止再次发生(并再次运行该配置,并关闭所有其他当前打开的会话),请在调试配置"中选择仅单个实例":
For me the issue was due to another debug session that was open in the background. To prevent that from happening again (and also close all other currently open sessions, once you run the configuration again) select "Single instance only" in the Debug Configuration:
这篇关于尝试远程调试时找不到进程调度程序的可用套接字端口的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!