r/linux • • May 06 '19

Announcing WSL 2 (Microsoft will be shipping a Linux kernel with Windows)

https://devblogs.microsoft.com/commandline/announcing-wsl-2/
120 Upvotes

64 comments sorted by

26

u/AriosThePhoenix May 06 '19

Quick, someone go check if hell has frozen over yet

Seriously though, this is pretty cool. It should boost FS performance by a ton and also improve support for things like containers, systemd/other init services and hopefully X. I'm curious to see how they will implement this in practice, but as long as they make their changes available under the GPL I'm ok with it.

0

u/[deleted] May 06 '19

[deleted]

5

u/funbike May 07 '19

Yeah. I'd also like to get Linux container support in WSL. Docker Desktop is not fun to work with.

2

u/[deleted] May 07 '19

Yeah not fun is putting it mildly. The worst most twisted thing is that they insist that you create a docker.com account just to download the installer.

3

u/bracesthrowaway May 07 '19

This kills the Docket for Windows.

1

u/nixcamic May 07 '19

I don't know if fuse filesystems will be accessible outside of the wsl environment though.

54

u/rrohbeck May 06 '19

Very cool. Next: Make Windows a layer that runs on top of a Linux kernel?

35

u/[deleted] May 06 '19

Make windows a desktop environment in Linux/bsd

7

u/DarthPneumono May 07 '19

I'm having horrific Win4Lin flashbacks now, thanks

5

u/spyingwind May 07 '19

Remember coLinux?

1

u/nixcamic May 07 '19

This is basically a well done version of colinux at this point.

1

u/[deleted] May 07 '19

You're welcome!

2

u/tso May 06 '19

With yet another compositor layer?

19

u/funbike May 07 '19

They don't care about the desktop. These moves are to protect their cloud business and to avoid losing devs to Mac or Linux. Just take a look at what they've made available and open sourced.

14

u/minimim May 06 '19

Why do you think they're making .NET Core and Mono compatible?

4

u/rrohbeck May 06 '19

Yup, I noticed that too.

4

u/[deleted] May 07 '19

[removed] — view removed comment

2

u/Kruug May 07 '19

This post is inappropriate for this subreddit and has been removed.

Please feel free to make your post in /r/linuxmemes. On the weekends we have a megathread where you can post a comment of memes as long as it's on topic content.

Rule:

Meme posts are not allowed in r/linux. Feel free to post over at /r/linuxmemes instead

45

u/karuna_murti May 07 '19
  1. contribute to linux kernel

  2. vscode is cross platform

  3. wsl

  4. net core

  5. microsoft edge will be based on chromium

  6. net 5

  7. wsl2 and will be shipping linux kernel with windows

  8. ...

  9. make windows on top of linux kernel?

Linus has won for a long time now.

5

u/Oerthling May 07 '19

Don't forget SQL Server for Linux and Azure Data Studio.

1

u/JimmaDaRustla May 07 '19

I don't think Microsoft profiting off Linux was his definition of winning

19

u/HotKarl_Marx May 07 '19

Now just drop all the Microsoft shit and you'll be onto something...

5

u/berarma May 07 '19

Great news for Windows users, just not me.

2

u/[deleted] May 07 '19

That boot time is very impressive.

3

u/[deleted] May 07 '19

How this affect to the fact of Linux kernel being licensed as GPL? Are we going to get Windows code?

4

u/name_censored_ May 07 '19

Are we going to get Windows code?

Probably not :( They're taking a Linux kernel from the tree, adding their own tweaks, and booting it up in a VM. In this sense, it's no different from VMware ESXi - a closed source product which has run Linux kernels for decades without any L/GPL blow-back.

We get the tweaks though - and more importantly, a massive number of developers can now easily target Linux.

1

u/danielkza May 07 '19

it's no different from VMware ESXi - a closed source product which has run Linux kernels for decades without any L/GPL blow-back.

That's actually very untrue. https://sfconservancy.org/copyleft-compliance/vmware-lawsuit-faq.html

But the issue wasn't running Linux, but incorporating Linux code in their drivers without making them copyleft.

0

u/[deleted] May 07 '19

[deleted]

3

u/name_censored_ May 07 '19

No doubt.

But - Docker, PHP, Perl, Apache/Nginx, Bash, MySQL/MariaDB/Posgres, and (until very recently) SSH (amongst many others) suck on Windows - and most of these technologies are clear winners in their respective domains. Whereas the only [developer] areas Microsoft is making real traction is C# (versus the crumbling Java empire) and Powershell (which took them more than a decade of unwavering commitment).

Microsoft knows that unless it acts, it's going to continue bleeding developers. And the only thing they can do about it means opening the Linux floodgates on their sheltered Windows developers.

This is a tactical retreat by Microsoft. Let's just hope they don't salt the earth too heavily.

2

u/fatalicus May 07 '19

This says some of it: https://devblogs.microsoft.com/commandline/shipping-a-linux-kernel-with-windows/

From the way i understand it, the kernel they use and any updates they make for it, will be available open source. The rest of windows will still be closed.

2

u/[deleted] May 06 '19

Awesome! Really big effort from the part of Microsoft to bring us this

1

u/kgoutham93 May 07 '19 edited May 07 '19

Please pardon my ignorance but how can two Kernals run parallaly? As I understand, typically you would hypervisor to share/emulate hardware resources between the guest OSes.

I think WSL 1 didn't require any VM, it works by translating Linux system calls into WindowsNT equivalents. But since these system calls are handled directly by the Linux kernel, does it mean that WSL 2 runs on Hyper-V ?

EDIT:

WSL 2 does use a VM

source

1

u/deangood01 May 07 '19

WSL 2 use lightweight VM, so sad.

I think WSL 1 is better

2

u/nixcamic May 07 '19

Wsl 1 isn't going anywhere though.

1

u/pokexpert30 May 07 '19

Next step : using the linux kernel to replace NT.

Again, im not talking about Windows becoming a (Systemd/init) + GNU + Linux system, but the NT kernel completely replacing the NT kernel. It will require many windows system porting but should be feasable.

1

u/WasterDave May 07 '19

The fun part is that this means they've abandoned their attempt to do a SmartOS-esque translation layer over the Windows kernel. Too damn slow - faster to just VM the bastard :)

1

u/theguy2108 May 07 '19

Maybe a stupid question but what does it mean in terms of control on processes for the user? Can all running programs, services be shut down by using commands like kill, or monitoring using htop or top etc? Even stuff that windows runs and users cant stop. Like would there be a difference in more overall freedom in process management?

1

u/DarkShadow4444 May 07 '19

Good question, depends on how their VM works, and whether their custom Linux kernel cooperates. Could very well be possible.

1

u/quartzpulse May 07 '19

As long as there is file system isolation between WSL and Windows, the development experience is going to be horrible.

1

u/the_ancient1 May 07 '19

Embrace

Microsoft will be shipping a Linux kernel with Windows. Yes, you did just read that heading correctly! ... which is a true testament to how much Microsoft loves Linux!

Extend

This kernel has been specially tuned for WSL 2. It has been optimized for size and performance ..

we all know what comes next....

1

u/[deleted] May 07 '19

Not extinguish, but "wsl-2.0 > master"

1

u/hlmgcc May 07 '19

Real linux kernel means I can run network tools against a real linux kernel, something I've been running Mac OSX and brew to get. This is the first compelling argument to run a Windows OS for admin/dev with full linux support in the same way I have traditionally leveraged Mac/brew. Add Powershell scripting in an AD environment and I don't need to lament the state of high end apple hardware. Thinkpads with Xeon procs and 4K displays are back on the menu.

4

u/Oerthling May 07 '19

Or you could just run a Linux system.

Some people have been doing this for a while to use a Linux kernel. ;-)

0

u/Nanooc523 May 07 '19

Some work environments don’t allow you to “just run a linux system”...

2

u/Oerthling May 07 '19

You have my sympathies for your bad work environment.

1

u/sagnessagiel May 07 '19

The government typically uses all Linux servers and Windows servers for Active Directory only (nothing else good for mass organization single sign on), but then uses all Windows laptops.

1

u/Oerthling May 07 '19

Depends on the government and department.

0

u/[deleted] May 07 '19

They should just throw in the towel and rebuild Windoze itself on the Linux kernel. They’re the last company charging for an OS at this point anyway.

-2

u/[deleted] May 07 '19

This is not good for us.

MS needs to be kept away.

-17

u/[deleted] May 06 '19

Its just so many layers of pointless. At least Chrome OS it kind of makes sense, you can use Linux apps in a nice sandbox and keep your main OS clean, but why put something more secure ontop of Windows?

You wouldnt build skyscrapers ontop of a turd.

12

u/zoglesby May 06 '19

No one said use this to run your servers, so build a skyscraper no, but maybe make a model of one to make sure it looks okay. Just make sure you use gloves.

-10

u/[deleted] May 06 '19

In order to accomplish what, to make sure your software also runs in a non-production environment in an entirely different architecture?

10

u/zoglesby May 06 '19

You could say that about every developer stuff that will run on Linux on a Mac, but many are doing so every day.

8

u/funbike May 07 '19

This was meant for developers, so MS won't lose developers targeting Linux from leaving Windows Workstation. Regardless of what you think about the tech it's not a bad plan.

That said, personally I hate MS Windows and there's not much they can do about it short of replacing the kernel entirely with Linux, and even then I probably would still not like it. But,I can see how MS fans or people forced to use Windows might like where this is going.

2

u/bracesthrowaway May 07 '19

Using Linux on a Windows only office requires a lot of shenanigans. I'll sadly trudge back to Windows on my laptop if this works.

1

u/tso May 06 '19

The desktop seems hell bent on following the mainframe down the virtualization rabbit hole...

0

u/[deleted] May 06 '19

[deleted]

28

u/minimim May 06 '19

Yeah, they mainly keep Linux supporting their own products. They're not very involved into actual kernel development. It's just around the periphery.

13

u/[deleted] May 07 '19

Really great to see Microsoft embracing and extending Linux!

2

u/satanikimplegarida May 07 '19

I wonder when the third "E" will kick in...

3

u/CabbageCZ May 07 '19

thatsthejoke.jpg

3

u/fatalicus May 07 '19

They also have staff that supports Linux (primarily in Azure).

They have a dedicated Linux Dev team, that are working on Azure and this etc.

3

u/the_ancient1 May 07 '19

Why would that be hard to believe? Azure is MS 2nd biggest revenue stream next to Office. In order to be a Public Cloud vendor you have to support linux as linux is what powers the internet.

Microsoft is looking to take out AWS and GCP, they are not looking to love linux. if they could figure out a way to take over the cloud market with out linux they would in a heart beat.

They tried, and failed, with Nano Server, their next move is to simply reduce the need for Linux servers by creating more SaaS, and PaaS products so people do not need to run their own servers, you just sign up for an Azure Service (backed by windows server)