microsoft / WSL

Issues found on WSL
https://docs.microsoft.com/windows/wsl
MIT License
17.28k stars 813 forks source link

Mirrored Networking Mode - support libvirt virtual interfaces #11150

Open hoo29 opened 7 months ago

hoo29 commented 7 months ago

Is your feature request related to a problem? Please describe. In mirrored networking mode, traffic for any virtual interfaces libvirt creates is not routable from Windows.

To reproduce:

  1. In WSL, install vagrant and vagrant libvirt.
  2. Create this Vagrantfile in a directory:
    Vagrant.configure("2") do |config|
    config.vm.box = "rockylinux/9"
    config.vm.provision "shell", inline: 
    """
    dnf install httpd -y
    systemctl start httpd
    systemctl enable httpd
    echo $(ip addr show eth0 | grep inet | awk '{print $2}' | cut -d/ -f1)
    """
    end
  3. Run vagrant up --provider=libvirt. Note down the ipv4 address shown at the end of the provisioning output.
  4. Run curl $THE_IP from WSL and you will get a response but you will not from windows.

Describe the solution you'd like Routes created for libvirt virtual interfaces to be routable from Windows.

Describe alternatives you've considered Using chrome installed in WSL works around the problem.

Additional context route print on Windows does not show any routes for the virbrX interfaces libvirt creates.

brett19 commented 3 days ago

Is there any updates on whether this is being considered or if there are potential alternative solutions?