search

Home  >  Q&A  >  body text

为什么我ping不通我的docker容器呢???


我是win10系统,我给docker其中一个容器做了端口映射,如图,但是我在win10主机上
C:Userstentou>telnet localhost 32786
正在连接localhost...无法打开到主机的连接。 在端口 32786: 连接失败
这是为什么呢??

漂亮男人漂亮男人2771 days ago1022

reply all(3)I'll reply

  • 仅有的幸福

    仅有的幸福2017-04-24 16:02:11

    First of all, I don’t know if your configuration is correct, but I feel like the concepts are confused?

    Ping is to test whether the IP or domain name is accessible?

    Telnet is used to test whether the port is open?

    reply
    0
  • 滿天的星座

    滿天的星座2017-04-24 16:02:11

    I don’t know which version of Docker for Windows you are using. In the Beta version before last month, in Settings > Network, there was an option to choose whether to map the virtual machine port to the Windows system port. You need to check it.
    The other thing is to check whether the permissions of Docker for Windows are restricted. It is recommended to use administrator mode to open Docker for Windows.

    reply
    0
  • 给我你的怀抱

    给我你的怀抱2017-04-24 16:02:11

    Turn off the firewall, try it

    reply
    0
  • Cancelreply