Windows Server

What is Windows Subsystem for Linux (WSL)

Windows Subsystem For Linux is a new feature of the modern Windows system (WSL has been available for Windows 10 since 2017, and starting from Server 2016 version 1803 (released April 30, 2018), WSL can now be installed on WSL). WSL is not an open-source program or Linux kernel, but rather a proprietary Microsoft framework.

To run Windows on Linux, you will need a piece of software called WineHQ. See the following links for more information
– What is WineHQ: How to get and WineHQ https://techdirectarchive.com/2020/05/05/what-is-winehq-how-to-get-and-winehq/ and
– How to install WineHQ on Linux https://techdirectarchive.com/2020/05/05/install-winehq-on-linux-to-run-windows-applications/
– See how to run Windows applications on Linux, see https://techdirectarchive.com/2020/05/05/winehq-how-to-run-windows-applications-on-linux/

With WSL, users can run Linux OS natively on their Windows 10 and Windows Server. This is a real game-changing technology that allows your favorite flavor of Linux whether that be Ubuntu, RedHat, Kali Linux, Alpine, Pengwin, Debian, or openSUSE, to run right in Windows. In this article, we’ll take a look at getting WSL installed and testing out some of the great features it has to offer.

– For how to install the Windows Subsystem for Linux (WSL) on Windows Server via Server Manager and PowerShell, see https://techdirectarchive.com/2020/04/26/virtualbox-how-to-install-the-linux-subsystem-wsl-on-windows-server-via-server-manager-and-powershell/
– How to install the Windows Subsystem for Linux (WSL) on Windows 10, see https://techdirectarchive.com/2020/04/26/virtualbox-how-to-install-the-windows-subsystem-for-linux-wsl-on-windows-10/

A brief difference between Windows Traditional VM and WSL

Virtual MachineWSL – Windows SubSystem for Linux
IsolatedIntegrated
Memory Intensivesmall memory footprint
Managed manuallyRuns only when needed
Slow to boot upFast to bootup

Why WSL? WSL is primarily a development tool, and it exists to help web and software developers for testing purposes.
– Most majority of the software that is run on Windows is actually created in Linux. Before WSL, in the past, to enable Linux to run on Windows, developers have made it work as best they can, creating tools and workarounds like Cygwin or MYSYS so their Linux work plays well with Windows and vice versa.

As discussed, WSL is an important feature for developers. For example, by running a Linux distro with WSL, web developers can be coding in Linux while simultaneously monitoring in realtime the exact page they’re working on via a web browser in Windows, and without requiring extra or paid software. Furthermore, since WSL is a Windows process, you can use Windows tools and functions like the task manager at the same time. Being able to kill a Linux process with the task manager is helpful for those times when something fails or a process hangs.

See the following links for examples
– How to install Ansible on Windows, https://techdirectarchive.com/2020/03/01/ansible-installation-on-windows/
– How to install additional packages via Cygwin, https://techdirectarchive.com/2020/03/02/how-to-install-additional-packages-via-cygwin/
– How to install Cygwin packages from the command line using apt-cyg, https://techdirectarchive.com/2020/03/13/how-to-install-cygwin-packages-from-the-command-line-using-apt-cyg/
– How to install Kerberos packages in Windows via Cygwin, https://techdirectarchive.com/2020/03/14/kerberos-setup-in-windows-cygwin/

WSL Drawback: At the moment, WSL does not support Graphical User Interface (GUI) versions of Linux but rather uses a command-line environment. For how to administer Linux via the web, see https://techdirectarchive.com/2020/04/26/ubuntu-linux-post-installation-and-guest-integration/
– WSL’s command-line interface requires the user to know Linux commands and understand the file organization of a Linux system.

How does the Windows Subsystem for Linux (WSL) work? WSL translates the Linux system calls returned by the process to the Windows kernel calls while a Linux distro sits on top (compatibility layer and this allows to run Linux binaries). It is thus eliminating the need for the Linux kernel in the process. So basically, it is Linux inside Windows. Furthermore, there is no emulation involved whatsoever.

– Underneath the WSL translation layer, implemented as a driver. This is a Windows Driver that implements the Linux Kernel ABI which handles System Calls, Virtual Files, and File Systems.
– At the base of this architecture is the Windows NT kernel.

Differences between WSL2 and WSL1 – Capabilities of WSL2
– An Actual Linux Kernel
– Full System Call Capability
– Socket/Networking Performance
– File System Performance

Obviously, the change brought by WSL 2 is a great and lightweight virtual machine based on Microsoft’s hardware virtualization service Hyper-V.
– Having a native hypervisor helps the WSL2 implementation to pull clear of any disadvantages that WSL1 had when it first launched.
– With the availability of a real Linux Kernal enables the user to execute tasks with full system call compatibility. So, the platform becomes much more potent for handling Linux-based applications

Advertisements
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x