sockets - 尝试远程调试时找不到进程调度程序的可用套接字端口

标签 sockets intellij-idea vagrant virtualbox remote-debugging

亮点:

  • Windows 10主机
  • 作为访客vm的ubuntu vagrant box(virtualbox)vm
  • 使用无用的端口转发,如下所示:config.vm.network "forwarded_port", guest: 1234, host: 12340
  • IDE:具有Ruby插件
  • 的IntelliJ IDEA

    问题:

    我尝试在this guide之后设置远程ruby调试,并在IDE中收到错误:“未能为进程调度程序找到可用的套接字端口”。看来这个问题是not IntelliJ-specific,我也能够用最新的RubyMine来重现它。

    从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 ,但是远程调试应该怎么工作呢? (我的意思是,有没有办法访问 guest 虚拟机端口而不转发该端口?显然没有)解决此问题的任何帮助将不胜感激。

    最佳答案

    对我来说,问题是由于在后台打开的另一个调试 session 所致。为防止再次发生这种情况(并再次运行该配置,并关闭所有其他当前打开的 session ),请在“调试配置”中选择“仅单个实例”:enter image description here

    关于sockets - 尝试远程调试时找不到进程调度程序的可用套接字端口,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45084093/

    相关文章:

    security - HTTPS 和基于 SSL 的 TCP 有什么区别

    java - Intellij错误: Internal Error Cannot Run Program in Directory Java Play Angular

    mysql - 使用SaltStack创建Mysql数据库

    ruby - 在文件同步之前 vagrant up provisioning

    selenium - 在 Vagrant 盒子内运行 Selenium/PhantomJS

    c - 当服务器在同一台机器上时打印客户端 ip

    sockets - 安装 lua 套接字时出错

    intellij-idea - 配置 "Idea"显示src/main/java为一个文件夹

    java - 多个线程监听一个 UDP 端口?

    Tomcat、Intellij 和 DCEVM 配置