Live data from Hacker News

Windows Subsystem for Linux 2 Moving into General Availability

infoq.com

411–420 of 420 posts

Re: Windows Subsystem for Linux 2 Moving into General Availability

#411
post #41
post #7

I switched to WSL2 a month ago and it's been great. With WSL1 I'd regularly run into subtle compatibility problems but haven't seen anything like that with 2. Despite a handful of annoyances, the Win10+WSL2+Visual Studio Code Dev environment has been a lot more pleasant than OSX.

I never thought I’d say it but because of this exact setup with VS Code I’ve actually stopped using my MBP at home in favor of my desktop, which was really only built with gaming in mind. I’ve now gotten used to having all the extra computing power at hand and would struggle to go back to a laptop as my primary development machine.

I'm currently trying to do the same, I'm sick of running out of ram on my MBP. What software/setups do you find indispensable to move to Windows? I'm not a first time Windows-only user, but first time to do full development work. For what it's worth I already use VSCode, I'm doing FE Development, and I use Docker a lot. I'm kind of unsure due to having to lose my Mac-specific tools such as Maccy (Clipboard Manager) and Alfred (Quick Launcher).

Re: Windows Subsystem for Linux 2 Moving into General Availability

#412

Earlier quoted context omitted.

So the idea is that you put all your work in that network drive and then open it across the network from your IDEs and Explorer etc? I mean, not hating it, but that doesn't feel all too straightforward, definitely less sonthab wsl1 :/

It's not a network path, it's a pseudo-device. Windows uses the \\ UNC file paths for a lot more things under the hood than just network access. There's a bunch of rare device file paths that you'll get UNC paths for, and every folder path canonicalizes to at least one UNC path for multiple reasons. Though it is powering that pseudo-device by a 9p-based file server under the hood, it's not a network accessible path,…

> It's not a network path~

It's a network path listening only on "localhost".

Re: Windows Subsystem for Linux 2 Moving into General Availability

#413
post #33

So WSL2 is supported on windows 10 Home as well, which is great. Does that mean Home also gets official Hyper V support?

There are several Windows features that rely on HyperV under the hood. Home supports them. It does not give the user the ability to run their own virtual machines though.

Re: Windows Subsystem for Linux 2 Moving into General Availability

#414

Earlier quoted context omitted.

It's not a network path, it's a pseudo-device. Windows uses the \\ UNC file paths for a lot more things under the hood than just network access. There's a bunch of rare device file paths that you'll get UNC paths for, and every folder path canonicalizes to at least one UNC path for multiple reasons. Though it is powering that pseudo-device by a 9p-based file server under the hood, it's not a network accessible path,…

> It's not a network path~ It's a network path listening only on "localhost".

At a high level it's much closer to a Win32 Namespace [1] that appears like a network path. UNC stands for Universal Naming Convention, there's no "Network" in the UNC abbreviation as there are many namespaces other than just network paths. Which is why the $ was chosen for the name because it is a valid Namespace character but not a valid system name in Windows, and they wanted to avoid the problem of people with systems named "wsl" suddenly unable to be accessible over the network, because Namespaces have higher priority than network paths. You could think of it as bypassing the network, but it is maybe more accurate to view it that network access is a fallback of UNC paths after all local Namespaces have been checked if they support the path.

Also, yes the current implementation backing that namespace/path is a Plan 9-based network file server, but that's an implementation detail that could change, seems to handled under the covers of the Namespace a little more directly than usual network access (including avoiding a localhost "loopback"), and probably something subject to change as WSL's needs change.

[1] https://docs.microsoft.com/en-us/windows/win32/fileio/naming...

Re: Windows Subsystem for Linux 2 Moving into General Availability

#415

Earlier quoted context omitted.

WSL2 is really not designed for using Linux tools on your NTFS-based filesystem. Store everything on the WSL filesystem, that works perfectly. If you need GUI tools try VcXsrv.

What do you propose if you want to use a windows program to edit those files? For example I use intellij on Windows but want to compile and test on the Linux machine. If it takes 30 seconds longer than wsl 1, why would I bother changing? What is the actual point of wsl if not for the cross compatible filesystems

Samba mount your wsl2 (hyper-v) in Windows. Simple.

Re: Windows Subsystem for Linux 2 Moving into General Availability

#416

Earlier quoted context omitted.

Tip: you get great performance by just installing and running Linux directly.

Yeah I really don't get the desire to do unixey development on Windows. Boot up a VM and SSH into it, if you really must have Windows. It's not like you have to buy a license to use Linux. I keep struggling to understand what WSL brings to Windows. First it was a totally incomplete distro, and now it's just a fucking VM. Seems like a gimmick more than anything. Virtualbox, HyperV, etc will all allow you to access you…

This ^

Re: Windows Subsystem for Linux 2 Moving into General Availability

#417
post #7

I switched to WSL2 a month ago and it's been great. With WSL1 I'd regularly run into subtle compatibility problems but haven't seen anything like that with 2. Despite a handful of annoyances, the Win10+WSL2+Visual Studio Code Dev environment has been a lot more pleasant than OSX.

Could you elaborate why it's been more pleasant than OSX, please?

Re: Windows Subsystem for Linux 2 Moving into General Availability

#418
post #7

I switched to WSL2 a month ago and it's been great. With WSL1 I'd regularly run into subtle compatibility problems but haven't seen anything like that with 2. Despite a handful of annoyances, the Win10+WSL2+Visual Studio Code Dev environment has been a lot more pleasant than OSX.

Could you elaborate why it's been more pleasant than OSX, please?

I'm agnostic to Win10 vs OSX as a desktop environment. What I like is running an real copy of Debian that starts instantly, and has transparent access to local files. I'm sure I could cobble something together with VMWare but this just works so cleanly. Homebrew is a fine option on OSX but its nowhere near is nice a full linux system.

I can also run Linux docker images now.

Re: Windows Subsystem for Linux 2 Moving into General Availability

#419
post #7

I switched to WSL2 a month ago and it's been great. With WSL1 I'd regularly run into subtle compatibility problems but haven't seen anything like that with 2. Despite a handful of annoyances, the Win10+WSL2+Visual Studio Code Dev environment has been a lot more pleasant than OSX.

Cool thanks for the info. Can i just update from wSL1 or do i need to be careful? Bit scared that it will screw up some things :-) Thanks

The update to migrate the filesystem took way longer than the docs said, I ended up just letting it run and came back a few hours later. And it wasn't like I had much in there. Otherwise it was straightforward.

I switched to windows insider to get it, but WSL2 should hit GA in the next month or two.

Re: Windows Subsystem for Linux 2 Moving into General Availability

#420
post #375
post #7

I switched to WSL2 a month ago and it's been great. With WSL1 I'd regularly run into subtle compatibility problems but haven't seen anything like that with 2. Despite a handful of annoyances, the Win10+WSL2+Visual Studio Code Dev environment has been a lot more pleasant than OSX.

What are the annoyances?

The most annoying issues mysteriously fixed themselves after 6mo or so: a trackpad that would go haywire ever once in a while, and diagonal tearing on the screen. It was a brand new model so maybe there were driver updates. The fingerprint scanner is way flakier than the mac. This is on a Lenovo X1 Extreme gen2.

Win10 is just a little less... elegant than OSX. But not in a way that really bothers me on a day to day basis.

Post reply on HN