Overview of the WSL2-Linux-Kernel Project
The WSL2-Linux-Kernel project is a repository that houses the source code and configuration files for the WSL2 kernel. WSL2, or Windows Subsystem for Linux version 2, is a Microsoft feature allowing users to run a Linux environment directly on Windows without needing a virtual machine.
Reporting Issues
If users encounter problems with either WSL or the WSL2 kernel, they're encouraged to report these issues through the WSL GitHub project. This repository, specifically for the WSL2-Linux-Kernel, does not handle issue reporting directly. Users should be aware of the distinct procedures for reporting general bugs compared to security-related bugs. They can report common issues via the standard bug process, whereas security concerns have a dedicated reporting channel.
Submitting Feature Requests
The project is open to suggestions for new features. Users who notice a missing feature can request it via the WSL GitHub project. Moreover, for those interested in contributing by developing kernel code, there's encouragement to submit patches or changes directly to the upstream Linux community. This offers a collaborative way to improve the kernel.
Building the WSL2 Kernel
For those looking to build the WSL2 kernel themselves, especially on an x86_64 architecture with an Ubuntu system, the following steps are recommended:
-
Install Necessary Dependencies:
- Users should install all building dependencies using the following command:
$ sudo apt install build-essential flex bison dwarves libssl-dev libelf-dev cpio
- Users should install all building dependencies using the following command:
-
Modify Kernel Configurations (Optional):
- If desired, users can modify the kernel configurations using:
$ make menuconfig KCONFIG_CONFIG=Microsoft/config-wsl
- Note that loadable module support is disabled in the custom built kernel, so any desired modules need to be set as built-in before compiling.
- If desired, users can modify the kernel configurations using:
-
Compile the Kernel:
- Utilize the WSL2 kernel configuration to build the kernel with:
$ make KCONFIG_CONFIG=Microsoft/config-wsl
- Utilize the WSL2 kernel configuration to build the kernel with:
Installing the Custom Kernel
To install and use a custom built kernel, users should refer to the documentation on the .wslconfig
configuration file. This documentation provides guidance on integrating a custom kernel into the WSL2 environment effectively.
For further details and resources, including links to report issues or contribute to development, users are encouraged to explore the respective sections of the WSL2-Linux-Kernel project repository.