Live data from Hacker News

Windows Subsystem for Linux 2 Moving into General Availability

infoq.com

21–30 of 420 posts

Re: Windows Subsystem for Linux 2 Moving into General Availability

#22
post #9

I really hope apple implements something similar, would much prefer to have a well integrated linux vm than the not-quite-linux of macos

This is an interesting take considering Linux is Unix-like and macOS is technically a BSD derivative. I don’t think macOS will ever have a Linux syscall translation layer/subsystem (WSL1) nor a lightweight VM with special integration (WSL2) but you can do sort of similar things in third party software, I think. Docker for Mac is using the native VM framework and includes a filesystem integration called osxfs, but des…

doesn't macOS put a BSD translation of some sort in their kernel? Theres a microkernel, a driver api (device kit) and then 'bsd'

Re: Windows Subsystem for Linux 2 Moving into General Availability

#23
post #14

Question -- from what I understand, WSL2 is closer to Linux running in a VM, whereas WSL1 was like a Windows kernel level version of Cygwin. Is that mostly correct? Regarding that, remember a number of years ago, prior to VMs there was a patch set for the Linux kernel porting it to user space -- so you could run Linux as a user process, which ended up functioning similar to running it in a VM. Would WSL2 be closer to…

Correct. WSL1 ran ELF binaries on Windows (as crazy as it sounds). WSL2 is basically linux in a VM + OS provided helper services on both sides.

Re: Windows Subsystem for Linux 2 Moving into General Availability

#24
post #14

Question -- from what I understand, WSL2 is closer to Linux running in a VM, whereas WSL1 was like a Windows kernel level version of Cygwin. Is that mostly correct? Regarding that, remember a number of years ago, prior to VMs there was a patch set for the Linux kernel porting it to user space -- so you could run Linux as a user process, which ended up functioning similar to running it in a VM. Would WSL2 be closer to…

> Question -- from what I understand, WSL2 is closer to Linux running in a VM, whereas WSL1 was like a Windows kernel level version of Cygwin. Is that mostly correct?

Yes, that's essentially correct. You could also think of it as WINE in reverse; one big difference from cygwin is that it runs unmodified binaries rather than needing to recompile.

> prior to VMs there was a patch set for the Linux kernel porting it to user space -- so you could run Linux as a user process

User Mode Linux (UML; https://en.wikipedia.org/wiki/User-mode_Linux), which I think is still a thing, although not super popular.

> Would WSL2 be closer to this model, or is it really running Linux under a stripped down Hyper V?

Not even stripped down; it's running Hyper V. (This is one of the big problems with WSL2; if you use it, you can't use non-HyperV virtualization.)

Re: Windows Subsystem for Linux 2 Moving into General Availability

#25
post #14

Question -- from what I understand, WSL2 is closer to Linux running in a VM, whereas WSL1 was like a Windows kernel level version of Cygwin. Is that mostly correct? Regarding that, remember a number of years ago, prior to VMs there was a patch set for the Linux kernel porting it to user space -- so you could run Linux as a user process, which ended up functioning similar to running it in a VM. Would WSL2 be closer to…

WSL 1 was closer to flinux than cygwin.

Ah, I completely forgot about flinux. Seems there were a lot of neat innovations back in the earlier days, including a couple of single system images (SSI) implementations (the opposite of VMs, making a network of hosts look like a single multiple processor system).

Re: Windows Subsystem for Linux 2 Moving into General Availability

#27
post #3

> He further mentions that unzipping tarbars could see a 20 times performance increase. Boy, do I love unzipping tarbars! On a more serious note, it’s great that WSL has gotten much faster, although it’s a little disappointing that they threw out the older, more interesting architecture to get it and just used a VM.

I agree wholeheartedly. I know it was probably a fool’s errand especially in a world where Docker for Windows was doing the same thing WSL2 does but worse, but WSL1’s design just satisfied me in a way that Hyper-V will not. Presumably, this also means you have to have Hyper-V enabled, crippling all other VM software. Hope the integration is impressive at least, to hopefully make up for it. I admittedly don’t run Wind…

> Presumably, this also means you have to have Hyper-V enabled, crippling all other VM software

How does hyper-V cripple other VM software?

I just had to enable it to use a prebuilt VM I need, now I’m a little worried

Re: Windows Subsystem for Linux 2 Moving into General Availability

#29
post #9

Earlier quoted context omitted.

This is an interesting take considering Linux is Unix-like and macOS is technically a BSD derivative. I don’t think macOS will ever have a Linux syscall translation layer/subsystem (WSL1) nor a lightweight VM with special integration (WSL2) but you can do sort of similar things in third party software, I think. Docker for Mac is using the native VM framework and includes a filesystem integration called osxfs, but des…

doesn't macOS put a BSD translation of some sort in their kernel? Theres a microkernel, a driver api (device kit) and then 'bsd'

random wikipedia image that somewhat supports what I was thinking https://en.wikipedia.org/wiki/Darwin_(operating_system)#/med...
Post reply on HN