WSL

WSL

Troubleshooting

Как сделать запрос из WSL на localhost самой винды

  • Берем IP из

    > cat /etc/resolv.conf
    
      # This file was automatically generated by WSL. To stop automatic generation of this file, add the following entry to /etc/wsl.conf:
      # [network]
      # generateResolvConf = false
      nameserver 192.168.96.1
    
    • Делаем запрос на порт curl 192.168.96.1:${port}

Докер не может использовать порт

#docker

Способ 1

net stop winnat
... # делаем свои действия
net start winnat

Способ 2

Сурсы:

  • https://github.com/docker/for-win/issues/9272#issuecomment-731847321
  • https://github.com/docker/for-win/issues/3171#issue-395479404

listen tcp :50051: bind: An attempt was made to access a socket in a way forbidden by its access permissions.

Проверить, закрыты ли порты в винде:

netsh int ipv4 show excludedportrange protocol=tcp

Если да, то открыть:

netsh int ipv4 set dynamic tcp start=49152 num=16384