python3.789
python3.789

Reputation: 326

WSL sometimes cannot create a specific filename in specific Windows folder

This is a very strange error for which I have no explanation.

Sometimes WSL fails to create a file with a certain name, although it does manage to create other files in the same folder, and if I move to another folder it does manage to create the same file.

The problem file name for now is aaaaa

pi@user:/mnt/c/tmp/test$ strace -f touch  aaaaa 2>&1 | grep aaaaa
execve("/usr/bin/touch", ["touch", "aaaaa"], 0x7ffc2b2b29c0 /* 31 vars */) = 0
openat(AT_FDCWD, "aaaaa", O_WRONLY|O_CREAT|O_NOCTTY|O_NONBLOCK, 0666) = -1 ENOENT (No such file or directory)
utimensat(AT_FDCWD, "aaaaa", NULL, 0) = -1 ENOENT (No such file or directory)
write(2, "cannot touch 'aaaaa'", 25cannot touch 'aaaaa') = 25

Create another file:

pi@user:/mnt/c/tmp/test$ strace -f touch  bbbbb 2>&1 | grep bbbbb
execve("/usr/bin/touch", ["touch", "bbbbb"], 0x7ffd266aa790 /* 31 vars */) = 0
openat(AT_FDCWD, "bbbbb", O_WRONLY|O_CREAT|O_NOCTTY|O_NONBLOCK, 0666) = 3

How can I resolve that?

Upvotes: 2

Views: 42

Answers (0)

Related Questions