microsoft / microsoft/WSL

uname -r doesn't match ls /lib/modules

Open
#7,019 4 comments 0 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

Windows Build Number

10.0.19043.1023

WSL Version
  • WSL 2
  • WSL 1
Kernel Version

5.10.16.3-microsoft-standard-WSL2

Distro Version

Ubuntu-20.04 LTS

Other Software

apt
modprobe
ddcci-dkms

Repro Steps
  1. Update kernel with sudo apt update; sudo apt upgrade or an update package
  2. Try:
  • ls /lib/modules
  • sudo apt install ddcci-dkms
  • modprobe <any module>
Expected Behavior
  • ls /lib/modules should show a folder with the currently installed kernel version as its name
  • sudo apt install ddcci-dkms should install the modules to the correct directory
  • modprobe should work
Actual Behavior
  • ls /lib/modules:
5.4.0-73-generic  5.4.0-74-generic
  • sudo apt install ddcci-dkms
Setting up ddcci-dkms (0.3.3-1) ...
Loading new ddcci-0.3.3 DKMS files...
BACKLIGHT_CLASS_DEVICE disabled in this kernel, not building module.
It is likely that 5.10.16.3-microsoft-standard-WSL2 belongs to a chroot's host
Building for 5.4.0-73-generic and 5.4.0-74-generic
Module build for kernel 5.4.0-73-generic was skipped since the
kernel headers for this kernel does not seem to be installed.
Building initial module for 5.4.0-74-generic
Done.

ddcci.ko:
Running module version sanity check.
 - Original module
   - No original module exists within this kernel
 - Installation
   - Installing to /lib/modules/5.4.0-74-generic/updates/dkms/

ddcci-backlight.ko:
Running module version sanity check.
 - Original module
   - No original module exists within this kernel
 - Installation
   - Installing to /lib/modules/5.4.0-74-generic/updates/dkms/

depmod...

DKMS: install completed.
  • modprobe ddcci-backlight
modprobe: FATAL: Module ddcci-backlight not found in directory /lib/modules/5.10.16.3-microsoft-standard-WSL2
Diagnostic Logs

No response

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

The report names no source files or tests. Start by reproducing the mismatch with uname -r, ls /lib/modules, DKMS installation, and modprobe; trace how WSL exposes the kernel version and module directory, then verify that DKMS and modprobe use the same version.

Written by the indexing model from the issue text.

Assessment

Tech stack
linux, ubuntu
Domain
operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.