Linus Torvalds Condemns Case-Insensitive File Systems as a Fundamental Flaw

Linus Torvalds Condemns Case-Insensitive File Systems as a Fundamental Flaw

Linus Torvalds, the creator of Linux, has criticized case-insensitive file systems, calling them a ‘bug’ and a ‘horrible’ design choice. The controversy arose from recent patches for the Bcachefs file system, which sparked a discussion on the technical merits and pitfalls of case insensitivity in file systems.

Developer Kent Overstreet started the conversation by explaining how some buggy patches for Bcachefs’ case-insensitive file and folder support were upstreamed into the kernel driver nearly two years ago. Overstreet noted that while the fstests should have included tests, they were not properly executed, leading to issues. He stated, ‘It is _not_ enough to simply rely on the automated tests. You have to have eyes on what your code is doing.’

Torvalds responded by asserting that case-insensitive names are ‘horribly wrong’ and that the problem wasn’t the lack of testing, but implementing it in the first place. He warned that trying to do it right would result in ‘horrible wrong’ outcomes, as ‘right’ doesn’t exist but trying to create it leads to errors.

Additionally, Torvalds criticized the broken nature of the tests, pointing out that they don’t cover all security-critical cases. He emphasized that case sensitivity is a ‘BUG’ and expressed frustration over the continued belief that it’s a feature, likening it to a reverence for the FAT filesystem.

The discussion has led to a lively back-and-forth, with Torvalds highlighting the long-standing issues with case insensitivity in file systems. The conversation has drawn attention from the Linux community and prompted further scrutiny of file system design and testing processes.