Microsoft

Microsoft surprised us with the news that soon everyone can run a bash console Linux natively on Windows 10. The feature, available for Windows Insiders in future builds of Windows 10, you can then turn to those members that community can evaluate it. In summer this option will extend to all audiences with the arrival of the update “Anniversary”.

How does this feature? As Microsoft noted in the presentation, not virtual machines for this option is used, nor containers. Microsoft had long been preparing for this movement, and its alliance with Canonical has made ​​us to access a unique way to run both bash other Ubuntu binaries directly and natively. The key: the so – called Windows Subsystem for Linux (WSL).

Microsoft
Image Source: Google Image

This is a native on Windows Linux, without further

He explained, among others, Dustin Kirkland, one of those responsible for Canonical, in his blog. There confirmed that neither virtualization and containers had nothing to do with this implementation, and neither had much to do with Cygwin, which until now was one of the most popular ways to do something similar to what has now been achieved in Windows 10.

As indicated Kirkland, Cygwin uses Linux binaries recompiled to adapt and convert Windows binaries. As explained in the FAQ, the cornerstone of this development is “the library that provides POSIX system calls and environment these programs expect.”

Actually what happens in Windows is more like an emulator, Kirkland noted, explaining that what is done here is “making a real – time translation system call Linux system calls the Windows operating system.” It is telling us, something that could be considered as the inverse of what makes wine, a project that allows precisely can run Windows binaries on Linux systems.

The work done in Astoria Project was not vacant

Ars Technica they went a little further to explaining the origins of this technology, which has an interesting predecessor: Project Astoria. The technology would allow move applications from Android to Windows 10 was abandoned because of technical difficulties, though they so focused otherwise – but some of the work that was being done for this project has served to give life to that console support bash in Linux.

When Microsoft began working on this project he developed several components to the Windows kernel. He did it with lxcore.sys or lxss.sys, for example, two -when they were discovered, allowing mysterious – components to support most of the Linux kernel APIs. Be careful, because as highlighted in Ars Technica it comes to components that do not have GPL (not Open Source) and do not contain code Linux “instead, implement the API of the Linux kernel using the native API Windows NT kernel that provides Windows”. And that’s what we have ended up baptizing quoted as Windows Subsystem for Linux.

You may also like to read another article on Web2GB: Accessing Safe Mode Windows 10

Therein lies the difference with alternatives such as Cygwin, since the mechanism of translation and execution of system calls made ​​that one can, indeed, work with applications and binary ELF Linux natively and identical to what we would do on an Ubuntu system “conventional”. Canonical has provided a system image (for Ubuntu 14.04 LTS now, but soon released with Ubuntu 16.04 image LTS) containing among other things Ubuntu versions of several of the command – line tools usually found in a Linux distribution.

Many advantages, but also some limitations

This subsystem allows achieving a truly remarkable performance for that run Linux applications in Windows 10. As indicated Kirkland, benchmarks as sysbench indicate that performance in this embodiment is “substantially equivalent” that would obtain with a native Windows installation for performance of CPU, memory and system input / output.

This developer spoke to advantages such as being able to access directly to all units of our Windows 10 system directly: each is mounted in the traditional directory (/ mnt / c, / mnt / d, etc, but reverse is also true, we can ride all Ubuntu file system from the file browser Windows 10)). Access to other utilities like ssh and said support apt-get (wonderful, really) really opens up interesting possibilities for any developer Linux.

That, however, does not hide the limitations of this implementation. For starters, keep in mind that this is something that is in full development and therefore will appear failures from time to time. There will be applications and tools that do not work as they should, and Kirkland gave as examples to known and great byobu, screen and TMux session management console.

Even those responsible for Microsoft themselves also warned to indicate that not all bash scripts and tools available work. They also pointed out something important: this is a set of developer tools “to help them write and develop your code for all scenarios and platforms”.

This is not a server platform on which host websites, run server infrastructure, etc. For such scenarios recommended solutions Ubuntu use their services in the cloud (Azure). And finally also they indicated that Linux tools like bash cannot interact with Windows applications and tools. “You cannot run the notebook from bash or bash can run Ruby from Powershell” clarified.

In this session video Build 2016 just gave important details on the operation of this system, like the ELF binary support that we talked about and that shows that we are running the same tools that would run on a system Ubuntu natively install:

Will we support other distributions, or even access to a graphical environment?

Many Linux users surely are wondering if this type of property can go further in the future and support interesting options. For example, other Linux distributions, which at first seem feasible, given the way of working of this subsystem Linux which translates system calls.

You may also like to read another article on Web2GB: Do you control Windows updates?

Sorry: not think we can have access to Unity or other window managers and desktop environments that Ubuntu in Windows.

Kirkland’s own description of how prepared the image of Ubuntu for Windows 10 users could use this operating system certainly suggests that many others could do the same. Here, though, probably need to reach agreements with Microsoft for the Redmond company also distributes those images to users who are not comfortable with Ubuntu and your tools or your package manager can do the same with other distributions with other thermodynamics and other package managers.

Another frequently asked question is probably affecting graphics applications.Can we have a graphical session or execution of programs with its graphical user interface (GUI)? That seems less likely as a user who spoke about it on Reddit and indicating that there are no plans to offer that option: “this is really aimed at developers; it not supposed to function as a virtual machine or a substitute for Cygwin”.

Too bad: it seems that will not be possible (or at least easy) to run applications in environments such as GNOME or KDE. That has already been the last straw, but he certainly made ​​by Microsoft is certainly interesting and unthinkable a few years ago, do not you think?

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.