"NTFS really isn't that bad" - Robert Collins (LCA 2020)
"NTFS really isn't that bad" - Robert Collins (LCA 2020) on HackerTube: recommended by 5 Hacker News commenters across 3 separate months, 2020–2025.
Robert Collins explains why rustup installs were painfully slow on Windows and how changes to rustup and Windows cut install time from 3m30s to 14s. The talk covers NTFS, small files and the cost of antivirus hooks on file close.
What HN commenters said
12 Hacker News comments link this video. Each one links back to its thread.
miki123211Jan 2025Recommends
And as a result of this, if you want to optimize your program to be fast on Windows, you will make very different optimization decisions than on other platforms. For example, Windows runs virus scans on close(), which makes it very slow. This means that sometimes it makes sense to have one or more background threads exclusively dedicated to closing files. There's a good talk on this at ▶ this video
in “Wild – A fast linker for Linux” · View on HN
ablobJul 2024Recommends
I want to take this opportunity to recommend the talk "NTFS isn't that bad" ( ▶ this video ). NTFS prefers a different access pattern than most usual file systems. I remember that a part of the talk was about speed-ups on Linux as well. So even if it doesn't sway your opinion it should enhance your perspective on how file systems work.
in “Show HN: Dut – a fast Linux disk usage calculator” · View on HN
unchar1Jul 2024Recommends
That may be due to a combination of Malware detection + most unix programs not really written to take advantage of the features NTFS has to offer This is a great talk on the topic ▶ this video
in “SQLite: 35% Faster Than the Filesystem” · View on HN
amiga386Jul 2024Recommends
NTFS can be especially awful if you're used to Linux behaviour, port code over to Windows and expect the same performance. Here's a talk on porting rustup to Windows: ▶ this video To begin with, it takes rustup 3m30s to install on Windows. After rejigging the code again and again away from its naive implementation which works fine on Linux, to perform sympathetically towards NTFS, it takes the same rustup 14s to install. That's quite a performance gain! But it needed a lot of changes to rustup, and to Windows itself.
in “SQLite: 35% Faster Than the Filesystem” · View on HN
jmmvSep 2022Recommends
Add your npm directories to the virus file exclusion lists of Windows Defender. Note that some of the directories may not be obvious (those under AppData for example). The speed improvements are massive for tools like these that touch lots of small files. Also take a look at this talk on NTFS, file system speed, and how the presenter optimized the Rust installer: ▶ this video . There is an awful lot that can be done to tools that deal with lots of files to perform well under Windows too.
in “When to use Bazel?” · View on HN
amiga386Apr 2025Cites it
The thinness is actually part of the problem. POSIX and Windows APIs don't work like each other. For example, if you were a Unix archiver extracting a file, you'd call stat() open() write() close() chmod() utimes(). On Linux/BSD that's 1 file open/close, but on Windows, that's 4 file opens/closes because the Windows APIs need an open filehandle, while the POSIX APIs take a filepath. Linux/BSD have LRU caches of filepath->inode because they're designed around these APIs, Windows doesn't. Cygwin has to open/close a Windows filehandle each time because it can't make the calling code pass a filehandle instead. So it may be more comfortable and familiar, but also Windows APIs are unsympathetic to code designed for Unix originally. See this talk on how the developers of rustup massively improved their performance on Windows by restructuring their code: ▶ this video
in “MinC Is Not Cygwin” · View on HN
Show 6 more comments
nullindividualSep 2024Cites it
But it simply isn't slower than Linux. Robert Collins explains that performance is just as good as Linux and the performance loss on Windows is due to file system filters (Defender)[0]. This is what DevDrive intends (and does) fix. [0] ▶ this video
in “Windows NT vs. Unix: A design comparison” · View on HN
bayindirhDec 2023Cites it
However, the code traverses that amount of data. It doesn't matter if you pass over the same inode n times. From OS point of view, there's no difference. Of course you can write a more complicated calculation algorithm, but it'll require tons of syscalls to determine the type of the file handle you're interacting with and will be probably very slow. This is what rustup did inadvertently back in the day, and it caused NTFS to melt down to a halt because of stat() overhead [0]. [0]: ▶ this video
in “Where Are the Sanity Checks?” · View on HN
CoolColdAug 2023Cites it
to my understanding it's not really IO (reading/writing bytes), but overhead on OpenFile/CloseFile being under AV/Defender inspection. I'm taking that understanding basing on ▶ this video with " "NTFS really isn't that bad" - Robert Collins (LCA 2020) " > Why was rustup slow (3m30s to install (not including download time)) in early 2019 on Windows, and why isn't it slow (14s to install) now? >Early in 2019 I was developing some things in Rustlang on Windows, got frustrated at the performance of rustup (the installer for rust) and looked for bug. I found one which blamed a combination of NTFS, small files and anti-virus software for the problem. This wasn't an entirely satisfactory answer to my mind. Fast forward a bit, and with a combination of changes to rustup and to Windows itself and rustup is now pleasantly usable.... which also improved performance for rustup on NFS mounted home directories.
in “Microsoft's backwards compatibility is insane” · View on HN
CoolColdAug 2023Cites it
Here likely meant that system level hooks of antiviral software are invoked on CloseFile call when you do writes, not on OpenFile. You may want to take a look on ▶ this video
in “Bun v0.8.0” · View on HN
d2waJul 2022Cites it
> Even if windows indexing aint malicious, it certainly behaves as if it is. The problem is that closing files takes a lot of time on Windows. ▶ this video
in “TeamViewer installs suspicious font only useful for web fingerprinting” · View on HN
for_xyzNov 2020Cites it
> the bottleneck is that NTFS is a crappy filesystem. Care to explain why do you think NTFS is crap? From my experience it's usually bad assumptions about files under windows and every application or library tries to stick to posix interface when dealing with files (open, read/write, close) which tends to block for longer periods on windows than on linux counterparts which results in significant perfomance loss . Linux first software will always outperform windows implementation and Windows first software will outperform Linux implementations unless you provide separate code paths to properly handle underlying OS architecture and assumptions. On Windows closing the file handle is extremely costly operation due AV checks and file content indexing [1] [1] ▶ this video
in “Windows Subsystem for Linux: The lost potential” · View on HN