# Install WSL 2

For Ubuntu downloaded from the Microsoft store, WSL 2 might not be available directly by running the command

```bash
wsl --set-version Ubuntu 2
```

If it errors out, download the "WSL2 Linux kernel update package for x64 machines" update package from <https://learn.microsoft.com/en-us/windows/wsl/install-manual#step-4---download-the-linux-kernel-update-package>

<figure><img src="/files/xs7g4wV3PCCfEE4CuJls" alt=""><figcaption></figcaption></figure>

Run this command to verify the current version

```bash
wsl -l -v
```

When success, it should look something like:

```bash
PS C:\WINDOWS\system32> wsl -l -v
  NAME      STATE           VERSION
* Ubuntu    Stopped         2
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://tk233.gitbook.io/notes/tools/windows/install-wsl-2.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
