error when launching..Could not access starting directory #14000

Closed
opened 2026-01-31 03:58:05 +00:00 by claunia · 19 comments
Owner

Originally created by @xtiansimon on GitHub (May 28, 2021).

Windows Terminal version (or Windows build number)

1.8.1444.0

Other Software

  • PowerToys v0.37.2 (newly installed ~2 weeks)
  • Windows 10 Pro 20H2 Build 19042.985 (newly installed < 1mo.) No other issues.
  • Kate 21.04.0 (newly installed ~1 week)
  • Windows Terminal Settings?
    • Added paste setting
    • added color schemes
      • "Gruvbox Dark",
      • "Gruvbox Dark Blu",
    • Anaconda and WSL2 settings
            {
                "colorScheme": "Gruvbox Dark",
                "commandline": "cmd.exe /K %USERPROFILE%\\Miniconda3_32\\Scripts\\activate.bat",
                "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6102}",
                "hidden": false,
                "icon": "%USERPROFILE%\\Miniconda3_32\\Menu\\Iconleak-Atrous-Console.ico",
                "name": "Anaconda Prompt (Miniconda3_32)",
                "startingDirectory": "C:\\Users\\myname",
                "tabTitle": "Anaconda (qb)"
            },
            {
                "bellStyle": "none",
                "colorScheme": "Gruvbox Dark Blu",
                "guid": "{58ad8b0c-3ef8-5f4d-bc6f-13e4c00f2530}",
                "hidden": false,
                "name": "Debian",
                "source": "Windows.Terminal.Wsl",
                "startingDirectory": "C:\\Users\\myname",
                "tabTitle": "WSL (Debian)"
            },

Steps to reproduce

This happened after latest update. I tried toggling WSL in "manage app execution aliases" as recommended in another recent post but this did not improve the broken Windows Terminal. Windows Terminal error 0x80070003 when launching `fedoraremix.exe' #10167

Repair is not sufficient. Only Reset brings back the WSL functionality. If I reset Windows app and return to base settings then Debian works, but of course Conda is missing.

I have nearly the exact same setup on my remote work computer-- same Windows Terminal version, Windows Terminal settings (except for different path/machine name), recent installs of PowerToys and Kate. Windows 10 version on work computer is also the same. I remote into using RDP. No issues there.

I use Windows Terminal nearly every day to use Debian to SSH into remote server. Have experience no issues until yesterday.

Expected Behavior

Launch of Anaconda or WSL2 Debian

Actual Behavior

[error 0x8007010b when launching `wsl.exe -d Debian']
Could not access starting directory "C:\Users\myname"

[error 0x8007010b when launching `cmd.exe /K %USERPROFILE%\Miniconda3_32\Scripts\activate.bat']
Could not access starting directory "C:\Users\myname"
Originally created by @xtiansimon on GitHub (May 28, 2021). ### Windows Terminal version (or Windows build number) 1.8.1444.0 ### Other Software - PowerToys v0.37.2 (newly installed ~2 weeks) - Windows 10 Pro 20H2 Build 19042.985 (newly installed < 1mo.) No other issues. - Kate 21.04.0 (newly installed ~1 week) - Windows Terminal Settings? - Added paste setting - added color schemes - "Gruvbox Dark", - "Gruvbox Dark Blu", - Anaconda and WSL2 settings ``` { "colorScheme": "Gruvbox Dark", "commandline": "cmd.exe /K %USERPROFILE%\\Miniconda3_32\\Scripts\\activate.bat", "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6102}", "hidden": false, "icon": "%USERPROFILE%\\Miniconda3_32\\Menu\\Iconleak-Atrous-Console.ico", "name": "Anaconda Prompt (Miniconda3_32)", "startingDirectory": "C:\\Users\\myname", "tabTitle": "Anaconda (qb)" }, { "bellStyle": "none", "colorScheme": "Gruvbox Dark Blu", "guid": "{58ad8b0c-3ef8-5f4d-bc6f-13e4c00f2530}", "hidden": false, "name": "Debian", "source": "Windows.Terminal.Wsl", "startingDirectory": "C:\\Users\\myname", "tabTitle": "WSL (Debian)" }, ``` ### Steps to reproduce This happened after latest update. I tried toggling WSL in "manage app execution aliases" as recommended in another recent post but this did not improve the broken Windows Terminal. [Windows Terminal error 0x80070003 when launching `fedoraremix.exe' #10167](https://github.com/microsoft/terminal/issues/10167) Repair is not sufficient. Only Reset brings back the WSL functionality. If I reset Windows app and return to base settings then Debian works, but of course Conda is missing. I have nearly the exact same setup on my remote work computer-- same Windows Terminal version, Windows Terminal settings (except for different path/machine name), recent installs of PowerToys and Kate. Windows 10 version on work computer is also the same. I remote into using RDP. No issues there. I use Windows Terminal nearly every day to use Debian to SSH into remote server. Have experience no issues until yesterday. ### Expected Behavior Launch of Anaconda or WSL2 Debian ### Actual Behavior ``` [error 0x8007010b when launching `wsl.exe -d Debian'] Could not access starting directory "C:\Users\myname" [error 0x8007010b when launching `cmd.exe /K %USERPROFILE%\Miniconda3_32\Scripts\activate.bat'] Could not access starting directory "C:\Users\myname" ```
claunia added the Needs-TriageNeeds-Tag-FixNeeds-Attention labels 2026-01-31 03:58:05 +00:00
Author
Owner

@zadjii-msft commented on GitHub (May 28, 2021):

Huh. Out of curiosity, what happens when you remove startingDirectory from your settings?

We stopped validating those before on launch in #10045. Before that, we'd just silently fall back to %userprofile% when we couldn't validate the directory.

@zadjii-msft commented on GitHub (May 28, 2021): Huh. Out of curiosity, what happens when you remove `startingDirectory` from your settings? We stopped validating those before on launch in #10045. Before that, we'd just silently fall back to `%userprofile%` when we couldn't validate the directory.
Author
Owner

@xtiansimon commented on GitHub (May 29, 2021):

"...remove startingDirectory from your settings?"

I think that fixed it.

The issue happened immediately these past few days, so maybe it's fixed?
Is it better I close the issue solved now? Or, I will be using WT more extensively tomorrow (Saturday 5/29). I can report back the results after further use, and close it then, too.

@xtiansimon commented on GitHub (May 29, 2021): > _"...remove startingDirectory from your settings?"_ I think that fixed it. The issue happened immediately these past few days, so maybe it's fixed? Is it better I close the issue solved now? Or, I will be using WT more extensively tomorrow (Saturday 5/29). I can report back the results after further use, and close it then, too.
Author
Owner

@Faris999 commented on GitHub (May 29, 2021):

Huh. Out of curiosity, what happens when you remove startingDirectory from your settings?

This error just happened to me today, and this fixed it. I think the startingDirectory field becomes null. Maybe because of an update?

@Faris999 commented on GitHub (May 29, 2021): > Huh. Out of curiosity, what happens when you remove `startingDirectory` from your settings? This error just happened to me today, and this fixed it. I think the `startingDirectory` field becomes `null`. Maybe because of an update?
Author
Owner

@xtiansimon commented on GitHub (May 29, 2021):

I will be using WT more extensively tomorrow (Saturday 5/29). I can report back the results after further use, and close it then, too.

So far so good. Thanks for the input zadjii-msft.

@xtiansimon commented on GitHub (May 29, 2021): > I will be using WT more extensively tomorrow (Saturday 5/29). I can report back the results after further use, and close it then, too. So far so good. Thanks for the input `zadjii-msft`.
Author
Owner

@eamodio commented on GitHub (May 29, 2021):

I was seeing the same thing, and it looked like a % character was lost in the startingDirectory field -- it had %USERPROFILE\foo rather than %USERPROFILE%\foo. This seemed to happen to all my profiles, and everything worked fine before the upgrade.

@eamodio commented on GitHub (May 29, 2021): I was seeing the same thing, and it looked like a `%` character was lost in the `startingDirectory` field -- it had `%USERPROFILE\foo` rather than `%USERPROFILE%\foo`. This seemed to happen to all my profiles, and everything worked fine before the upgrade.
Author
Owner

@eamodio commented on GitHub (May 29, 2021):

IMO this should be re-opened

@eamodio commented on GitHub (May 29, 2021): IMO this should be re-opened
Author
Owner

@nozzlegear commented on GitHub (May 30, 2021):

The latest update seems to have broken my starting directory as well. Manually editing the starting directory fixed the issue, but I had made no changes to it from the default installation and this update broke it.

@nozzlegear commented on GitHub (May 30, 2021): The latest update seems to have broken my starting directory as well. Manually editing the starting directory fixed the issue, but I had made no changes to it from the default installation and this update broke it.
Author
Owner

@ThomasRedstone commented on GitHub (May 31, 2021):

I'm seeing this happen as well, my starting directory was set to /home/tom/, which does exist within WSL, but Terminal was trying to set the starting directory to C:/home/tom, if I create a home directory within Windows it will then run WSL, but I start in /mnt/c/home/tom.

@ThomasRedstone commented on GitHub (May 31, 2021): I'm seeing this happen as well, my starting directory was set to `/home/tom/`, which does exist within WSL, but Terminal was trying to set the starting directory to `C:/home/tom`, if I create a home directory within Windows it will then run WSL, but I start in `/mnt/c/home/tom`.
Author
Owner

@akempe commented on GitHub (May 31, 2021):

It doesn't seem to be possible to set the starting directory to anywhere inside the WSL file system. Everything you put there seems to get appended/mapped to a Windows path. @xtiansimon would you mind re-opening this?

@akempe commented on GitHub (May 31, 2021): It doesn't seem to be possible to set the starting directory to anywhere inside the WSL file system. Everything you put there seems to get appended/mapped to a Windows path. @xtiansimon would you mind re-opening this?
Author
Owner

@ThomasRedstone commented on GitHub (Jun 1, 2021):

It doesn't seem to be possible to set the starting directory to anywhere inside the WSL file system. Everything you put there seems to get appended/mapped to a Windows path. @xtiansimon would you mind re-opening this?

Quite right, though I don't believe I ever set the value, so perhaps the update is changing it to something that isn't valid?

@ThomasRedstone commented on GitHub (Jun 1, 2021): > It doesn't seem to be possible to set the starting directory to anywhere inside the WSL file system. Everything you put there seems to get appended/mapped to a Windows path. @xtiansimon would you mind re-opening this? Quite right, though I don't believe I ever set the value, so perhaps the update is changing it to something that isn't valid?
Author
Owner

@DHowett commented on GitHub (Jun 1, 2021):

It doesn't seem to be possible to set the starting directory to anywhere inside the WSL file system.

This has never been possible, but due to aggressive path "validation" it was ignored, and reset to C:\Users\yourname. For some people, this looked like it was working. In every case, however, it was not. Folks just had invalid startingDirectory settings that were being ignored instead of reported.

@DHowett commented on GitHub (Jun 1, 2021): > It doesn't seem to be possible to set the starting directory to anywhere inside the WSL file system. This has never been possible, but due to aggressive path "validation" it was _ignored, and reset to C:\Users\yourname_. For some people, this looked like it was working. In **every case**, however, it was not. Folks just had invalid `startingDirectory` settings that were being ignored instead of reported.
Author
Owner

@akempe commented on GitHub (Jun 1, 2021):

It doesn't seem to be possible to set the starting directory to anywhere inside the WSL file system.

This has never been possible, but due to aggressive path "validation" it was ignored, and reset to C:\Users\yourname.

Makes sense, but this isn't exactly clear and I'm sure confuses a hell of a lot of people as I'm pretty sure they're not expecting to be dealing with the Windows FS in those settings. I note the point made in #10305 that we should use //wsl$/{distro}/home/{wsl username}, but this feels like it's not obvious either. Am I missing some docs or coming at this wrong?

@akempe commented on GitHub (Jun 1, 2021): > > It doesn't seem to be possible to set the starting directory to anywhere inside the WSL file system. > > This has never been possible, but due to aggressive path "validation" it was _ignored, and reset to C:\Users\yourname_. Makes sense, but this isn't exactly clear and I'm sure confuses a hell of a lot of people as I'm pretty sure they're not expecting to be dealing with the Windows FS in those settings. I note the point made in #10305 that we should use `//wsl$/{distro}/home/{wsl username}`, but this feels like it's not obvious either. Am I missing some docs or coming at this wrong?
Author
Owner

@DHowett commented on GitHub (Jun 1, 2021):

We've got some documentation specifying this, but we could probably make it clearer and surface it in the UI somewhere.

@DHowett commented on GitHub (Jun 1, 2021): We've got [_some_ documentation](https://docs.microsoft.com/en-us/windows/terminal/troubleshooting#set-your-wsl-distribution-to-start-in-the-home--directory-when-launched) specifying this, but we could probably make it clearer and surface it in the UI somewhere.
Author
Owner

@wolf99 commented on GitHub (Jun 2, 2021):

My settings use "startingDirectory": "//wsl$/Ubuntu/home/{user}" which is correct per #10305 but I'm still seeing this error when WT is launched before WSL is running ("cold" start).
If I start WSL in advance (a "warm" start), then WT has no problem with this path... does that point to a different root cause?

@wolf99 commented on GitHub (Jun 2, 2021): My settings use `"startingDirectory": "//wsl$/Ubuntu/home/{user}"` which is correct per #10305 but I'm still seeing this error when WT is launched before WSL is running ("cold" start). If I start WSL in advance (a "warm" start), then WT has no problem with this path... does that point to a different root cause?
Author
Owner

@DHowett commented on GitHub (Jun 2, 2021):

This is a somewhat annoying issue where WSL cannot handle \\wsl$ paths until it's been launched once, which we're hoping to ameliorate with #9223

@DHowett commented on GitHub (Jun 2, 2021): This is a somewhat annoying issue where WSL cannot handle `\\wsl$` paths until it's been launched once, which we're hoping to ameliorate with #9223
Author
Owner

@AaronMcHale commented on GitHub (Jun 14, 2021):

Getting a similar or the same problem. I have my start directory set to //wsl$/Ubuntu/home/aaron, this has been working fine for me for a long time, until today where after installing Windows 10 Cumulative Update for June 2021, I now get an error on starting WSL inside Windows Terminal. I have to start WSL outside of Windows Terminal first, using the default starting directory, then opening WSL inside Windows Terminal works, which is now rather annoying.

@AaronMcHale commented on GitHub (Jun 14, 2021): Getting a similar or the same problem. I have my start directory set to `//wsl$/Ubuntu/home/aaron`, this has been working fine for me for a long time, until today where after installing Windows 10 Cumulative Update for June 2021, I now get an error on starting WSL inside Windows Terminal. I have to start WSL outside of Windows Terminal first, using the default starting directory, then opening WSL inside Windows Terminal works, which is now rather annoying.
Author
Owner

@mwoodpatrick commented on GitHub (Aug 1, 2021):

I'm seeing the same issue in Version 10.0.22000 Build 22000, it does seem like this issue should be reopened

@mwoodpatrick commented on GitHub (Aug 1, 2021): I'm seeing the same issue in Version 10.0.22000 Build 22000, it does seem like this issue should be reopened
Author
Owner

@alvarochvz commented on GitHub (Aug 9, 2021):

Reporting that this issue is present on my windows version

Version 10.0.19043 -- Compilatio 19043

@alvarochvz commented on GitHub (Aug 9, 2021): Reporting that this issue is present on my windows version Version 10.0.19043 -- Compilatio 19043
Author
Owner

@DHowett commented on GitHub (Aug 9, 2021):

Yes, this issue should be moved to the wsl repository

@DHowett commented on GitHub (Aug 9, 2021): Yes, this issue should be moved to the [wsl repository](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#14000