News for hackers. Stuff that matters.
Re:Initial preview of GUI app support for the Windows Subsys... by thorum on Wednesday April 21, 2021 @02:17PM (#26893427)
That's really cool.

When I tried WSL a while back, file system access was pretty slow especially for scanning large folder trees with many files (important for programming projects). Is this still an issue or has it improved in that area?

Re:Initial preview of GUI app support for the Windows Subsys... by craigaloewen on Wednesday April 21, 2021 @02:28PM (#26893589)
We improved the file system performance overall when we introduced WSL 2 by about 3-6x in general, and 20x for specific disk heavy operations. This still does bring its own challenges (You'll need to move your files to the Linux file system, and Cross OS file perf is slower in WSL 2) but we are working on these as well! :)
Re:Initial preview of GUI app support for the Windows Subsys... by Negitivefrags on Wednesday April 21, 2021 @03:23PM (#26894255)
From our perspective WSL2 only made file system performance worse. The caviet of moving files to the Linux file system is kind of a big one.

We just want to Rsync some files from a Linux server to a windows build server without garbage performance and somehow there isn’t a way to do that still.

Re:Initial preview of GUI app support for the Windows Subsys... by madeofpalk on Wednesday April 21, 2021 @08:45PM (#26897295)
> The caviet of moving files to the Linux file system is kind of a big one.

Trying not to sound reductive, but either it's an issue for you or not. It's really going to depend on your use case which should be super apparent for you.

I do all my web development within WSL2 and its great. I suspect this is the main use case they're optimising for.

Re:Initial preview of GUI app support for the Windows Subsys... by e12e on Wednesday April 21, 2021 @04:40PM (#26895148)
With native opensshd in windows, and a windows build of rsync - why would wsl be needed?
Re:Initial preview of GUI app support for the Windows Subsys... by Negitivefrags on Wednesday April 21, 2021 @04:43PM (#26895193)
What windows build of Rsync are you referring to?

I haven’t found one that doesn’t use Cygwin (slow filesystem).

Re:Initial preview of GUI app support for the Windows Subsys... by e12e on Wednesday April 21, 2021 @05:08PM (#26895471)
I thought there was a mingw build, but apparently not. :/

You see that slow file access with cygwin?

Last time I had such a use case for windows, I used unision - but isn't rsync, of course.

https://www.cis.upenn.edu/~bcpierce/unison/

Judging by this scoop.sh issue, there are no obvious not-cygwin builds/ports:

https://github.com/lukesampson/scoop/issues/2295

Looks like there are libraries for rust and go - but not clients that are a drop in replacement (yet).

Re:Initial preview of GUI app support for the Windows Subsys... by Negitivefrags on Wednesday April 21, 2021 @08:28PM (#26897176)
Cygwin is faster than WSL2 but not faster than WSL1 from the last time we tested.

Our builds involve syncing directories that have several hundred thousand files in them so the speed of stat() is really the bottleneck.

I’ll give unison a look, I haven’t tried that.

The libraries are an interesting idea, I’ll look into that too.

Re:Initial preview of GUI app support for the Windows Subsys... by binarycrusader on Wednesday April 21, 2021 @05:13PM (#26895523)
Haven't tried this commercial client myself and I'm not endorsing it, but this one claims to be native rsync without cygwin:

https://acrosync.com/windows.html

Re:Initial preview of GUI app support for the Windows Subsys... by Negitivefrags on Wednesday April 21, 2021 @08:22PM (#26897134)
I’ve looked into it. It’s not really the right use case for pushing data to and from a build server. It’s more designed for a continuous backup situation with a GUI.
Re:Initial preview of GUI app support for the Windows Subsys... by ohthehugemanate on Wednesday April 21, 2021 @02:33PM (#26893658)
That's an issue with WSL1, which translated system calls from Linux to Windows. Unfortunately the Linux and Windows filesystem drivers are radically different; many operations that are fast/cheap on linux (eg checking file metadata, which is stored in memory) are super exensive on the NT kernel (eg metadata involves reading the file from disk, and running any programs that have registered event handlers for file reads... like virus scanners and context menu items). So Git, for example, which on Linux keeps its state spread across thousands of files' metadata, was a dog.

WSL2 takes a different approach: HyperV was always good at thin VMs... they took it to the next level and made WSL2 a super thin VM. Now performance is near native, depending on your benchmark.

Bias: I work at MS in an unrelated area. I run Arch as my daily driver, but am damn impressed by the engineering in WSL2.

Re:Initial preview of GUI app support for the Windows Subsys... by forgotpwd16 on Wednesday April 21, 2021 @03:09PM (#26894108)
Are those operations an issue on the NT kernel or the NTFS filesystem?
Re:Initial preview of GUI app support for the Windows Subsys... by dataflow on Wednesday April 21, 2021 @04:31PM (#26895061)
The former.
Re:Initial preview of GUI app support for the Windows Subsys... by eknkc on Wednesday April 21, 2021 @02:29PM (#26893605)
WSL2 has its own filesystem (ext4 and everything). Accessing it is fast, accessing windows filesystem from wsl and vice versa is still slow.

This is a big deal because, say you wanted to use intellij idea on wsl, using it on windows side and accessing the wsl filesystem does not really work. It is too slow. Now you can run it in linux, access the native fs. I imagine it would perform pretty good.

Re:Initial preview of GUI app support for the Windows Subsys... by hnbad on Wednesday April 21, 2021 @05:36PM (#26895750)
FWIW this is why VSCode has the Remote extension, which includes support for running VSCode headless in WSL and connecting to that from Windows.

Theoretically this change would eliminate the need for that but it's nice to have the same VSCode on Windows as in WSL.

Re:Initial preview of GUI app support for the Windows Subsys... by voidfunc on Wednesday April 21, 2021 @02:41PM (#26893757)
Perf is decent, I already do this with x410 and IntelliJ. I have noticed some quirks tho with slow syncs between editor and actual file contents that ive never noticed on a host running just Linux
Re:Initial preview of GUI app support for the Windows Subsys... by _-david-_ on Wednesday April 21, 2021 @03:45PM (#26894484)
I haven't tried this yet, but would something like this https://blog.jetbrains.com/blog/2021/03/11/projector-is-out/ help out?
Re:Initial preview of GUI app support for the Windows Subsys... by jnwatson on Wednesday April 21, 2021 @02:29PM (#26893609)
File system access definitely had issues for WSL 1. WSL 2, however, is much perkier.

FYI, WSL 1 and WSL 2 are completely different architectures, so you have to explicitly upgrade your instances from 1 to 2.