WSL: stderr gives permission errors

snotnose

Ars Tribunus Militum
2,747
Subscriptor
System is a 1 week old laptop with the latest Win11 and WSL. From the shell prompt I can redirect to /dev/stderr fine. From a shell script I get permission denied errors.

Yeah, there are workarounds (I haven't tried any yet) like use fd 2 instead of stderr, but, um, really? When I first learned Unix 40+ years ago the first things I learned was stdin, stdout, and stderr. They're kinda basic.

I've done the distro-upgrade, upgrade, and update a couple times. Funny how if you wait an hour there's always something to update :)

I'm not looking forward to changing/testing a bunch of existing shell scripts and would really like to fix this.