Skip to content

Windows Firewall block WSL2 accessing to Windows service  #5237

Closed

Description

@eromoe

Test code:

winip=$(ip route | grep default | awk '{print $3}')
ping $winip

result:
image

Actually I want to use a proxy service host on windows . I saw many people success with above command, why I faied ? Or wsl2 go into new problem ?

Activity

  1. therealkenc commented on May 20, 2020

    @therealkenc

    There isn't enough to go on here to guess why you can't ping your default route on (if I am interpreting correctly) WSL1.

  2. eromoe commented on May 21, 2020

    @eromoe
    Author

    I can provide what you need if you tell me how to do , I have totally no clue to investigate it .

  3. changed the title [-]WSL2 can not access windows ip retreived by `ip route | grep default | awk '{print $3}`[/-] [+]Windows Firewall block WSL2 accessing to Windows service [/+] on May 23, 2020
  4. eromoe commented on May 23, 2020

    @eromoe
    Author

    I found it due to windows firewall. Add exclude rule of wsl.exe in firewall didn't work, I saw several cases include me had to shutdown firewall to make wsl able to access windows service .

    Since this is common usage of wsl2, people shouldn't need shutdown firewall . It is system/wsl resposibility to make wsl2 bypass firewall at default .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions