WSL icon indicating copy to clipboard operation
WSL copied to clipboard

WSL2 WSLRegisterDistribution Error 0x80071772

Open NickITGuy opened this issue 5 years ago • 12 comments

  • Your Windows build number: Microsoft Windows 10 Pro Version 10.0.19041.207 (Type ver at a Windows Command Prompt)

  • What you're doing and what's happening: Download Ubuntu 20.04 LTS from Microsoft Store, Go to windows start menu and start Ubuntu 20.04 LTS (Or go to command line and type ubuntu2004) (Copy&paste the full set of specific command-line steps necessary to reproduce the behavior, and their output. Include screen shots if that helps demonstrate the problem.)

  • What's wrong / what should be happening instead: I get the following error

Ubuntu2004 Installing, this may take a few minutes... WslRegisterDistribution failed with error: 0x80071772 Error: 0x80071772 The specified file is encrypted and the user does not have the ability to decrypt it.

Annotation 2020-04-24 113255

NickITGuy avatar Apr 24 '20 02:04 NickITGuy

After a reboot and a reinstall this issue fixed its self.

NickITGuy avatar Apr 24 '20 03:04 NickITGuy

Can this be reopened? I have this on Windows 11. This happens when I try to install Ubuntu on a non-system drive. @NickITGuy probably managed to get it working because after a restart and reinstall, MS Store installs the distro back on C: (instead of D: for some reason). This is a consistent behavior that I have replicated on my machine a few times.

VishalSubramanyam avatar Jan 02 '23 19:01 VishalSubramanyam

I have the same issue

ezhupa99 avatar May 14 '23 02:05 ezhupa99

Thanks! reinstalling solved my problem.

DDLdancer avatar May 27 '23 12:05 DDLdancer

Can this be reopened? I have this on Windows 11. This happens when I try to install Ubuntu on a non-system drive. @NickITGuy probably managed to get it working because after a restart and reinstall, MS Store installs the distro back on C: (instead of D: for some reason). This is a consistent behavior that I have replicated on my machine a few times.

Exactly, the problem is still here. If you move Ubuntu to C:\ and run installation, it works but vhd is in C:\ even you migrate Ubuntu to D:\ via Windows setting. @NickITGuy

PeterWang-dev avatar Oct 16 '23 11:10 PeterWang-dev

Writing this to reopen the issue for @PeterWang-dev @ezhupa99 and @VishalSubramanyam :)

NickITGuy avatar Oct 16 '23 11:10 NickITGuy

I had this same error and finally fixed it after hours of trying to figure out which directory was encrypted or why my admin acct didn't have the right permissions. Hopefully this saves some one some time.

Uninstalling wsl via 'Add or remove programs' and then running Ubuntu again without reinstalling wsl worked for me. It appears I had 2 versions of wsl installed somehow. I kept the one with 'Upgrade' at the end. My guess is upgrading wsl didn't remove the old version, which was causing some conflicts. ymmv

snl60 avatar Mar 09 '24 00:03 snl60

I am still having this issue. Is there a solution yet? I only have one WSL installed. It is the latest version on Windows 11. I used the Windows Store to install Ubuntu 24.01, then, using the Apps form, moved the location to D:. Always get the 80071772 error. I tried the restart options, still the same.

If wsl cannot run the distributions from a drive other than c:, why offer the Move option? And forcing us to run in on C: is very poor, as many people are limited on space on C: but usually have spare space on other drives.

MarkLFT avatar Oct 13 '24 03:10 MarkLFT

I used this: https://craigloewen-msft.github.io/WSLTipsAndTricks/tip/install-different-drive.html

After export I unregistrer the original instance for reuse the name and free the space (I hope it does). Attention the export instruction is wrong, please look at the wsl command help.

Here the fixed:

wsl --export <DistroName> <FileName>
wsl --unregister <DistroName>
wsl --import <DistroName> <InstallLocation> <FileName>

trivalik avatar Oct 17 '24 05:10 trivalik

Since my install was already going to another drive other than "C:", I used the "move" command in the "Apps > Installed Apps" for Ubuntu to repoint it to "C:", then retried "wsl --install" and experienced joy at last.

Honestly, what's with the "C drive" fetish that Microsoft has...lazy coding leftover from the 1980s?

sageikosa avatar Oct 24 '24 21:10 sageikosa

Since my install was already going to another drive other than "C:", I used the "move" command in the "Apps > Installed Apps" for Ubuntu to repoint it to "C:", then retried "wsl --install" and experienced joy at last.

Honestly, what's with the "C drive" fetish that Microsoft has...lazy coding leftover from the 1980s?

this helped me... forgot i set downloads to another drive!

PilotDevo avatar Feb 23 '25 00:02 PilotDevo

Manage to fix the issue by:

  1. Uninstall all the Ubuntu from Settings > Apps > Installed apps
  2. Search and install Ubuntu from Microsoft Store
  3. Move the Ubuntu file location to the C drive by Settings > Apps > Installed apps > Move > select C

Image

  1. Finally, open it from Microsoft Store (an cmd will pop up, wait for it to finish the installation, set up usernameand password)

teyms avatar May 11 '25 12:05 teyms