4 ms·
Personally I never had a problem with filesystem performance on WSL 1. I certainly don't think it was so bad that the whole thing needed to be scrapped in favor
by shawnz 7y ago
Personally I never had a problem with filesystem performance on WSL 1. I certainly don't think it was so bad that the whole thing needed to be scrapped in favor of a virtual machine.
- mehrdadn 7y agoTry doing git filter-branch. ;)
- jrockway 7y agoWindows does something weird with the filesystem that I have never figured out. In a msys2 shell, git is incredibly incredibly slow. I actually don't even bother running git in msys2 anymore; I just use the native git in that directory. (I use msys2 to cross-compile AVR stuff.) This seems to be a known issue, but nobody knows how to fix it. (It's some UAC thing, apparently.) I imagine this is what WSL 1 used, and it was similarly slow.
- zlynx 7y agoAs far as I know it's a fundamental kernel architecture decision that Microsoft can't just "fix." From the original NT microkernel design, filesystem access is all asynchronous messaging, and it can be intercepted and modified by drivers at many points. A lot of software takes advantage of that. But it's also why caching isn't as effective as it could be, since you can't rely on all those unknown layers returning the same result each time. Plus a lot of Windows systems are running an AV which likes to check to see if you should be allowed to read any particular file in case it might be dangerous.
- WorldMaker 7y agoAlso, NTFS has very different (multi-file) ACID guarantees and transaction semantics compared to most POSIX file systems. A lot of performance differences between Windows and POSIX file APIs make some sense in a NoSQL versus SQL database analogy: they make very different guarantees about what the "atomic commit" level is, what is stored and how it is stored, what is locked and how and when it is locked. They both have great uses and there are trade-offs to both approaches, you can't always rely on the performance of an application built for one running performatively on top of the other.
- mycall 7y agoI thought ReFS was suppose to give Windows different atomics and I'm surprised they haven't push it further into their client OS.
- WorldMaker 7y agoThe impression Microsoft gives to me is that ReFS is meaningfully only beneficial over NTFS in RAID configurations with multiple physical drives (otherwise NTFS and ReFS have very similar semantics on a single physical drive), so pushing it any further than "Windows Storage Spaces" sounds unlikely, and few consumer machines have more than one physical drive in any configuration much less a software RAID configuration. In relation to the above conversation about WSL1 performance characteristics, my impression is that ReFS would be equal or worse to NTFS for what Linux/POSIX file operations expect. (ReFS is still very much on the "SQL Database" side of the analogy, like NTFS as it was of course designed to support much the same transactional semantics, and some additional ones as well at the "virtual storage space" level above the physical pool of drives.) In danger of getting further aside into tangential spaces, Ubuntu's current experimentation with ZFS by default is probably one to watch to see if the user experience of complicated multi-physical disk file systems like ReFS can be made to fit and is useful to a broader user base than just power users. (Though arguably compared to the broader spectrum of casual Windows users, even some of the more casual Ubuntu users might be considered power users in comparison.)
- temac 7y agoYep, Windows FS is very slow. If you have an antivirus it is extremely slow, but even if you don't, it is still very slow. This is not really an issue of msys2 or WSL, this is an issue of Windows itself.
- mehrdadn 7y agoMSYS2 git has its own overhead; what you're seeing there isn't the Windows or native git overheads (though those also exist).
- james-mcelwain 7y agoReally? I found it slow enough to basically not be able to use any of my regular build systems (Maven, NPM, Cargo, etc.).
- kevin_thibedeau 7y agoTry running Node on Windows. Even without WSL the poor NTFS performance is a serious drag.
- malkia 7y agoI've been compiling fuchsia in it, and yes, the file performance is really bad - Normally "gn" does not take that much time to generate ninja files, but under WSL1 it takes significantly more. Later building these files, the impact is taken by the CPU mostly, but still there is lots of I/O so much slower.