Davi Silva
Davi Silva

Reputation: 83

Is it okay to switch between WSL versions whenever I need to?

I just recently installed Windows Subsystem for Linux 2. My only current Distro is Ubuntu and I'm using it for everything I do. I know that WSL 1 is better to handle projects that interact with both Windows and Linux, while WSL 2 is better for projects specific to Linux only.


I might want to switch between the versions depending on what I'm working on, and I would like to if it's safe to continuously change between versions?


Another alternative I found was doing something like:

wsl --export Ubuntu ubuntu.tar
wsl --import Ubuntu2 ./Ubuntu2 ubuntu.tar

and then setting the version of the second one with wsl --set-version Ubuntu2 2.

Upvotes: 8

Views: 2463

Answers (1)

wxz
wxz

Reputation: 2546

Based on this FAQ from Microsoft:

We currently have no plans to deprecate WSL 1. You can run WSL 1 and WSL 2 distros side by side, and can upgrade and downgrade any distro at any time.

That being said, the switch from one to the other is described as a "conversion", so I would suggest have backups of important files when you switch back and forth (generally a good idea anyway).

Upvotes: 2

Related Questions