I always use wsl 1 instead of 2. One of the primary reasons is that you can directly control your network card from 1. So with the mirrored networking mode 2 is starting to look a little bit better.
One downside of that aspect of WSL1 is that you can’t get any network interface statistics at all. For instance I have a program running in WSL and I want to report network upload speed while it’s running, and WSL1 simply doesn’t expose that.
I believe WSL2 set up networking almost as a virtual client on a network local to your machine. Windows used NAT to direct traffic from Windows to WSL. The new changes allow more direct access to the network hardware instead of "virtualizing" (probably the wrong word) it
oefrha|2 years ago
panki27|2 years ago
shortrounddev2|2 years ago
I believe WSL2 set up networking almost as a virtual client on a network local to your machine. Windows used NAT to direct traffic from Windows to WSL. The new changes allow more direct access to the network hardware instead of "virtualizing" (probably the wrong word) it