Instalé Docker y luego inicié Docker. Docker dice que "Docker se está iniciando". Luego, Docker dice "Docker no se pudo iniciar". ¿Por favor, podrías ayudarme?
Detalle del error de Docker:
System.InvalidOperationException: Failed to deploy distro docker-desktop to C:\Users\---\AppData\Local\Docker\wsl\distro: exit code: -1 stdout: The operation could not be started because a required feature is not installed. stderr: at Docker.ApiServices.WSL2.WslShortLivedCommandResult.LogAndThrowIfUnexpectedExitCode(String prefix, ILogger log, Int32 expectedExitCode) in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.ApiServices\WSL2\WslCommand.cs:line 146 at Docker.Engines.WSL2.WSL2Provisioning.<DeployDistroAsync>d__17.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\WSL2\WSL2Provisioning.cs:line 169 --- 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 Docker.Engines.WSL2.WSL2Provisioning.<ProvisionAsync>d__8.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\WSL2\WSL2Provisioning.cs:line 78 --- 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 Docker.Engines.WSL2.LinuxWSL2Engine.<DoStartAsync>d__25.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\WSL2\LinuxWSL2Engine.cs:line 99 --- 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 Docker.ApiServices.StateMachines.TaskExtensions.<WrapAsyncInCancellationException>d__0.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\TaskExtensions.cs:line 29 --- 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 Docker.ApiServices.StateMachines.StartTransition.<DoRunAsync>d__5.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\StartTransition.cs:line 67 --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at Docker.ApiServices.StateMachines.StartTransition.<DoRunAsync>d__5.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\StartTransition.cs:line 92 --- End of stack trace from previous location where exception was thrown --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() at Docker.Engines.Engines.<WaitCurrentTransitionsAsync>d__30.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\Engines.cs:line 358 --- 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 Docker.Engines.Engines.<RestartAsync>d__26.MoveNext() in C:\workspaces\PR-15138\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\Engines.cs:line 250El problema está en WSL , ya que deja de responder y devuelve un error de servicio. Siga los pasos a continuación
1. Uncheck the Windows Subsystem for Linux in Windows Features 2. Restart 3. Turn the feature back on 4. Re-apply the WSL2 update 5. RestartMi solución:
Revisé los requisitos previos para Docker. He aplicado el segundo paso en los requisitos previos. ( Subsistema de Windows para la instalación de Linux con pasos de instalación manual ) Me ha solucionado el error.
Si obtiene un error como este (durante este proceso de instalación):
WslRegisterDistribution failed with error: 0x80370114 Error: 0x80370114 The operation could not be started because a required feature is not installed. (Encontré este error.) Por favor, aplique esto .
These steps are quoted from the "this" named hyperlink above. 1. Open "Windows Security" 2. Open "App & Browser control" 3. Click "Exploit protection settings" at the bottom 4. Switch to "Program settings" tab 5. Locate "C:\WINDOWS\System32\vmcompute.exe" in the list and expand it 6. Click "Edit" 7. Scroll down to "Code flow guard (CFG)" and uncheck "Override system settings" 8. Start vmcompute from powershell "net start vmcompute" 9. Then go back and command wsl --set-default-version 2He arreglado mis problemas así. Buena suerte :)
Lo que solucionó esto para mí fue
Docker no pudo iniciar la actualización de WSL 2 Acabo de hacer esto en powershell
wsl --install -d Ubuntu wsl --update wsl --shutdownPara tu información, la respuesta de jprism funcionó para mí.
Mis problemas eran...
La combinación de la respuesta anterior y la instalación de un nuevo destro funcionó para mí.
Estaba enfrentando el mismo problema en mi escritorio de cooperación de Windows. Desafortunadamente, la mayoría de los cambios en la configuración de Windows no están disponibles para los usuarios y están controlados por el equipo de TI. Lo que hice para que la ventana acoplable se ejecutara es
Sé que esto no es ideal, pero al menos consiguió que docker funcionara.
En mi escenario, necesitaba instalar WSL 2 y mi computadora no lo tenía. Instalarlo hizo que Docker se ejecutara correctamente. Pruebe los pasos a continuación si está instalando Docker por primera vez.
Primero, necesitamos activar WSL desde Windows.
Panel de control -> Programas -> Activar o desactivar funciones de Windows
tienes que comprobar
Luego haga clic en Aceptar
Después de eso, debe habilitar WSL 1 y actualizarlo a WSL 2 ( https://docs.microsoft.com/en-us/windows/wsl/install-win10#manual-installation-steps )
Para instalar WSL 1 que viene integrado, abra PowerShell como administrador y ejecute:
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestartDespués de eso, descargue la actualización WSL 2 de Microsoft. Use debajo de esto:Paquete de actualización del kernel WSL2 Linux para máquinas x64
Después de instalar el paquete anterior, debe configurar WSL 2 como la versión predeterminada.
Abra PowerShell como administrador y ejecute:
wsl --set-default-version 2Ahora reinicie su computadora. Ahora su ventana acoplable debería funcionar.
Tenga en cuenta que para actualizar a WSL 2, debe ejecutar Windows 10.
esto te puede ayudar
& 'C:\Program Files\Docker\Docker\DockerCli.exe' -SwitchDaemonejecuta esto en powershell.