-
Notifications
You must be signed in to change notification settings - Fork 833
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WslRegisterDistribution failed with error: 0x80070005 #6744
Comments
Thanks for reporting the issue, and for including a trace. The access denied is coming from an attempt to open HKCU (via RegOpenCurrentUser). Can you check the permissions on that key for your device? And can you share more details about how you are invoking that code fragment? On a clean VM of 21343, after running wsl.exe --install to get WSL configured, I was able to install the Alpine Linux trial from the Store, and was also able to programmatically register Alpine's .tar.gz from a test console app. So I'm suspecting there's something more subtle going on in the environment where you're seeing this. |
Unfortunately I cannot, as I already ran the workaround steps above which fixed the issue. Maybe @airtonix can help (but for him the issue occurred in October)
Sure, but it's basically similar to the reference implementation: https://github.com/agowa338/WSL-DistroLauncher-Alpine/blob/master/DistroLauncher/DistroLauncher.cpp
I suspect it's a bug with the windows release upgrades. At least that was the root of the issue the last few times this occurred. Sadly I haven't been able to find a consistent way to trigger this issue (some semi-annual upgrades go without this problem others cause it). But uninstalling and reinstalling the features listed above fixed the issue in all of these cases. |
Here is what I have for permissions on my HKCU:
Omitted entries starting with S-*, as well as Audit and Sddl. Please let me know if these are needed. Edit: @agowa338 what do your perms for HKCU look like? just for a comparison, you don't have to provide all of it just up to the application package authority. Easy way is in powershell with:
Fixed my issue: This error can be any number of issues, try using WSL dmesg as it will give you more insight to what might actually be causing the access denied error. Note it doesn't always have to do with the registry keys, it could be something as simple as files not existing like wsl expects. |
I encoutnred the following error when installing from Microsoft Store:
I am running Version 2004 (OS Build 19041.985). The HKCU is
I am not able to resolve the issue as I have close to zero knowledge on WSL and OS in general. |
What worked for me when I got this error:
You will be logged on as the almighty root user, but Alpine is a very lightweight distro, and it is unlikely you will do much that you wouldn't want root privileges to execute. If you are running Windows Terminal (you should) you'll see the Alpine distro added to your available launchers. Check out https://docs.microsoft.com/en-us/learn/modules/get-started-with-windows-subsystem-for-linux/7-manage-multiple-distributions which will walk you through creating a (non-root) user in the distro, and then setting that user to default. |
any update on this? |
@Amondale |
I got the same exact problem! And worked everything |
wsl --update |
Due to the error this issue is about, the list was empty, hence no WSL could start. But maybe the issue has been fixed and the |
Works after I removed it and run |
Thank you very much for this solution. - I can echo what venimus said in that it works as expected again after removing and then running For those concerned about their data, the individual distros installations I have seem to be unaffected by this procedure - just made accessible again. |
How do you remove it? I don't have uninstall button in Microsoft Store. |
just go check remove apps at settings and find it or write in the search bar windows subsystem and then press delete |
After the issue, I restarted my computer. Ran |
I faced this issue as well and ThreatLocker was blocking vmw.exe/vmcompute.exe. Switched to learning mode for the install. |
Today I faced the same issue. Using the Uninstall Store version, restart, Just now instead of issuing |
The issue is still there with WSL 2 . I literally followed MS help page and this stuff fails. I already have working Debian and Mint so it is not my WLS2 installation. This is really sad. What I did based on https://learn.microsoft.com/en-us/windows/wsl/install-manual
It fails to start with the error in the original post. This worked for me, but it requires admin user and messing with the folder permissions. I moved the Ubuntu install out of |
I deleted C:\Users\username.wslconfig and it fixed the problem. |
Regression of #4004 and #3020
Environment
Steps to reproduce
Call:
(Or use Alpine Linux App from Store)
WSL logs: https://github.com/agowa338/wsl_etl/blob/main/wsl.etl?raw=true
Expected behavior
API Call succeeds
Actual behavior
API Call throws Access Denied instead of registering the tar.gz
Workaround
The text was updated successfully, but these errors were encountered: