docker / for-win

Bug reports for Docker Desktop for Windows
https://www.docker.com/products/docker#/windows
1.85k stars 287 forks source link

Error enabling features during Docker Desktop 4.17.0 installation #13288

Open JJC-code opened 1 year ago

JJC-code commented 1 year ago

Description

Today I had faced the issue that my Docker Desktop had stopped. Due to this fact I decided to reinstall it. So I downloaded Docker Desktop 4.17.0 and tried to install it but I encountered an error during the installation of Docker Desktop on my system. The error message I received was "Component CommunityInstaller.EnableFeaturesAction failed" and the error stack trace showed the following:

at CommunityInstaller.InstallWorkflow.<DoHandleD4WPackageAsync>d__30.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at CommunityInstaller.InstallWorkflow.<DoProcessAsync>d__23.MoveNext()

Please help me resolve the issue.

Actual behavior

The installation process of Docker Desktop was interrupted and failed to enable some required features, resulting in the error message above.

Expected behavior

The installation process should complete successfully, and all required features should be enabled without any errors.

Information

Output of & "C:\Program Files\Docker\Docker\resources\com.docker.diagnose.exe" check

I am not able to run it as folder is empty.

Steps to reproduce the behavior

  1. Download the Docker Desktop installation files from the official Docker website.
  2. Run the installation file and follow the prompts.
  3. During the installation process, the error message "Component CommunityInstaller.EnableFeaturesAction failed" is displayed, and the installation fails.

Full install-log-admin

BuildLabName: 19041.1.amd64fre.vb_release.191206-1406
File: C:\ProgramData\DockerDesktop\install-log-admin.txt
CommandLine: "C:\Users\<username>\Downloads\Docker Desktop Installer.exe" 
You can send feedback, including this log file, at https://github.com/docker/for-win/issues
[2023-03-07T19:56:01.739746400Z][ManifestAndExistingInstallationLoader][I] No install path specified, looking for default installation registry key
[2023-03-07T19:56:01.747747000Z][Installer][I] No installation found
[2023-03-07T19:56:01.903875700Z][InstallWorkflow][I] Cancel pending background download
[2023-03-07T19:56:01.905875500Z][BackgroundTransfer][I] Cancel current background transfer job
[2023-03-07T19:56:06.074613100Z][InstallWorkflow][I] Using package: res:DockerDesktop
[2023-03-07T19:56:06.075609100Z][InstallWorkflow][I] Downloading
[2023-03-07T19:56:09.122056900Z][InstallWorkflow][I] Extracting manifest
[2023-03-07T19:56:09.456115000Z][InstallWorkflow][I] Manifest found: version=99724, displayVersion=4.17.0, channelUrl=https://desktop.docker.com/win/main/amd64/appcast.xml
[2023-03-07T19:56:09.456115000Z][InstallWorkflow][I] Checking prerequisites
[2023-03-07T19:56:09.473061800Z][InstallWorkflow][I] Prompting for optional features
[2023-03-07T19:56:10.632672300Z][Installer][W] Failed to track the installer started event
[2023-03-07T19:56:23.350744800Z][InstallWorkflow][I] Selected backend mode: wsl-2
[2023-03-07T19:56:23.350744800Z][InstallWorkflow][I] Unpacking artifacts
[2023-03-07T19:58:06.744435300Z][InstallWorkflow][I] Deploying component CommunityInstaller.CreateGroupAction
[2023-03-07T19:58:18.113351700Z][InstallWorkflow][I] Deploying component CommunityInstaller.AddToGroupAction
[2023-03-07T19:58:29.460413400Z][InstallWorkflow][I] Deploying component CommunityInstaller.EnableFeaturesAction
[2023-03-07T19:58:29.471436200Z][InstallWorkflow-EnableFeaturesAction][I] Required features: VirtualMachinePlatform, Microsoft-Windows-Subsystem-Linux
[2023-03-07T19:58:29.525917700Z][InstallWorkflow][E] Installation failed System.Exception: Component CommunityInstaller.EnableFeaturesAction failed:  ---> System.BadImageFormatException
   at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
   at System.Management.ManagementObjectCollection.ManagementObjectEnumerator.MoveNext()
   at System.Linq.Enumerable.<CastIterator>d__97`1.MoveNext()
   at System.Linq.Enumerable.WhereSelectEnumerableIterator`2.MoveNext()
   at System.Linq.Enumerable.WhereEnumerableIterator`1.MoveNext()
   at System.Linq.Enumerable.Any[TSource](IEnumerable`1 source)
   at CommunityInstaller.EnableFeaturesAction.GetFeaturesToEnable()
   at CommunityInstaller.EnableFeaturesAction.<DoAsync>d__45.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at CommunityInstaller.InstallWorkflow.<DoHandleD4WPackageAsync>d__30.MoveNext()
   --- End of inner exception stack trace ---
   at CommunityInstaller.InstallWorkflow.<DoHandleD4WPackageAsync>d__30.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at CommunityInstaller.InstallWorkflow.<DoProcessAsync>d__23.MoveNext()
[2023-03-07T19:58:29.527914600Z][InstallWorkflow][I] Rollbacking component CommunityInstaller.AddToGroupAction
[2023-03-07T19:58:29.527914600Z][InstallWorkflow][I] Rollbacking component CommunityInstaller.CreateGroupAction
[2023-03-07T19:58:29.527914600Z][InstallWorkflow][I] Rollbacking component CommunityInstaller.UnpackArtifactsStep
[2023-03-07T19:58:29.539976500Z][FileSystem][I] Deleting C:\Program Files\Docker\Docker
[2023-03-07T19:58:29.787240100Z][FileSystem][I] Deleted C:\Program Files\Docker\Docker successfully
[2023-03-07T19:58:29.787240100Z][InstallWorkflow][I] Rollbacking component CommunityInstaller.ExtractManifestStep
[2023-03-07T19:58:29.788240900Z][InstallWorkflow][I] Rollbacking component CommunityInstaller.DownloadStep
JJC-code commented 1 year ago

Will anybody take a look at this issue? Thanks in advance.

qazwsxedckll commented 1 year ago

I think I have found the key to the problem. In an old installer, such as 4.3.0, there is a check box which says Install required Windows components for WSL2. If you uncheck it, everything will be fine but the check box no longer exists in newer installer.

JJC-code commented 1 year ago

@qazwsxedckll wow, you are right. For this very moment I will perceive as TEMPORARY solution which allows me to proceed with my task but for the future... I hope guys from Docker will resolve the issue because I do really want to use the latest version of Docker Desktop. Anyway, thanks for giving this suggestion. Have a nice day!

DeepBhat commented 1 year ago

I'm sorry, where can I get the old installer?

JJC-code commented 1 year ago

@DeepBhat Here: https://docs.docker.com/desktop/release-notes/

On the right side you have listed the released versions.

qazwsxedckll commented 1 year ago

@JJC-code I just find out the error message is not exactly the same. My problem is becacuse of McAfee.

corwestermaniddink commented 1 year ago

This is really a problem for me, because my WSL2 is updated and can't work with older version of Docker Desktop. So the workaround with installing older version is not working for me. :(

JJC-code commented 1 year ago

@corwestermaniddink did you find a way to resolve this issue?