0

My installation of WSL fails with error 0x800f0831 when I try it either via powershell or via enable optional features.

Windows 1809, build 17763.678

PS C:\WINDOWS\system32> Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
Enable-WindowsOptionalFeature : Enable-WindowsOptionalFeature failed. Error code = 0x800f0831
At line:1 char:1
+ Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows- ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Enable-WindowsOptionalFeature], COMException
    + FullyQualifiedErrorId : Microsoft.Dism.Commands.EnableWindowsOptionalFeatureCommand

I've run the following commands as suggested by some technet articles, but to no avail:

sfc /scannow
dism.exe /Online /Cleanup-image /Scanhealth
dism.exe /Online /Cleanup-image /Restorehealth
sc config wuauserv start=disabled 
net stop bits
net stop appidsvc
net stop cryptsvc
net stop wuauserv
net stop wuauserv
rd /q /s %Systemroot%\SoftwareDistribution
rd /q /s %Systemroot%\system32\catroot2
del %Systemroot%\WindowsUpdate.log
sc config wuauserv start=auto  
wuauclt /resetauthorization /detectnow

Any thoughts on how to move forward with this?

6
  • The best working solution for 3 years is -- reinstall Windows 10 OS.
    – Biswapriyo
    Commented Sep 4, 2019 at 18:51
  • I was hoping to avoid this... Commented Sep 4, 2019 at 19:26
  • Have you tried using the GUI? In Add/Remove Windows Features? Commented Sep 5, 2019 at 15:18
  • @CarlosRafaelRamirez, yes -- same error. Commented Sep 7, 2019 at 16:12
  • 1
    @CarlosRafaelRamirez you're absolutely right. I upgraded to 1903 and then the installation process went through without any issues. Thanks! Commented Sep 10, 2019 at 23:40

1 Answer 1

1

Upgraded Windows 10 from version 1809 to 1903 solved this issue as suggested by CarlosRafaelRamirez in the comments.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .