Forum Discussion

iamvikas's avatar
iamvikas
Copper Contributor
Aug 10, 2021

WSL and VS code issue in windows 11

after upgrading to windows 11 when I run WSL I see this error "An error occurred mounting one of your file systems"

Also when I try to open VS code in WSL it says VS code for wsl closed unexpectedly. 

And the terminal show this error:

 

[2021-08-10 07:59:08.861] sh: 1: /scripts/wslServer.sh: not found
[2021-08-10 07:59:08.861] VS Code Server for WSL closed unexpectedly.
[2021-08-10 07:59:08.861] For help with startup problems, go to
[2021-08-10 07:59:08.861] https://code.visualstudio.com/docs/remote/troubleshooting#_wsl-tips
[2021-08-10 07:59:08.876] WSL Daemon exited with code 0

 

I am at windows 11 pro build : 22000.120

  • reedonly's avatar
    reedonly
    Copper Contributor

    iamvikas you need to open PowerShell with admin privileges and do wsl --update, seems like the kernel needs to be updated to mount the filesystem for wsl.

Resources