You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I try to get CAN support running inside WSL by compiling the kernel modules as follows. If I try to load the module, WSL crashes and immediately shuts down without any error log or something.
This is how I compile the modules inside my running distro:
sudo apt-get install build-essential flex bison libssl-dev bc libelf-dev libncurses-dev dwarves
mkdir /kernel_build
cd /kernel_build
git clone --depth 1 --branch linux-msft-wsl-5.15.123.1 https://github.com/microsoft/WSL2-Linux-Kernel.git
cd WSL2-Linux-Kernel
cat /proc/config.gz | gunzip > .config
make prepare modules_prepare
make menuconfig
-> Networking Support
-> <M> CAN bus subsystem support
-> <M> Raw CAN Protocol (raw access with CAN-ID filtering)
-> <M> Broadcast Manager CAN Protocol (with content filtering)
-> <M> CAN Gateway/Router (with netlink configuration)
-> CAN Device Drivers
-> <M> Virtual Local CAN Interface (vcan)
-> <M> Platform CAN drivers with Netlink support
-> [*] CAN bit-timing calculation
-> [*] CAN devices debugging messages
-> CAN USB interfaces --->
-> <M> PEAK PCAN-USB/USB Pro interfaces for CAN 2.0b/CAN-FD
Save config
make M=drivers/net/can/
make M=net/can
sudo cp drivers/net/can/dev/can-dev.ko /lib/modules/5.15.123.1-microsoft-standard-WSL2
sudo cp drivers/net/can/vcan.ko /lib/modules/5.15.123.1-microsoft-standard-WSL2
sudo cp drivers/net/can/usb/peak_usb/peak_usb.ko /lib/modules/5.15.123.1-microsoft-standard-WSL2
sudo cp net/can/*.ko /lib/modules/5.15.123.1-microsoft-standard-WSL2
sudo depmod -a
sudo modprobe can
Immediately afterwards WSL is crashing and window is closing. Have no clue how to debug this...
If I do a sudo modprobe vcan the module is loaded but actually it is not working because of missing can module.
So I guess the compilation itself is working...
Expected Behavior
Kernel module is loaded
Actual Behavior
WSL crashes and window closes.
Diagnostic Logs
No response
The text was updated successfully, but these errors were encountered:
Hi I'm an AI powered bot that finds similar issues based off the issue title.
Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one and thumbs upping the other issue to help us prioritize it. Thank you!
Hi! We've identified this issue as a duplicate of another one that already exists in this repository. This specific instance is being closed in favor of tracking the concern over on the referenced thread.
Windows Version
Microsoft Windows [Version 10.0.22631.3155]
WSL Version
2.0.0.0
Are you using WSL 1 or WSL 2?
Kernel Version
5.15.123.1-1
Distro Version
Ubuntu22.04
Other Software
No response
Repro Steps
I try to get CAN support running inside WSL by compiling the kernel modules as follows. If I try to load the module, WSL crashes and immediately shuts down without any error log or something.
This is how I compile the modules inside my running distro:
Immediately afterwards WSL is crashing and window is closing. Have no clue how to debug this...
If I do a sudo modprobe vcan the module is loaded but actually it is not working because of missing can module.
So I guess the compilation itself is working...
Expected Behavior
Kernel module is loaded
Actual Behavior
WSL crashes and window closes.
Diagnostic Logs
No response
The text was updated successfully, but these errors were encountered: