Support Bridged Ethernet and as a Kernel loadable module
Nobody has claimed this yet.
- 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.
Currently, running Mininet simulator (http://mininet.org/) for setting up an SDN development environment on WSL 2 becomes impossible.
The requested feature is ta make it possible to enable such an environment in WSL 2, which in turn allows running advanced software switching technology like OpenVSwitch (https://www.openvswitch.org/).
This will open up further possibilities to run virtualized technologies such OpenMANO (https://github.com/nfvlabs/openmano) as well as many network orchestration and management tools such as OSM (https://osm.etsi.org/).
Specifically, advanced virtualization technologies such SDN/NFV are currently used in the 5G network and beyond.
Supporting these features, will open up several opportunities to the research community to enable testing and simulating 5G anf beyond in WSL2 (which is considered near to bare-metal virtualization in terms of performance and scalability).
It will open up several opportunities for teachers, students, researchers and labs centers ta make it possible to simulate such big challenges inside their laptops or surface.
Describe the solution you'd like
To make it possible to enable Mininet and Openvswitch on WSL 2, the main solution to address these limitations is to compile with a loadable kernel module instead of a built-in module.
Describe alternatives you've considered
To make this happen, the current workaround to bypass this problem is to build a new WSL2 kernel with customized features as described in WSL2 + Mininet (https://zhuanlan.zhihu.com/p/138933513):
- The main thing is to modify Networking Support -> Networking Options -> 802.1d Ethernet Bridging to modularize features, that is, to compile with a loadable kernel module instead of a built-in module.
- After booting, first install the kernel module (sudo make modules_install), then load the bridge module (sudo modprobe bridge && sudo lsmod).
- Thereafter, install openvswitch normally using command : sudo apt install openvswitch-switch. Then, The current WSL 2 does not have systemd yet, so you have to use init.d (or you may use one of the workarround to support systemd in WSL2 like described here : https://github.com/arkane-systems/genie or here : https://github.com/hakiri/ubuntu-wsl2-systemd-script.
- Next, you can install Mininet under Ubuntu by typing: sudo apt install mininet, and test it is working by typing:
sudo mn --test pingall - If you want to use Mininet-WIFI (https://mininet-wifi.github.io/), which is mininet for wireless communication and IoT (including 6LowPAN), you have to modify the options to support mac80211 and mac80211_hwsim when compiling the kernel (in step 1 above), by doing a) mac80211 in Networking Support -> Wireless -> cfg80211 and mac80211; and b) mac80211_hwsim is in Device Drivers -> Network device support -> Wireless Lan -> Simulated radio testing tool for mac80211.
These steps have been tested successfully for WSL 4.19; but have several running issues when compiling WSL2-Linux-Kernel 5.4 and 5.10.
Additional context
Below are the workaround to make this feature possible:

Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the WSL2 kernel configuration for 802.1d Ethernet Bridging, cfg80211, mac80211, and mac80211_hwsim, then compare the documented WSL 4.19 workaround with the 5.4 and 5.10 configurations. Done means the required networking features can be built and loaded as modules and the documented Mininet check, sudo mn --test pingall, works with Open vSwitch.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- linux
- Domain
- networking, operating-systems
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100