Windows Version
Microsoft Windows [Version 10.0.26200.8875]
WSL Version
2.9.4.0
Are you using WSL 1 or WSL 2?
Kernel Version
6.18.35.2-1
Distro Version
Ubuntu 26.04
Other Software
No response
Repro Steps
- Create a file with this exact 143-char filename (257 bytes in UTF-8) on a WSL-mounted drive, say
C: drive:
Screenshot 2025-11-05 at 22-15-27 तृप्ति से परम तृप्ति पूज्य गुरु माँ विभाश्री के जीवन की अलौकिक यात्रा Pujya Guru Maa VibhaShree - YouTube.png
- Add other files to the folder containing this file, including files that are both before & after the above filename in lexicographic order.
- Ensure the drive is mounted via 9p:
mount | grep /mnt/c
ls the folder containing it.
Expected Behavior
Directory lists normally. This filename exceeds Linux's 255-byte NAME_MAX by 2 bytes in UTF-8, though it's valid on NTFS (which measures UTF-16 code units, not UTF-8 bytes) — a filename-length issue, not a path-depth one. One unencodable entry shouldn't block listing the rest of the directory.
$ ls
1758974745371.jpg
Screenshot 2025-11-05 at 22-15-27 तृप्ति से परम तृप्ति पूज्य गुरु माँ विभाश्री के जीवन की अलौकिक यात्रा Pujya Guru Maa VibhaShree - YouTube.png
upscaled_1758974745371.jpg
Actual Behavior
Entire listing fails, with some files listed but others not:
$ ls
ls: general io error: Input/output error (os error 5)
1758974745371.jpg
strace shows the raw syscall failing, not a per-file stat call:
getdents64(3, 0x60e1fce1c480, 32768) = -1 EIO (Input/output error)
Running mv "<filename>" shorter.png from WSL confirms Linux can't represent the name at all:
mv: cannot stat '<filename>': File name too long
Confirmed workaround: setting virtiofs=true in .wslconfig resolves this completely - the same file, in the same folder, lists cleanly under virtiofs.
Also, listing the directory from windows (powershell) is non-issue -
> ls
Directory: <some_path>
Mode LastWriteTime Length Name
---- ------------- ------ ----
-a--- 27-09-2025 17:43 213902 1758974745371.jpg
-a--- 05-11-2025 22:15 1621646 Screenshot 2025-11-05 at 22-15-27 तृप्ति से परम तृप्ति पूज्य गुरु माँ विभाश्री के जीवन की अलौकिक यात्रा Pujya Guru Maa VibhaShree -
YouTube.png
-a--- 27-09-2025 17:45 645080 upscaled_1758974745371.jpg
Diagnostic Logs
$ strace -f -e trace=openat,getdents64,newfstatat,lstat ls <directory> 2>&1
...
openat(AT_FDCWD, <directory>, O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 3
newfstatat(AT_FDCWD, <directory>, {st_mode=S_IFDIR|0777, st_size=4096, ...}, 0) = 0
getdents64(3, 0x562df3c50180 /* 3 entries */, 32768) = 88
getdents64(3, 0x562df3c50180, 32768) = -1 EIO (Input/output error)
ls: general io error: Input/output error (os error 5)
1758974745371.jpg
+++ exited with 1 +++
Windows Version
Microsoft Windows [Version 10.0.26200.8875]
WSL Version
2.9.4.0
Are you using WSL 1 or WSL 2?
Kernel Version
6.18.35.2-1
Distro Version
Ubuntu 26.04
Other Software
No response
Repro Steps
C:drive:Screenshot 2025-11-05 at 22-15-27 तृप्ति से परम तृप्ति पूज्य गुरु माँ विभाश्री के जीवन की अलौकिक यात्रा Pujya Guru Maa VibhaShree - YouTube.pngmount | grep /mnt/clsthe folder containing it.Expected Behavior
Directory lists normally. This filename exceeds Linux's 255-byte
NAME_MAXby 2 bytes in UTF-8, though it's valid on NTFS (which measures UTF-16 code units, not UTF-8 bytes) — a filename-length issue, not a path-depth one. One unencodable entry shouldn't block listing the rest of the directory.Actual Behavior
Entire listing fails, with some files listed but others not:
straceshows the raw syscall failing, not a per-file stat call:Running
mv "<filename>" shorter.pngfrom WSL confirms Linux can't represent the name at all:Confirmed workaround: setting
virtiofs=truein.wslconfigresolves this completely - the same file, in the same folder, lists cleanly undervirtiofs.Also, listing the directory from windows (powershell) is non-issue -
Diagnostic Logs