WSL is saying it can't find the path specified

Pan, Dihua 0 Reputation points
2023-08-15T13:54:54.7433333+00:00

Run powershell with administrator, and then execute wsl command, but getting error "The system cannot find the path specified."

User's image

If I click the "Reset" button in Windows Subsystem for Linxu app under Apps and Features, and then execute wsl command immediately, wsl command is working, but after 2 or 3 seconds, and execute wsl command one more time, then it returns "The system cannot find the path specified." again. What's going on here, what should I do? I have tried uninstall wsl_update, removed Windows Subsystem for Linux from windows features, and then reinstalled everything, still no luck. Please help. Thanks.

Untitled

User's image

Windows
Windows
A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.
5,074 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Limitless Technology 44,101 Reputation points
    2023-08-16T09:32:22.1266667+00:00

    Hello

    Thank you for your question and reaching out.

    Run with cmd administrator then type below command in each line then press Enter.

    wsl --shutdown

    wslconfig /unregister Ubuntu

    wsl --install --distribution Ubuntu

    Please Note: If you forgot the distro name, Please run 'wsl --list' from cmd line.

    --If the reply is helpful, please Upvote and Accept as answer--

    3 people found this answer helpful.