
Microsoft's Linux Kernel - polyomino
https://github.com/microsoft/WSLv2-Linux-Kernel
======
mtzet
This is really Microsoft catching up to the Mac in terms of integration with
the open-source ecosystem which importantly drives the web.

In the mid 2000's the Mac really took off due to being a good-enough Linux
replacement on the command line, while taking care of all the hardware
integration and providing a sleek desktop experience. This really helped the
Mac take off among hackers. This system wasn't as open-source as Linux, but it
was good enough: Most of us don't want to mess about with the desktop stack.
If the stack we care about is open-source and runs across many systems, then
we still have the freedom. I find it fairly easy to work on both Mac OS X,
Linux and WSL2 -- but not pre-WSL Windows.

The inclusion of a Linux kernel really seems to cause a lot of confusion. No,
Microsoft is not about to remove the NT kernel. No, they're not about to
supplant Linux. WSL1 did what the guys from Illumos and FreeBSD have also
done: since the Linux syscall interface is quite stable, the NT kernel can
simply implement these syscalls and handle them appropriately. The was that
the NT kernel was still sufficiently different that the filesystem performance
was quite poor and complex applications like Docker required more kernel
features than was provided by just the syscall API.

Including a Linux kernel is really the nuclear option: rather than trying to
fit Linux applications in Windows, they're running in their own world and
providing integrations into this world. This means you can now run Docker on
WSL2 for instance, but it's also complicated: Kernels really like to think
that they own the world, for instance they keep memory around to use for
later. WSL2 dynamically grows the amount of RAM allocated to the VM, which is
quite clever, but I don't know how/if they're going to handle freeing memory
again -- here the NT kernel really needs to communicate with the Linux kernel.

Anyways, the upshot is that no, Microsoft is not going to take over the world,
but perhaps it will be easier to use a Windows laptop which supports all the
stupid Enterprise software I need but still have a Linux shell for actual
work.

~~~
rbanffy
> I find it fairly easy to work on both Mac OS X, Linux and WSL2 -- but not
> pre-WSL Windows

The thing that annoys me most on Windows is Windows itself. After using
Linuxes for almost two decades now, the notion of the OS taking tens of
minutes to self update when all I wanted was to quickly reboot it is
unbearable.

> I don't know how/if they're going to handle freeing memory again -- here the
> NT kernel really needs to communicate with the Linux kernel

Usually "free" memory only happens when a Linux machine starts. During normal
usage most of the memory is being used to cache things and, when some large
app frees its own memory (such as when Slack quits) it'll eventually be used
for other things.

Not sure how that would work. Memory doesn't stay unused in Linux for long -
whatever programs free will end up being used to cache information that's slow
to access.

~~~
ex3xu
> The thing that annoys me most on Windows is Windows itself. After using
> Linuxes for almost two decades now, the notion of the OS taking tens of
> minutes to self update when all I wanted was to quickly reboot it is
> unbearable.

This is definitely a problem especially considering that the shotgun approach
to some Windows updates actually hurt the performance of some machines, even
breaking Windows on occasion [0]. However, in fairness I would say that I've
spent just as much or more time fixing rolling release issues on Arch/Manjaro,
or troubleshooting the package stopping me from sudo apt upgrade. The worst
experience for me was having to reformat after the update from Ubuntu 14.04
crashed.

What annoys me most about Microsoft's overarching paternalistic philosophy is
is how creepy their telemetry initiatives are. Granted plenty of companies do
this now, for the same profit-driven motivations, but Microsoft goes above and
beyond in terms of disabling or even ignoring opt out options [1]. I've found
the Winaero blog [2] to be a good source of tools to stop some of the Windows
telemetry shenanigans.

[0]:
[https://www.forbes.com/sites/daveywinder/2019/05/19/microsof...](https://www.forbes.com/sites/daveywinder/2019/05/19/microsoft-
admits-updates-are-freezing-windows-10-computers-again/)

[1]:
[https://www.reddit.com/r/Windows10/comments/a4lpg0/windows_1...](https://www.reddit.com/r/Windows10/comments/a4lpg0/windows_10_still_collecting_activity_history/)

[2]: [https://winaero.com/](https://winaero.com/)

~~~
gambiting
So after a very long hiatus I have decided to try installing linux on a
raspberry pi - and wow, the results were amazing. Using my decade-old
knowledge of using fstab I added some drives to /etc/fstab and rebooted.
Oooops. Raspbian would fail boot with a message "root account locked, couldn't
open console".

Fantastic - so if any of the fstab entries are missing, the entire system
effectively bricks itself. The only way to fix it was to remove the SD card,
put it in another machine, and manually remove the offending entries from the
fstab file. Fantastic. I Don't think I have ever managed to get windows to
self-brick itself with something so simple.

~~~
ex3xu
With great power comes great responsibility, I guess. I agree it would have
been nice for Linux to come with a few more sanity checks by default, like
maybe a warning flag for rm -rf /* and dd commands...

~~~
gambiting
I'm just more offended that the default behaviour on an extremely popular
distro is failed boot = brick. You don't even get a basic command prompt to
fix something, the default behavior is to lock everything down and forbid
access, making it impossible to repair the machine from itself. Windows will
reboot a few times and then automatically start in safe mode when this
happens, you don't need to extract the drive to manually edit some text files
before the system can boot again.

~~~
majewsky
FWIW, you're using the word "brick" incorrectly. Bricking is when the only fix
is to throw the device away and buy a new one, which clearly is not the case
here.

~~~
gambiting
I don't think I am. I've been fixing hardware for years and any device that
doesn't switch on is "bricked" \- its utility has dropped down to zero, it has
turned into a literal brick. Just because you can revive it through some
arcane procedure doesn't make it any less bricked to the end user.

~~~
majewsky
Flashing a new OS onto the SD card is not "some arcane procedure" for the
RPi's target audience.

------
ChuckMcM
Well that is pretty nice. WSL gets that much more exactly like Linux.

What I really appreciate about WSL is that you get the accessibility of a
bunch of OSS projects and a machine which has legit drivers for all of its
component bits. What this means to me is that searching for a "linux laptop"
won't be a chore, if it runs the latest Windows it will run Linux. And I can
do development on the Linux side while communicating with senior management in
power point on the Windows side :-). If they come up with a better/credible
USB allocation scheme it will be icing on the cake.

I also think they should buy one of the X server vendors and bundle it
(comments about X.org from Redhat not withstanding) I use Xwin32 on my laptop
with WSL and its pretty seamless in terms of things that want to pop up a GUI.

~~~
scardine
There are a few annoyances with WSL2. For me the most important are:

1\. You can't connect to a port listening on WSL localhost like in WSL1, you
have to figure out the WSL IP address and use that.

2\. From WSL you can't connect to a Windows TCP port on localhost, you must
figure out the Windows IP (cat /etc/resolv.conf) and use that.

3\. The WSL remote interpreter on PyCharm is not working anymore. The
suggested workaround is "use SSH remote interpreter" but given #1 you can't
connect to localhost (and the WSL IP changes every time you restart it)

In order to use the SSH remote interpreter in my favorite IDE I'm using this
script (on Windows):

    
    
        import subprocess
        import re
    
        output = subprocess.check_output('wsl.exe ifconfig')
        match = re.search(r"\sinet\s+(\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3})\s", output.decode('utf-8'))
        if match:
            ip = match.group(1)
            with open(r"C:\Windows\System32\drivers\etc\hosts") as i:
                content = i.read()
                new_content = re.sub(r"(172.\d+\.\d+\.\d+)\s+wsl", f"{ip} wsl", content, re.M)       
            if new_content != content:
                try:
                    with open(r"C:\Windows\System32\drivers\etc\hosts", "w") as o:
                        o.write(new_content)
                except PermissionError:
                    print(new_content)
    

First I use the Windows Scheduler to start SSH (wsl service start ssh) on
logon. Then this script is executed on logon with elevated privileges to
update the hosts file. Instead of "localhost", I use "wsl" and it works well
enough for me while I wait for the fixes.

Despite the above, the combo Windows 10 + WSL2 is the best "Linux Desktop" for
me.

~~~
dehrmann
> you must figure out the Windows IP

The existence of c:\Windows\System32\drivers\etc\hosts cracks me up.
Supposedly [citation needed] Windows uses/used part of the BSD network stack.

~~~
nolok
Ahhh, the eternel dilemna they face. Either recreate the wheel and get
complaints about that, or re-use the wheel and have people "crack up" about
you doing that.

~~~
dehrmann
What cracks me up is the irony of seeing ...\etc\hosts on Windows, not the
entire decision.

~~~
nolok
Then I don't understand your comment. What's the irony in there ? Or do you
mean humor instead of irony / is it not irony at all ?

~~~
toyg
The irony is that “etc” makes no sense whatsoever in Windows, and particularly
in that place. It probably came about because it was easier to have it there
than to patch whatever bit of code they borrowed, and it’s now likely
vestigial, but probably there is too much stuff relying on it to change
things. The irony is in an OS trying extremely hard to _not_ be a unix, ending
up with unixy folder names because laziness.

------
mullingitover
I wish Microsoft would release their own linux-based OS with a compatibility
layer to let me run Windows apps. I'm not overly impressed with the direction
Apple is going but I really enjoy a *nix-native environment too much to go
back to vanilla Windows. It would change the math a lot for me if it was full-
blown linux under the hood.

~~~
filmgirlcw
Disclosure: I work at Microsoft but not on Windows (and my work machine is a
MacBook Pro FWIW)

WSL 2 is a lot like that -- it's a VM in the sense that it uses Hyper-V, but
it's super lightweight. And in fact, when WSL 2 is enabled, both Windows AND
Linux are running in the same type of VM (separate, obviously), so it's near-
native performance in a lot of ways. There are still some I/O issues that the
team is actively working on, but early benchmarks are quite promising.

~~~
hermitdev
I'm nervous about WSL 2. I use WSL at home quite a bit and I'm on the Fast
Insider ring. My PC hasnt been able to boot Win10 for over a year with
virtualization support enabled in my BIOS. No errors or anything, just hangs
at boot. Ive left feedback in the hub, but crickets. Don't know what the
problem is. It used to work, but at some point an update broke it. Not
bleeding edge hardware, either. About a 4 to 5 year old PC. Intel i7 CPU,
think it's an X79 chipset (not at the computer, so cant verify). Its just
weird...

~~~
vbezhenar
I had similar problem. With Hyper-V my PC BSODed like every other day. I did
some investigation on dumps and I think that problem was in nvidia driver (not
entirely sure, though, but stacktraces were from that driver). I don't really
know whether it resolved or not, because I decided not to use Hyper-V ever
again, VirtualBox is much better.

~~~
hermitdev
I never got BSODs, just hangs at start, so I don't have any dumps to look at.
I'm also using nVidia (1080 GTX) and it has probably been a few months since I
updated drivers, but I've been having the issue I think since at last the 1803
update.

I havent been on the PC for several weeks, so I don't have a link to my
feedback. I'll post next time I'm on.

------
jdoliner
My brain threw an exception when I read this title. Awesome that this is a
reality though. Now that we have a Linux kernels running and accessible on
both Windows and Chromebooks I feel like we can finally say: 2019 actually is
the year of Linux on the desktop. It's not a meme anymore, it's finally just a
true statement.

Edit: To those questioning if this really counts as Linux on the Desktop. Yes,
I understand what you're saying, I too am a bit of a blowhard about Linux and
prefer to use the real deal, not some kernel on a kernel bs. But I think this
is still a huge deal in terms of the accessibility of Linux, think of how many
young programmers will be able to dip their toes in the Linux pool on their
gaming rigs without having to go through an Ubuntu install process (I write,
thinking in the back of my mind that I had to go through that, and so maybe
they should too.) Yes there is something of an ideological compromise here,
because the Linux they're running is sitting on a binary blob and not truly
free... but Linux still exists in it's gloriously free form for them to use
when they decide that's important to them, I see no harm in them reaping some
of the other benefits of Linux without the freedom, it will hopefully become
an on ramp to more Linux adopters and programmers.

~~~
dehrmann
While people nitpick over what "linux desktop" means, don't lose sight of the
fact that general purpose computing is slowly dying and being replaced by iOS
and Android. Roughly as many iPhones are sold per year as desktops and laptops
combined.

~~~
pjmlp
iOS doesn't use Linux and on Android userspace doesn't actually see it.

[https://developer.android.com/ndk/guides/stable_apis](https://developer.android.com/ndk/guides/stable_apis)

So it is meaningless.

~~~
snaky
There's more than one Android userspace.

[https://github.com/termux/termux-
packages/tree/master/packag...](https://github.com/termux/termux-
packages/tree/master/packages)

~~~
pjmlp
Which isn't fully POSIX, breaks down with every Android release that clamps
down security, and most of it is just plain ISO C, ISO C++ and OpenGL, hardly
Linux specific.

------
antirez
Microsoft: put a good POSIX layer into Windows. The times are mature now, and
this allows your platform to benefit from a lot of open source system software
easily, without portings and compatibility layers. At the same time, now that
developers start to be annoyed big time by Apple nonsensical Mac handling,
this gives a lot of devs, not developing primarily for the Win arch, the
ability to evaluate Windows as a development machine.

~~~
bshacklett
The pure geek in me really wishes they'd bring back SFU. Windows has a really
impressive mechanism for implementing subsystems (I can't remember for sure,
but I believe win32 is actually implemented on top of this layer).

I'm sure there's far more complexity involved than I could imagine, but I've
always loved the idea of having a bunch of different subsystems running
without the need for virtualization.

~~~
signal11
V1 of WSL (which isn’t going to go away IIRC) was essentially an
iteration/improvement of the subsystem model, but with new things like
picoprocesses.

This article[1] has a good overview of the design goals, which mainly was to
let unmodified binaries run.

[1] [https://blogs.msdn.microsoft.com/wsl/2016/04/22/windows-
subs...](https://blogs.msdn.microsoft.com/wsl/2016/04/22/windows-subsystem-
for-linux-overview/)

------
jasoneckert
I'm sure that I'll have a nightmare tonight where I'm stuck in a Scooby Doo
episode, and they unmask the ntoskrnl.exe binary to reveal this Linux kernel
underneath....

------
utopcell
The apt name would be Microsoft/Linux. But that would give Stallman an
aneurysm.

~~~
yjftsjthsd-h
WSL 1 was GNU/NT, I would think.

~~~
anticensor
GNU/LinuxABI@kWindows actually.

------
b3b0p
I've only imagined a Microsoft version of Linux (or BSD or ...). I figured it
was the only way to get a polished consistent experience much like I have
gotten (mostly, but not perfect) from Apple and macOS. The reason I left Linux
on the Desktop in 2006 for macOS. I was tired of inconsistent experience,
constantly tweaking, sleep/suspend/hibernate haphazardly working (or not).

However, the one problem I have with switching to Windows, even with a
flawless WSL (2), or full Linux/BSD/whatever OS under the hood, the whole
Apple ecosystem integration, seamless syncing between all my devices and
accounts will be hard to let go unless something from MSFT / Windows and
company can provide that same convenience. From what I have researched, it's
close, but still not there.

It's too convenient. I know people will say they have problems with it
(iCloud/macOS/iOS syncing/integration), but my experience and all my fellow
constituents and family haven't. So, I have not witnessed nor experienced
these issues people bring up in threads on HackerNews, Reddit, etc that I have
seen (yet can't seem to find exact examples of at the moment with links).

I really admire this work. I hope MSFT continues down the path they have been.
I've always had a soft spot for them. I'm rooting for them.

------
lsllc
I admire what Microsoft have done with WSL and now WSL2, it's really pretty
cool. Satya has done an excellent job revitalizing Microsoft from the Ballmer
days.

However, WTF. Why has the "Microsoft" directory got a leading capital. I mean
every.other.directory.in.linux.is.lower.case!!!!!! Look around folks! Every
other vendor in that tree has their name lowercase, please respect the local
customs!

~~~
butterisgood
Because it’s an English proper noun?

~~~
_emacsomancer_
You mean like 'linux'?

~~~
butterisgood
Sure, but if I worked at Microsoft there might be guidelines on the use of the
company name. I doubt it’s worth reading into as some nefarious situation.

~~~
Dylan16807
The complaint is that it's gaudy, not "nefarious".

------
bin0
Question for those with more technological knowledge than I have: will this
allow AF_PACKET support on windows so I can run monitor mode stuff? CUDA
acceleration?

If I could avoid spending time getting nvidia drivers working on my laptop,
that would be a massive help. And yeah, I know, I'm supposed to buy AMD stuff
so I can use open source etc. But all the best hardware is nvidia, and so top
hardware ships with nvidia. I've got to use this thing for my work as well, so
it's not really an option, and I don't have the technical chops to quickly
debug my drivers or wm or whatever.

~~~
3PS
These are two of their highest requested features at the moment [1] [2], and
if I recall correctly they specifically remarked on passing through hardware
as one of their main priorities going forward with WSL2. Unfortunately it
requires some vendor support so it's not an easy task to solve right away, but
I would stay optimistic.

[1] [https://wpdev.uservoice.com/forums/266908-command-prompt-
con...](https://wpdev.uservoice.com/forums/266908-command-prompt-console-
windows-subsystem-for-l/suggestions/17817685-support-af-packet-address-family-
tcpdump-wireshar)

[2] [https://wpdev.uservoice.com/forums/266908-command-prompt-
con...](https://wpdev.uservoice.com/forums/266908-command-prompt-console-
windows-subsystem-for-l/suggestions/16108045-opencl-cuda-gpu-support)

~~~
bin0
I am indeed very optimistic. As much as I love linux, not having to get
optimus GPUs set up on it would be a massive relief. I've voted on both
before; here's to hoping!

------
z3phyr
Honestly, I would kill to see real shifts and development in operating systems
space and computing space in general. I would rather love to be in a world
where the industry incrementally adapts newer kinds of operating systems in
their workflow, a world where different kinds of ideas (example plan9,
inferno, lisp, oberon) are regularly experimented with in the marketplace.
Here we are stuck with the same kinds of systems which just work in one way,
and working on standardizing it; where CLI programs are still considered
professional;

This is spent effort to be lazy.

Having said that, it is technologically worth studying.

------
oil25
We've come a long way from Bill Gates' original characterization of open
source (long before it was called that) as thievery -
[https://worldhistoryproject.org/1976/2/bill-gates-writes-
ope...](https://worldhistoryproject.org/1976/2/bill-gates-writes-open-letter-
to-hobbyists)

I'm still sure as ever Microsoft is no friend of free (as in Freedom, not
price) software and can't help but shake my head at this latest publicity
stunt. I wouldn't trust their software any further than I throw it.

~~~
hollerith
"Open source" has a precise definition [1], and your comment does not use the
term correctly.

[1] [https://opensource.org/osd](https://opensource.org/osd)

In particular, if the software or "work" was never made freely available by
its lawful owner, it is not open source.

~~~
oil25
Bill wrote his letter 21 years before this definition materialized and it
actually served to inspire the free software/open source concept altogether.

> There is a viable alternative to the problems raised by Bill Gates in his
> irate letter to computer hobbyists concerning "ripping off" software. When
> software is free, or so inexpensive that it's easier to pay for it than to
> duplicate it, then it won't be "stolen".

—Jim Warren, July 1976

------
selimonder
Microsoft gained a lot of respect back! Great move executives, well done. But
I believe in your intentions, keep it right, people like this.

------
tempodox
They still don't have a terminal application that deserves the name. The crap
they built into the Ubuntu app is still the same torturous parody that's used
in the DOS cmd interpreter. Even Cygwin has a much better terminal than that.

~~~
figgis
[https://github.com/microsoft/Terminal](https://github.com/microsoft/Terminal)

------
kpU8efre7r
Too many free / non-free / Linux / OSS ideologues.

Does this let users do more? Does this give users more options? This is a
good, practical feature. I'm excited to, hopefully soon, fully ditch Linux on
desktop for something that actually works.

~~~
posix_me_less
This system even installs new Microsoft software and tracks all your actions
without any respect for you turning it off. Finally you can forget about the
pain of deciding what is going on in your computer. Microsoft just knows the
best so it indeed "just works(TM)". /s

------
idlewords
It's hard to win harder than this. People finding a way to see this as a
betrayal or trick—it's what total victory looks like.

------
mustak_im
What is this repo based on? Was Microsoft working on this since 2004? It's
commit history shows it was started in 2004??

------
gfiorav
I already use WSL1 as my main setup for web dev at work. If Windows comes to a
point where doing anything doesn't immediately make the fan spin to maximum
RPM, I'll be very happy to call Windows my digital home.

------
mrmonkeyman
"Embrace, extend, and extinguish"

These words are not made up by journalists, these are the exact words
Microsoft used internally.

They do this, every. Single. Time.

Everyone keeps falling for it, talking proudly about how MS changed so much
and they are now somehow totally turned around. Yes.. ok, whatever you need to
believe in. Just be warned, they will utterly drstroy everything they come
into contact with.

Or should I say: denial is the most predictable of all human responses. But,
rest assured, this will be the umpteenth time we have destroyed it, and we
have become exceedingly efficient at it.

------
ngcc_hk
No no no. Can’t be. They thought it is cancer ...

The new Microsoft may finally let me go back to windows. Mac is too expensive.

------
tannhaeuser
Please could someone point me to a practical guide for a layman on how to run
Linux apps on Windows 10? I want to give users compact installation
instructions for shell and Node.js apps (1) mostly written for Linux/Mac OS,
but I couldn't figure out what Windows version (Professional?) is required for
WSL/WSL2, and how to install it.

(1) Node.js of course runs natively on Win; however my apps makes particular
assumptions wrt file paths, shared-reading/locking semantics, and spawning
external shell scripts

~~~
bytecod
WSL can be installed on any version of windows 10 from home up.

Users first need to enable the WSL optional feature in their windows install,
then they can install their favorite distro's userland from the windows store.

More detailed instructions here:
[https://aka.ms/wslinstall](https://aka.ms/wslinstall)

~~~
oedmarap
Additionally, if you don't wish to use the Microsoft Store you can download
the distro packages individually. [0]

You then open/unzip the '.appx' package with any archiver such as 7Zip and
place the files in a folder of your choosing; simply launching the distro
executable ('ubuntu1804.exe' for example) to install and register the distro.

You can then use that same executable to launch WSL for that distro in its own
window, which makes it easy to add the icon as a shortcut to your taskbar for
quick access like you would any Windows program, without having to open
command line first.

Added benefit is that you can store all your distros as folders (with
individual rootfs and config files) in a parent location of your choosing such
as a fast external array, without having to use the MS Store or an MS Account.

[0] [https://docs.microsoft.com/en-us/windows/wsl/install-
manual](https://docs.microsoft.com/en-us/windows/wsl/install-manual)

------
sprashanth
Just noticed the contributors as showing "∞ contributors" :D

~~~
judge2020
Same for the official linux source
[https://github.com/torvalds/linux](https://github.com/torvalds/linux)

------
xvilka
Embrace, Extend and Extinguish.

Still, the same until they:

1\. Will give up FAT and exFAT patents

2\. Stop racketeering Android vendors for their patented "inventions"

Also, what happened with NTFS-3G[1] project? Seems dead for many years, while
still not supporting some of the NTFS features. They should at least upload it
to GitHub.

[1] [https://www.tuxera.com/community/open-source-
ntfs-3g/](https://www.tuxera.com/community/open-source-ntfs-3g/)

------
tjpnz
As a dev and Linux/OSX user I'm still struggling to see who exactly this is
for. All of the tools I want to use are very well supported on OSX and I don't
have much use for Microsoft software like Office these days with Google Sheets
et cetera. Is this being geared more towards corporate customers who have
chosen to standardise all of their IT on Microsoft products, but who need
easier access to dev tools/environments?

~~~
bnt
I recently switched to Windows after 10 years of Macs, because I didn’t fee
like forking out €3k for a decent 15” laptop. I switched to a Razer (€1700)
which can actually game + with WSL I can actually do Rails development. After
a month of using this machine, my carpal tunnel pains dropped off
significantly (in part because I ditched the Magic Mouse for a Logitech MX)
and my fingers don’t swell or hurt from bashing a non-existant keyboard on the
MBP. So to me when it comes to computers, Apple is dead.

~~~
slantyyz
FWIW, when I switched from Mac to Windows, I was able to still do Rails
development in Windows itself (I guess it ultimately depends on your Rails app
complexity and the gems you rely on) and deploy my solutions to Linux servers.
This was before WSL came out.

~~~
bnt
For sure, but it was pretty slow (every page reload took ages) and with WSL it
is much faster.

~~~
slantyyz
Really? That's interesting.

I don't have that experience running Rails on Windows. Having said that, I do
use thin for my development instance, so maybe that's why.

------
_ph_
Now we only need a Windows-native Wayland server, which integrates seamlessly
into the Windows desktop and of course just uses the Windows graphics stack.

~~~
anticensor
Windows-native and _.NET-based_ Wayland server.

------
rsrx
This is truly amazing. I have always developed on Windows and recently got a
new contract where whole development environment is based on OSX/Linux. It has
saved me hours and hours of work (and $$$) since I can run their environment
in subsystem, while keeping Windows interface. Thank you, Nadella.

------
emmelaich
What's the bet that MacOS will switch to the Linux kernel within the next five
years?

~~~
_ph_
What would be the motivation for Apple to do such a thing? MacOS is already a
Unix, with a BSD-based userland. Also, they are doing active kernel
development - as in architecture development - to enhance the system security,
so that even root cannot compromise the system. One part of this is moving
kernel extensions into user processes thanks to the fact that Mach is a
microkernel. They couldn't do that with the current Linux architecture.

~~~
emmelaich
Not only can you do it with Linux, a lot is already done; with SELinux,
apparmour, grsecurity, PaX, qubes.

They'd also save on kernel development AND get docker and a lot of other
goodies.

------
rolph
I wonder if they fixed this yet? from 2017 when wsl was beta and not a default
component.

[https://www.theregister.co.uk/2017/09/12/microsoft_downplays...](https://www.theregister.co.uk/2017/09/12/microsoft_downplays_bashware_malware_threat/)

apparently a bash on linux in wsl can deliver a payload to the windows
environment.

if windows is going to ship with its wsl turned on by default, bashware has to
be addressed.

------
hereme888
I see it as another publicity stunt by the Big 5 tech companies to save their
reputation amidst years of anti-privacy violations. From buying Github, to
"supporting" open-source software. Yeah right, more like marketing to save
your reputation. I'll keep moving further and further away from Big Tech. Will
Microsoft send themselves more "aggregated" user data on how their new Linux
kernel is being used? Will this have to be another rule for my firewall to
block?

~~~
kpU8efre7r
How do you guys have time to get any work done with all this zealotry?

~~~
posix_me_less
It is possible. First, sometimes it is more benefitial to just pass on the
shiny corp gadget. They are new, they look cool, everybody talks about them,
but you often find that you can save attention span and protect privacy by
ignoring it (e.g. facebook). Second, this stance make you look for
alternatives. First you give up a lot, you have to work harder to work around.
But if you do, you will have to go deeper into technology and think about how
those things work. So it gives back so much in terms of brain development.

------
galaxyLogic
I think this will benefit windows users because now they have easy access to
Linux but also probably to Linux users who now can write Linux programs that
can access resources on a Windows machine.

Conceptually it amounts to having England and France whose people speak their
own languages and now there is an European Union language translator program
that allows them to talk to each other in their own language. No?

~~~
unilynx
I'd expect it to be mostly one way - Windows can access the Linux stuff.

If I could do COM calls from Linux to a Windows hosted Excel.Application, now
that would be amazing...

------
gagahpangeran
Maybe this will be one of my reasons for returning to Windows.

------
andrekandre
would this have been at all possible if linux had been GPLv3?

------
asanagi_traps
Are they going to push this to upstream ever? How are they, or we, are going
to catch up when thousands of lines of code are added every day.

~~~
oaiey
When I remember right, Microsoft is already a big contributor to the Linux
Kernel. Do not forget, Azure has tons of Linux machines hosted. I think they
know exactly how to ha ndle this.

And I think currently they are just patching their own Linux together like any
distro does

------
mehrdadn
Is WSL2 more than just a VM? How is it different?

~~~
harrygeez
for starters, it's not your typical VirtualBox VM running off your host OS.
The Linux kernel in WSL2 runs on top of Hyper-V _alongside_ Windows, which is
_also_ in a VM.

Microsoft is leveraging the same technology they use to run Windows on Xbox
alongside the game OS, so it's really like an OS with 2 kernels

~~~
mehrdadn
I get that it's on a hypervisor but from a user standpoint how is that
beneficial or any different from just running a normal VM in a hypervisor, is
my question? Like I could've already run Hyper-V and installed Linux, so (how)
is WSL2 different/better?

~~~
oaiey
I cannot answer your question. I can just tell you that they brought back Dave
Cutler from retirement for this concept found in XBox and now Windows 10. This
is definitely not that everyone's VM.

And if you do not know Dave Cutler... Well he is a VMS veteran (a system which
was also ground up virtualized) who designed the Windows NT Kernel. He is
essentially a legend in the field of operating systems and engineering. There
is a nice documentation around him.

------
archey1
Give it a few years, and Windows will be using the Linux kernel while shipping
NT in this way for compatibility reasons.

------
Breo
Hello, folks,

With this kernel we could use unix commands in somekind of terminal? Maybe
node executations will run faster?

------
fithisux
So where are the github repositories with the source code of drivers of the
companies?

------
criddell
Didn't Microsoft agree to never ship a Unix again when they sold Xenix?

~~~
vbezhenar
Linux is not Unix.

~~~
criddell
I can't find details of the sale so maybe I'm wrong, but I thought it also
applied to clone products.

------
guilhas
I'll keep using my Arch linux with Windows in a virtual box. Win win.

------
voltagex_
It's really good - I was able to build extra modules for WSL2 with ease.

------
smitty1e
"I have a dream that was not that of Bill Gates."\--MLK

------
nojvek
Haha. Linux really was a virus. The good kind that eventually won out because
it was open and solved real problems that people wanted it everywhere.

MS really playing the “we’ll go wherever the developers are” game really well.

------
frequentnapper
As an aside, which laptop do people here prefer for windows dev? I am split
between Surface laptop and Lenovo X1 Carbon.

~~~
Const-me
Thick ones, able to house active cooling, and therefore fast CPUs. Where you
can upgrade RAM and SSD with a screwdriver, without a heat gun. A brand
doesn’t matter.

~~~
frequentnapper
I travel quite a bit, so lightness is a requirement.

~~~
Const-me
I have an upgradeable 13.3" laptop, with active cooling, which weights 1.6kg.
Light enough for all practical applications.

------
julienfr112
The cancer grew so much that it now metastazed even in Microsoft Corp !

------
inamberclad
Embrace, extend...

~~~
dmos62
... extinguish [0]

This makes me nervous. This is a win-win now, but who can say they won't just
do what they do and destroy desktop Linux as we know it when theirs gets the
traction necessary? If I were a nefarious assembly of MS execs, my long-term
plan would be to use Windows' UI friendliness and compatibility to attract
Linux users (embrace) and, when there would be a critical mass of users,
extend MS Linux to break compatibility with true Linux (extend and
extinguish).

What about the memorable MS exec quote "Linux is cancer"? For MS, Linux is
cancer. For the consumer, MS is the cancer. Don't use their products. What's a
company got to do to be shunned by the market?

[0]
[https://en.wikipedia.org/wiki/Embrace,_extend,_and_extinguis...](https://en.wikipedia.org/wiki/Embrace,_extend,_and_extinguish)

~~~
ginko
>This is a win-win now

I don't see how this is a win-win. It incentivizes people (like developers who
might otherwise stick to linux) to run a proprietary operating system.

~~~
dmos62
It's a win for the Linux user, because it increases the reach of Linux
software. Think the uninitiated co-worker being able to run your scripts or
something. It's a win for MS, because it makes their platform more powerful.

Of course, to repeat myself, I don't think Windows is a good thing.

------
m0zg
Now get GUI apps and CUDA working, and I'm in.

------
meruru
Who cares about the year of the Linux desktop when the world is still turning
into 1984? There was a reason we wanted Linux to dominate and it wasn't so it
would end like this.

~~~
mycall
Linux desktop means little when people log into Google, Facebook et al.

~~~
meruru
Exactly. Linux won on technical merits, but we failed to educate people about
the really important part about freedom.

~~~
jodrellblank
> Linux won on technical merits

Arguably. It's hard to say Linux won on technical merits of networking
compared to FreeBSD or OpenBSD, or on storage compared to FreeBSD+ZFS, or say
that generally when devs chose MacOS X.

I suggest Linux won for being: the most popular out of the things which cost
$0.

BSD lost for not being popular, commercial Unix, Windows and MacOS lost for
costing money.

~~~
asveikau
> BSD lost for not being popular

People used to say that BSD lost because of the ambiguous copyright status of
the early 90s, allowing Linux to glide in unopposed as the "free unix-like os
for PCs".

[https://en.wikipedia.org/wiki/UNIX_System_Laboratories,_Inc....](https://en.wikipedia.org/wiki/UNIX_System_Laboratories,_Inc._v._Berkeley_Software_Design,_Inc).

[https://en.wikipedia.org/wiki/Berkeley_Software_Distribution...](https://en.wikipedia.org/wiki/Berkeley_Software_Distribution#History)

~~~
mycall
While others say the GPL license is what created an ecosystem, whereby the
BSD-3 won't create an ecosystem of same quality.

~~~
asveikau
It'd also be fair to say *BSD development is more centralized ("cathedral-
like" to borrow from ESRs 1990s work) and that may have some repercussions in
development speed.

------
AdmiralAsshat
All the Linux with none of the freedom. Yaaaay?

~~~
freehunter
To be fair, plenty of people care more about the "Linux" than they do about
the "freedom" part. Case in point: macOS. Basically everything that makes it
"macOS" is proprietary, but it gained popularity because it was mostly Linux-
compatible.

Unix compatibility is worth quite a bit on its own, Linux wouldn't have gotten
half as far without it. And Unix is historically proprietary and closed-
source.

~~~
AceJohnny2
> _And Unix is historically proprietary and closed-source_

"Unix" the brand name, maybe, but "Unix" the source code less so. BSD was
based on Unix. The story of why Linux became popular instead of BSD is that
BSD was mired in a copyright fight with AT&T over that relationship at the
time.

Per
[http://www.catb.org/esr/writings/taoup/html/ch02s01.html](http://www.catb.org/esr/writings/taoup/html/ch02s01.html)
who was active at the time (and before he became today's wingnut)

"It would take another two years and the great Internet explosion of 1993–1994
before the true importance of Linux and the open-source BSD distributions
became evident to the rest of the Unix world. Unfortunately for the BSDers, an
AT&T lawsuit against BSDI (the startup company that had backed the Jolitz
port) consumed much of that time and motivated some key Berkeley developers to
switch to Linux.

> Code copying and theft of trade secrets was alleged. The actual infringing
> code was not identified for nearly two years. The lawsuit could have dragged
> on for much longer but for the fact that Novell bought USL from AT&T and
> sought a settlement. In the end, three files were removed from the 18,000
> that made up the distribution, and a number of minor changes were made to
> other files. In addition, the University agreed to add USL copyrights to
> about 70 files, with the stipulation that those files continued to be freely
> redistributed. -- Marshall Kirk McKusick

The settlement set an important precedent by freeing an entire working Unix
from proprietary control, but its effects on BSD itself were dire. Matters
were not helped when, in 1992–1994, the Computer Science Research Group at
Berkeley shut down; afterwards, factional warfare within the BSD community
split it into three competing development efforts. As a result, the BSD
lineage lagged behind Linux at a crucial time and lost to it the lead position
in the Unix community."

------
kgc
If it ships with Windows, doesn't that mean Windows is GPL now?

~~~
mey
No more than running Linux in a VM makes the hypervisor GPL. They are
distributing it via their store.

------
envolt
The only reason I'm sticking to my Macbook is the Linux based kernal, which
makes it easier for me to use the command line, install NodeJS, build an
application, install Redis Server on my local.

Though everything can be done in Windows, it's not easy to do so.

I specifically remember trying to install Redis on Windows and had to give up
after the end of the day. Ended up creating a server and installing Redis on
that on AWS.

Also, people are complaining that Microsoft once said "Linux is Cancer" at
some point. A lot has changed since then. Ubuntu was released after that which
IMO helped to adopt Linux by an end user.

~~~
chx
What did I just read.

MacBook userspace is derived from NetBSD. The kernel is so far removed from
BSD UNIX it's not worth even mentioning.

This link you commented on points to the kernel used in WSL2 which gives you a
full Linux under Windows. Unlike Mac where you probably will use homebrew to
install Unix packages, this is a full, unadultered Linux machine. Even WSL1
allowed you to install anything from Ubuntu although some (very, very few!)
didn't run, most importantly (for us) some debuggers.

------
jppope
Is this why they say to never push to production on Friday?

~~~
Someone1234
Why? This seems to have been available for at least four days and there's no
obvious problem/mistaken with it.

