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
Shutdown WSL using the following command:
wsl --shutdown
Restart WSL and now Windows exes like VSCode will no longer start with the error:
run-detectors: unable to find an interpreter for /mnt/c/Users/MyUserName/AppData/Local/Programs/Microsoft VS Code/Code.exe
To fix this, I found on the internet that I could create a file /usr/lib/binfmt.d/WSLInterop.conf and set it's contents to the following:
:WSLInterop:M::MZ::/init:PF
Once I create that file containing the above text, and rebooted WSL, Windows exe would start as expected when running inside WSL
Expected Behavior
I expect that when I enable systemd support in WSL, I should be able to continue to run Windows exes inside WSL, just as they had worked before enabling systemd
Actual Behavior
By enabling systemd support in WSL, I no longer was able to run Windows exes
Diagnostic Logs
No response
The text was updated successfully, but these errors were encountered:
This issue has been automatically closed since it has not had any activity for the past year. If you're still experiencing this issue please re-file this as a new issue or feature request.
Windows Version
Microsoft Windows [Version 10.0.22621.1848]
WSL Version
1.2.5.0
Are you using WSL 1 or WSL 2?
Kernel Version
5.15.90.1
Distro Version
Ubuntu-22.04
Other Software
Visual Studio Code, version 1.79.2
Repro Steps
Add the following lines to /etc/wsl.conf:
[boot]
systemd=true
Shutdown WSL using the following command:
wsl --shutdown
Restart WSL and now Windows exes like VSCode will no longer start with the error:
run-detectors: unable to find an interpreter for /mnt/c/Users/MyUserName/AppData/Local/Programs/Microsoft VS Code/Code.exe
To fix this, I found on the internet that I could create a file /usr/lib/binfmt.d/WSLInterop.conf and set it's contents to the following:
:WSLInterop:M::MZ::/init:PF
Once I create that file containing the above text, and rebooted WSL, Windows exe would start as expected when running inside WSL
Expected Behavior
I expect that when I enable systemd support in WSL, I should be able to continue to run Windows exes inside WSL, just as they had worked before enabling systemd
Actual Behavior
By enabling systemd support in WSL, I no longer was able to run Windows exes
Diagnostic Logs
No response
The text was updated successfully, but these errors were encountered: