{"id":22617,"date":"2023-07-13T05:00:00","date_gmt":"2023-07-13T03:00:00","guid":{"rendered":"https:\/\/sii.pl\/blog\/?p=22617"},"modified":"2023-10-10T08:53:41","modified_gmt":"2023-10-10T06:53:41","slug":"windows-subsystem-for-linux-wsl-2-part-1-installation-and-configuration","status":"publish","type":"post","link":"https:\/\/sii.pl\/blog\/en\/windows-subsystem-for-linux-wsl-2-part-1-installation-and-configuration\/","title":{"rendered":"Windows Subsystem for Linux (WSL 2). Part 1: Installation and configuration"},"content":{"rendered":"\n<p>Long gone are the days when one had to choose which OS to use \u2013 Windows or any Linux distribution. Some time ago Microsoft introduced a tool that allowed to run Linux programs within Windows OS. Currently, there is a 2<sup>nd<\/sup> version of this tool called <em>Windows Subsystem for Linux<\/em>.<\/p>\n\n\n\n<p>In this article, I\u2019ll describe what a WSL is and how to enable and start working with it.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>What is a WSL?<\/strong><\/h2>\n\n\n\n<p><em>Windows Subsystem for Linux<\/em> is a feature of both \u2013 Windows 10 and Windows 11 that allows<br>to run Linux command-line tools (also some graphical programs), utilities and applications directly from Windows.<\/p>\n\n\n\n<p>In order to do so, at least one of the most popular Linux distributions, such as Ubuntu, Debian, Fedora, Kali Linux etc. needs to be installed within the WSL. This provides a full Linux environment while still being able to use Windows applications and tools at the same time.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>What does the WSL change?<\/strong><\/h2>\n\n\n\n<p>So far, if one wanted to work both with Windows and Linux, there were two main options:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Dual boot \u2013 install Windows and Linux as separate operating systems \u2013 unfortunately it wasn\u2019t the most convenient solution as it was possible to work with one OS at the same time,<\/li>\n\n\n\n<li>VMs \u2013 use virtual machines, for example, Windows as host and Linux as VM, or the other way round \u2013 those were still 2 separate operating systems, that could be run at the same time, but as one was a full VM, it was consuming lots of hardware resources (RAM, CPU, etc.).<\/li>\n<\/ul>\n\n\n\n<p>With WSL, there\u2019s no need to use a dual boot or set up a fully featured VM. The overall experience is more compliant, easier for the end user, and consumes fewer resources than a typical VM.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Difference between WSL 1 and WSL 2<\/strong><\/h2>\n\n\n\n<p>WSL 1 was first introduced in July 2016, while WSL 2 was first introduced in May 2019. Of course, the age of those two features is not the only difference. Their approach to running Linux applications is totally different.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>How does the WSL 1 work?<\/strong><\/h3>\n\n\n\n<p>WSL 1 uses a compatibility layer in order to translate Linux system calls into Windows system calls, allowing Linux binaries to run natively on Windows. This introduces some limitations \u2013 slower file system performance, limited access to system resources and lack of support for running Docker containers.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>How does the WSL 2 work?<\/strong><\/h3>\n\n\n\n<p>WSL 2 handles the same problems quite differently. First of all, there\u2019s no compatibility layer anymore, but a lightweight virtual machine to run Linux kernel. This results in improved performance and better compatibility with Linux applications and tools. What is more, WSL 2 now also supports running Docker containers and provides access to the same system resources as Windows, such as GPUs (especially interesting for Machine Learning), serial ports or USB devices.<\/p>\n\n\n\n<p>As WSL 2 is the newest, recommended-to-use solution, I\u2019ll focus on this version in the article.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Setting up WSL<\/strong><\/h2>\n\n\n\n<p>Enabling WSL is usually easy and straightforward, but can be also a bit tricky at the same time. First of all, you need to remember about few details.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Prerequisites<\/strong><\/h3>\n\n\n\n<p>In order to enable WSL, you need to fulfil the following prerequisites:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Windows 11 or Windows 10 version 2004 and higher needs to be installed,<\/li>\n\n\n\n<li>As WSL 2 utilizes VM, virtualization must be enabled in BIOS\/UEFI,<\/li>\n\n\n\n<li>You need to have admin privileges in the system.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Recommended tools<\/strong><\/h2>\n\n\n\n<p>I\u2019ll use the following tools:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Windows Terminal \u2013 modern terminal application for Windows that provides a CLI environment (for details, please see the <a href=\"https:\/\/learn.microsoft.com\/en-us\/windows\/terminal\/\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\" rel=\"nofollow\" >documentation<\/a>),<\/li>\n\n\n\n<li>Visual Studio Code (see the next article),<\/li>\n\n\n\n<li>IntelliJ IDEA (see the next article).<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Before installation<\/strong><\/h2>\n\n\n\n<p>Before you start, I would really recommend you install the Windows Terminal, as well as\u2026 create a recovery point for the Windows. WSL is quite a mature and proven tool, but it\u2019s still under constant development, and sometimes, after the installation process it causes the OS malfunctions resulting in OS start failure. Therefore, it\u2019s better to be prepared in advance for that scenario, and when the problem occurs \u2013 just to recover the OS to the point before any changes were made.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Installation process<\/strong><\/h2>\n\n\n\n<p>The first step would be to decide, which Linux distribution you would like to use within the WSL. Open Windows Terminal and type in:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl -l -o<\/pre>\n\n\n\n<p>To list all available install Linux distributions. The one marked with an asterisk \u201c*\u201d is the default one that would be installed by command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl --install<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Installation for users with admin privileges<\/strong><\/h2>\n\n\n\n<p>In order to install specific Linux distribution, open Windows Terminal with admin privileges and type in, for example for Ubuntu 22.04 LTS:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl --install -d Ubuntu-22.04<\/pre>\n\n\n\n<p>The admin user to run <em>Power Shell <\/em>has to be the same, one that is currently logged in. When you try to run the <em>Power Shell<\/em> terminal as an admin user, but are different than is currently logged in, you may encounter the following failure:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">Installing: Virtual Machine Platform\nVirtual Machine Platform has been installed.\nInstalling: Windows Subsystem for Linux\nWindows Subsystem for Linux has been installed.\nInstalling: Windows Subsystem for Linux\nCatastrophic failure.\n<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Linux configuration<\/strong><\/h3>\n\n\n\n<p>When WSL is installed, you\u2019ll need to reboot your PC. Then, after you log in again to the OS, a terminal with Linux configuration appears. You need to define a new user \u2013 you can choose whichever name you want, as this is a totally separate Linux OS user \u2013 it\u2019s not connected in any way with a Windows user.<\/p>\n\n\n\n<p>Then you\u2019ll be asked for a password. Again, you can type whichever password you want. Note that no single asterisk nor dot sign appears in the terminal when you type in. This is totally normal behaviour. Just type in the new password and approve it with <em>enter<\/em>. Then retype it again and everything is ready.&nbsp; You can find <a aria-label=\" (opens in a new tab)\" href=\"https:\/\/learn.microsoft.com\/en-us\/windows\/wsl\/setup\/environment#set-up-your-linux-username-and-password\" target=\"_blank\" rel=\"noreferrer noopener\" class=\"ek-link\" rel=\"nofollow\" >best practices for setting up usernames and passwords here<\/a>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Installation for users with no admin privileges<\/strong><\/h2>\n\n\n\n<p>Installation of WSL 2 becomes quite tricky and counterintuitive in this scenario. First of all, even if you know the admin user login and password and open <em>Power Shell<\/em> with that user, you will probably encounter the installation failure mentioned above. You could log in to the OS as an admin user and install WSL 2 from that account, but then the Linux distro would be available only from that admin user.<\/p>\n\n\n\n<p>If you were logged in as a non-admin user, you would have to run <em>Power Shell <\/em>as administrator every time when you\u2019d like to use WSL \u2013 this is not the best solution.<\/p>\n\n\n\n<p>The first step I would recommend in this scenario is to set the default WSL version to 2 by running the following command in <em>Power Shell<\/em> (open Windows Terminal):<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl --set-default-version 2<\/pre>\n\n\n\n<p>Then, install the desired Linux distro, for example, Ubuntu-22.04 LTS:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl --install -d Ubuntu-22.04<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Linux configuration<\/strong><\/h3>\n\n\n\n<p>Linux terminal may appear without rebooting your PC. Follow the same instructions as mentioned above to define a new user and password. Then you can close the Linux terminal.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Check the WSL version<\/strong><\/h3>\n\n\n\n<p>As I mentioned earlier, WSL installation for non-privileged users can be quite tricky. You need to verify which version of WSL was installed by running the command in <em>Power Shell<\/em>:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl -l -v<\/pre>\n\n\n\n<p>If the output is like below:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">NAME            STATE          VERSION\n* Ubuntu-22.04    Running        2\n<\/pre>\n\n\n\n<p>Then you have the correct version of WSL installed. However, if you see 1 under the version, follow these steps to migrate to version 2.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Migration from WSL 1 to WSL 2<\/strong><\/h3>\n\n\n\n<p>Open <em>Power Shell<\/em> (for example by running <em>Windows Terminal<\/em>) as administrator and run the following command to enable the virtual machine feature:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">dism.exe \/online \/enable-feature \/featurename:VirtualMachinePlatform \/all \/norestart<\/pre>\n\n\n\n<p>In the next step <a href=\"https:\/\/learn.microsoft.com\/en-us\/windows\/wsl\/install-manual#step-4---download-the-linux-kernel-update-package\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\" rel=\"nofollow\" >download and open the migration tool described here<\/a>.<\/p>\n\n\n\n<p>After installation, open <em>Power Shell<\/em> and run the following command again:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl --set-default-version 2<\/pre>\n\n\n\n<p>And finally, migrate the existing WSL Linux distro to version 2:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl --set-version Ubuntu-22.04 2<\/pre>\n\n\n\n<p>When the above step completes, you can again verify the version of WSL Linux distro installed:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl -l -v<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Steps to do after installation<\/strong><\/h3>\n\n\n\n<p>Linux distribution within WSL was successfully installed, but how can you get access to it, and what needs to be done now?<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>How to access Linux distribution<\/strong><\/h2>\n\n\n\n<p>In order to use Linux, simply run <em>Windows Terminal<\/em>. Probably (if you haven\u2019t changed it in the settings), the default tab would be a <em>Windows Power Shell<\/em>. You can then choose the down arrow or use the shortcut to open the Linux terminal. One of the advantages of <em>Windows Terminal<\/em> is the fact, that when Linux distribution is installed within the WSL, then it\u2019s automatically registered in the program. See the screen below:<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large\"><a href=\"https:\/\/sii.pl\/blog\/wp-content\/uploads\/2023\/07\/how_to_choose_WSL_terminal.jpg\"><img decoding=\"async\" width=\"1024\" height=\"577\" src=\"https:\/\/sii.pl\/blog\/wp-content\/uploads\/2023\/07\/how_to_choose_WSL_terminal-1024x577.jpg\" alt=\"How to access Linux distribution\" class=\"wp-image-22619\" srcset=\"https:\/\/sii.pl\/blog\/wp-content\/uploads\/2023\/07\/how_to_choose_WSL_terminal-1024x577.jpg 1024w, https:\/\/sii.pl\/blog\/wp-content\/uploads\/2023\/07\/how_to_choose_WSL_terminal-300x169.jpg 300w, https:\/\/sii.pl\/blog\/wp-content\/uploads\/2023\/07\/how_to_choose_WSL_terminal-768x433.jpg 768w, https:\/\/sii.pl\/blog\/wp-content\/uploads\/2023\/07\/how_to_choose_WSL_terminal-555x312.jpg 555w, https:\/\/sii.pl\/blog\/wp-content\/uploads\/2023\/07\/how_to_choose_WSL_terminal.jpg 1115w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><figcaption class=\"wp-element-caption\">Fig. 1 How to access Linux distribution<\/figcaption><\/figure>\n\n\n\n<p>Other option would be to choose Ubuntu from Windows Start menu, but I recommend using <em>Windows Terminal<\/em>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Eventual internet connection issues<\/strong><\/h2>\n\n\n\n<p>It may appear, that there\u2019s no Internet connection from the installed Linux distribution. This can be checked easily by running:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">ping siiportal.sii.pl<\/pre>\n\n\n\n<p>If the output is as follows:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">ping: siiportal.sii.pl: Temporary failure in name resolution<\/pre>\n\n\n\n<p>It means that you have no internet connection from your Linux OS.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Solving the Internet connection problem<\/strong><\/h3>\n\n\n\n<p>The problem is the file <em>\/etc\/resolv.conf<\/em> generated by Windows by default, always when Linux OS is started. To have Internet access automatically, every time, when Linux OS is started, the following steps must be executed:<\/p>\n\n\n\n<ol class=\"wp-block-list\" type=\"1\">\n<li>Add entry in <em>\/etc\/wsl.conf<\/em> in order to stop generating <em>\/etc\/resolv.conf<\/em> file every time, the Linux is started,<\/li>\n\n\n\n<li>Remove <em>\/etc\/resolv.conf<\/em> file as it is a symlink,<\/li>\n\n\n\n<li>Create <em>\/etc\/resolv.conf<\/em> file again with our own <em>nameserver<\/em> entry,<\/li>\n\n\n\n<li>Change the attribute of <em>\/etc\/resolv.conf<\/em> guaranteeing its immutability \u2013 that means this file can\u2019t be edited or removed.<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Stop automatically generating \/etc\/resolv.conf file<\/strong><\/h3>\n\n\n\n<p>Open <em>\/etc\/wsl.conf<\/em> file with admin privileges, for example using <em>nano<\/em>:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">sudo nano \/etc\/wsl.conf<\/pre>\n\n\n\n<p>And add the following entry to the file:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">[network]\n  generateResolvConf = false\n<\/pre>\n\n\n\n<p>Save changes.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Remove \/etc\/resolv.conf<\/strong><\/h3>\n\n\n\n<p>In order to remove the mentioned file, execute command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">sudo rm \/etc\/resolv.conf<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Create \/etc\/resolv.conf again<\/strong><\/h3>\n\n\n\n<p>Create and open the <em>\/etc\/resolv.conf<\/em> file, for example with nano:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">sudo nano \/etc\/resolv.conf<\/pre>\n\n\n\n<p>And add your own DNS server address, for example the Google\u2019s one:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">nameserver 8.8.8.8<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Make \/etc\/resolv.conf file immutable<\/strong><\/h3>\n\n\n\n<p>Execute the following command (it would fail if <em>\/etc\/resolv.conf<\/em> was a symlink):<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">sudo chattr +i \/etc\/resolv.conf<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Verify solution<\/strong><\/h3>\n\n\n\n<p>Now you can close the tab with Linux. You can wait ~ 30 seconds until Linux OS will be stopped automatically by WSL, or make it stop manually by executing:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl --shutdown<\/pre>\n\n\n\n<p>Now check if WSL is stopped:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">wsl -l -v<\/pre>\n\n\n\n<p>The output should be similar to the one below:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">  NAME            STATE          VERSION\n* Ubuntu-22.04    Stopped        2\n<\/pre>\n\n\n\n<p>The most important is the <em>Stopped<\/em> state.<\/p>\n\n\n\n<p>Now you can open Linux terminal tab again and check with the <em>ping<\/em> command if you have a connection to the Internet. If the output is similar to the one below, everything works fine:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">PING siiportal.sii.pl (91.227.21.84) 56(84) bytes of data.\n64 bytes from static-91-227-21-84.devs.futuro.pl (91.227.21.84): icmp_seq=1 ttl=55 time=6.12 ms\n64 bytes from static-91-227-21-84.devs.futuro.pl (91.227.21.84): icmp_seq=2 ttl=55 time=6.17 ms\n(\u2026)\n<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Update Linux distribution<\/strong><\/h2>\n\n\n\n<p>The final step is to update the Linux distribution. You need to remember, that you are responsible for updates and installed software in particular Linux distributions. WSL doesn\u2019t update any Linux distro, nor does it automatically Windows updates.<\/p>\n\n\n\n<p>Execute the following commands in order to update package information and update the OS:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">sudo apt update &amp;&amp; sudo apt dist-upgrade -y<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Conclusion<\/strong><\/h2>\n\n\n\n<p>In this article I\u2019ve described briefly what a WSL is, what are the potential advantages of using this tool and how to install it.<\/p>\n\n\n\n<p>I strongly recommend <a href=\"https:\/\/learn.microsoft.com\/en-us\/windows\/wsl\/install-manual\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\" rel=\"nofollow\" >getting familiar with the official documentation available here<\/a>.<\/p>\n\n\n\n<p>In next article I\u2019ll describe how to configure developer tools to work with installed Linux distribution (<em>Visual Studio Code<\/em>, <em>IntelliJ IDEA<\/em>), as well as how to install and use Docker from WSL.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Sources<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/learn.microsoft.com\/en-us\/windows\/terminal\/\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\" rel=\"nofollow\" >What is Windows Terminal?<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/siipoland-my.sharepoint.com\/personal\/dbaldyga_sii_pl\/Documents\/Blog\/autorzy%20i%20teksty\/Marcin%20Wr\u00f3bel\/\u2022%09https:\/learn.microsoft.com\/en-us\/windows\/wsl\/setup\/environment#set-up-your-linux-username-and-password\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\" rel=\"nofollow\" >Set up your Linux username and password<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/siipoland-my.sharepoint.com\/personal\/dbaldyga_sii_pl\/Documents\/Blog\/autorzy%20i%20teksty\/Marcin%20Wr\u00f3bel\/\u2022%09https:\/learn.microsoft.com\/en-us\/windows\/wsl\/install-manual#step-3---enable-virtual-machine-feature\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\" rel=\"nofollow\" >Enable Virtual Machine feature<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/siipoland-my.sharepoint.com\/personal\/dbaldyga_sii_pl\/Documents\/Blog\/autorzy%20i%20teksty\/Marcin%20Wr\u00f3bel\/\u2022%09https:\/learn.microsoft.com\/en-us\/windows\/wsl\/install-manual#step-4---download-the-linux-kernel-update-package\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\" rel=\"nofollow\" >Download the Linux kernel update package<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/learn.microsoft.com\/en-us\/windows\/wsl\/\" target=\"_blank\" aria-label=\" (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\" rel=\"nofollow\" >Windows Subsystem for Linux Documentation<\/a><\/li>\n<\/ul>\n\n\n\n<p>***<\/p>\n\n\n\n<p>Other articles in the series can be found here:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a aria-label=\"Windows Subsystem for Linux (WSL 2) Part 2: Dev tools configuration (opens in a new tab)\" href=\"https:\/\/sii.pl\/blog\/en\/windows-subsystem-for-linux-wsl-2-part-2-dev-tools-configuration\/?category=hard-development&amp;tag=linux-2,tools,windows-2\" target=\"_blank\" rel=\"noreferrer noopener\" class=\"ek-link\">Windows Subsystem for Linux (WSL 2) Part 2: Dev tools configuration<\/a><\/li>\n\n\n\n<li><a href=\"https:\/\/sii.pl\/blog\/en\/windows-subsystem-for-linux-wsl-2-part-3-docker-installation-and-configuration\/?category=hard-development&amp;tag=linux-2,tools,windows-2\" target=\"_blank\" aria-label=\"Windows Subsystem for Linux (WSL 2). Part 3: Docker installation and configuration (opens in a new tab)\" rel=\"noreferrer noopener\" class=\"ek-link\">Windows Subsystem for Linux (WSL 2). Part 3: Docker installation and configuration<\/a><\/li>\n<\/ul>\n\n\n<div class=\"kk-star-ratings kksr-auto kksr-align-left kksr-valign-bottom\"\n    data-payload='{&quot;align&quot;:&quot;left&quot;,&quot;id&quot;:&quot;22617&quot;,&quot;slug&quot;:&quot;default&quot;,&quot;valign&quot;:&quot;bottom&quot;,&quot;ignore&quot;:&quot;&quot;,&quot;reference&quot;:&quot;auto&quot;,&quot;class&quot;:&quot;&quot;,&quot;count&quot;:&quot;8&quot;,&quot;legendonly&quot;:&quot;&quot;,&quot;readonly&quot;:&quot;&quot;,&quot;score&quot;:&quot;5&quot;,&quot;starsonly&quot;:&quot;&quot;,&quot;best&quot;:&quot;5&quot;,&quot;gap&quot;:&quot;11&quot;,&quot;greet&quot;:&quot;&quot;,&quot;legend&quot;:&quot;5\\\/5 ( votes: 8)&quot;,&quot;size&quot;:&quot;18&quot;,&quot;title&quot;:&quot;Windows Subsystem for Linux (WSL 2). Part 1: Installation and configuration&quot;,&quot;width&quot;:&quot;139.5&quot;,&quot;_legend&quot;:&quot;{score}\\\/{best} ( {votes}: {count})&quot;,&quot;font_factor&quot;:&quot;1.25&quot;}'>\n            \n<div class=\"kksr-stars\">\n    \n<div class=\"kksr-stars-inactive\">\n            <div class=\"kksr-star\" data-star=\"1\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"2\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"3\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"4\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"5\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n    <\/div>\n    \n<div class=\"kksr-stars-active\" style=\"width: 139.5px;\">\n            <div class=\"kksr-star\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 11px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 18px; height: 18px;\"><\/div>\n        <\/div>\n    <\/div>\n<\/div>\n                \n\n<div class=\"kksr-legend\" style=\"font-size: 14.4px;\">\n            5\/5 ( votes: 8)    <\/div>\n    <\/div>\n","protected":false},"excerpt":{"rendered":"<p>Long gone are the days when one had to choose which OS to use \u2013 Windows or any Linux distribution. &hellip; <a class=\"continued-btn\" href=\"https:\/\/sii.pl\/blog\/en\/windows-subsystem-for-linux-wsl-2-part-1-installation-and-configuration\/\">Continued<\/a><\/p>\n","protected":false},"author":538,"featured_media":22626,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_editorskit_title_hidden":false,"_editorskit_reading_time":0,"_editorskit_is_block_options_detached":false,"_editorskit_block_options_position":"{}","inline_featured_image":false,"footnotes":""},"categories":[1320],"tags":[1746,1745,1590],"class_list":["post-22617","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-hard-development","tag-linux-2","tag-windows-2","tag-tools"],"acf":[],"aioseo_notices":[],"republish_history":[],"featured_media_url":"https:\/\/sii.pl\/blog\/wp-content\/uploads\/2023\/07\/Windows-Subsystem-for-Linux-WSL-2.-Part-1-Installation-and-configuration.jpg","category_names":["Hard development"],"_links":{"self":[{"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/posts\/22617"}],"collection":[{"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/users\/538"}],"replies":[{"embeddable":true,"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/comments?post=22617"}],"version-history":[{"count":3,"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/posts\/22617\/revisions"}],"predecessor-version":[{"id":24948,"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/posts\/22617\/revisions\/24948"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/media\/22626"}],"wp:attachment":[{"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/media?parent=22617"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/categories?post=22617"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sii.pl\/blog\/en\/wp-json\/wp\/v2\/tags?post=22617"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}