microsoft / microsoft/WSL

Mirrored Networking Mode - support libvirt virtual interfaces

Open
#11,150 2 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature
Dominant language
C++
Stars
33.7k
Forks
1.8k
Avg merge
3d 17h
Merged PRs (30d)
116

Description

**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](https://developer.hashicorp.com/vagrant/downloads) and [vagrant libvirt](https://vagrant-libvirt.github.io/vagrant-libvirt/).
2. Create this `Vagrantfile` in a directory:
```ruby
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.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the supplied Vagrantfile and reproduce the libvirt setup using `vagrant up --provider=libvirt`. Compare `curl` from WSL and Windows with the Windows `route print` output; done means routes for libvirt's virtual interfaces are present and the service is reachable from Windows.

Written by the indexing model from the issue text.

Assessment

Domain
networking, operating-systems
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.