"Open in Windows Terminal" doesn't work correctly when WSL directories are mounted into Windows #15929

Closed
opened 2026-01-31 04:52:29 +00:00 by claunia · 3 comments
Owner

Originally created by @DRajsky on GitHub (Nov 19, 2021).

Windows Terminal version

1.11.2921.0

Windows build number

10.0.19043.1348

Other Software

No response

Steps to reproduce

  1. Have Ubuntu 20.04 installed as WSL and \wsl$ mounted as a "Network disk".
  2. In Windows Explorer go to some folder in WSL mounted disk (e. g. Z:\home\rajsky\ali).
  3. Click with right mouse button to open context menu and select "Open in Windows Terminal" (my default one is Ubuntu)

Expected Behavior

Windows terminal should open at the exact folder.

Actual Behavior

Windows Terminal opens in /home directory instead. This only occures in the mounted Ubuntu disk (e.g. if I would open any folder on my C: disk, it would work correctly).
image

Originally created by @DRajsky on GitHub (Nov 19, 2021). ### Windows Terminal version 1.11.2921.0 ### Windows build number 10.0.19043.1348 ### Other Software _No response_ ### Steps to reproduce 0. Have Ubuntu 20.04 installed as WSL and \\wsl$ mounted as a "Network disk". 1. In Windows Explorer go to some folder in WSL mounted disk (e. g. Z:\home\rajsky\ali). 2. Click with right mouse button to open context menu and select "Open in Windows Terminal" (my default one is Ubuntu) ### Expected Behavior Windows terminal should open at the exact folder. ### Actual Behavior Windows Terminal opens in /home directory instead. This only occures in the mounted Ubuntu disk (e.g. if I would open any folder on my C: disk, it would work correctly). ![image](https://user-images.githubusercontent.com/56031388/142625407-107d50ce-528a-4aac-96c5-68cd210a0d64.png)
claunia added the Needs-TriageResolution-ExternalNeeds-Tag-Fix labels 2026-01-31 04:52:29 +00:00
Author
Owner

@elsaco commented on GitHub (Nov 19, 2021):

@DRajsky this only happens when WSL is used as default profile. Check system messages (dmesg output) and you'll find log entries like this:

[Fri Nov 19 07:27:05 2021] init: (21) ERROR: CreateProcessParseCommon:849: Failed to translate Z:\home\val\bin

With pwsh as default profile it works as expected:
pwsh_wsl_open_here

@elsaco commented on GitHub (Nov 19, 2021): @DRajsky this only happens when WSL is used as default profile. Check system messages (dmesg output) and you'll find log entries like this: `[Fri Nov 19 07:27:05 2021] init: (21) ERROR: CreateProcessParseCommon:849: Failed to translate Z:\home\val\bin` With pwsh as default profile it works as expected: ![pwsh_wsl_open_here](https://user-images.githubusercontent.com/3933920/142648893-bc109826-7615-4fed-beca-112d5211d7b9.png)
Author
Owner

@DRajsky commented on GitHub (Nov 19, 2021):

@elsaco Yes, that is correct, but 90 % of the time I use Windows Terminal for the Ubuntu part so it annoys me a bit :D

@DRajsky commented on GitHub (Nov 19, 2021): @elsaco Yes, that is correct, but 90 % of the time I use Windows Terminal for the Ubuntu part so it annoys me a bit :D
Author
Owner

@DHowett commented on GitHub (Nov 19, 2021):

Unfortunately, if we're getting so far as to print a message in dmesg (and init is complaining about the path), this is going to be an issue for https://github.com/microsoft/wsl. ☹️

@DHowett commented on GitHub (Nov 19, 2021): Unfortunately, if we're getting so far as to print a message in `dmesg` (and `init` is complaining about the path), this is going to be an issue for https://github.com/microsoft/wsl. ☹️
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#15929