Skip to content
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

An error occurred: Docker.Core.HttpBadResponseException #6807

Open
2 tasks done
ponokwai opened this issue May 20, 2020 · 20 comments
Open
2 tasks done

An error occurred: Docker.Core.HttpBadResponseException #6807

ponokwai opened this issue May 20, 2020 · 20 comments

Comments

@ponokwai
Copy link

ponokwai commented May 20, 2020

  • I have tried with the latest version of my channel (Stable or Edge)
  • I have uploaded Diagnostics
  • Diagnostics ID:

Expected behavior

Starting Docker Desktop for Windows, I attempted to run a linux container but it fails to start-up

Actual behavior

I get "An error occurred. See exception below:

Docker.Core.HttpBadResponseException:
Unhandled exception: Operation failed with result 32775
at Docker.Core.Logging.ClientExceptionInterceptor.d__0.MoveNext() in C:\workspaces\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.Core\Logging\ClientExceptionInterceptor.cs:line 17
--- 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.Core.Logging.LoggingMessageHandler.d__4.MoveNext() in C:\workspaces\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.Core\Logging\LoggingMessageHandler.cs:line 37
--- 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 System.Net.Http.HttpClient.d__58.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 Docker.Core.HttpClientExtensions.d__11.MoveNext() in C:\workspaces\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.Core\HttpClientExtensions.cs:line 22 --- 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.Core.BackendAPI.BackendAPIClient.<StartHyperVVMAsync>d__11.MoveNext() in C:\workspaces\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.Core\BackendAPI\BackendAPIClient.cs:line 102 --- 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.LinuxHyperVEngine.<DoStartAsync>d__12.MoveNext() in C:\workspaces\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.Desktop\Engines\LinuxHyperVEngine.cs:line 60 --- 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\stable-2.3.x\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\stable-2.3.x\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\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.ApiServices\StateMachines\StartTransition.cs:line 36 Original stacktrace: at Docker.Backend.HyperVInfrastructure.<HandleMaybeAsyncJob>d__37.MoveNext() in C:\workspaces\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.Backend\HyperV\HyperVInfrastructure.cs:line 744 --- 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.Backend.HyperVInfrastructure.<StartVMAsync>d__29.MoveNext() in C:\workspaces\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.Backend\HyperV\HyperVInfrastructure.cs:line 588 --- 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.Backend.HyperV.<StartAsync>d__7.MoveNext() in C:\workspaces\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.Backend\HyperV\HyperV.cs:line 101 --- 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.Backend.HttpAPI.HyperVAPIController.<StartAsync>d__8.MoveNext() in C:\workspaces\stable-2.3.x\src\github.com\docker\pinata\win\src\Docker.Backend\HttpAPI\HyperVAPIController.cs:line 44 --- 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 System.Threading.Tasks.TaskHelpersExtensions.<CastToObject>d__11.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 System.Web.Http.Controllers.ApiControllerActionInvoker.d__1.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 System.Web.Http.Controllers.ActionFilterResult.d__5.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 System.Web.Http.Dispatcher.HttpControllerDispatcher.d__15.MoveNext()

Information

Version: 2.3.0.2 (45183)
Channel: stable
Sha1: e9b671cd3cb844cb63ad6fd7c79a4d15424233c4
Started on: 2020/05/20 12:31:21.748
Resources: C:\Program Files\Docker\Docker\resources
OS: Windows 10 Enterprise
Edition: Enterprise
Id: 1703
Build: 15063

  • Windows Version:Windows 10 Enterprise; Build 15063
  • Docker Desktop Version: 2.3.0.2 (45183)
  • Are you running inside a virtualized Windows e.g. on a cloud server or on a mac VM: No. i am running on windows desktop

Steps to reproduce the behavior

  1. Start up docker desktop defaulting to linux container

log.txt

@adiguno
Copy link

adiguno commented Jun 5, 2020

I had the same issue, when trying to 'reset to factory defaults'

@StruninIhor
Copy link

StruninIhor commented Jun 22, 2020

The same issue. Attached log file
log.txt

@marivaldojr
Copy link

I had that issue when trying to 'reset to factory defaults'. I notice that on Hyper-V Manager the DockerDesktopVM was in state "Paused-Critical", then I turn off and on again. After I could start the Docker Desktop.

@richardgragasin
Copy link

any updates? im having similar issues on my cloud vm.

@ankurgupta15
Copy link

@ponokwai did you get solutions for the above error because i am getting the same error and not able to resolve it yet.

@ponokwai
Copy link
Author

@ankurgupta15 I never did. I gave up on running docker locally. I just deploy to Azure and manage it there

@grzegorzsobocinski2397
Copy link

grzegorzsobocinski2397 commented Jul 28, 2020

I had the same issue after Docker Desktop update (2.3.0.4 46911). Going into Hyper-V Manager and restarting the service helped.

@ravigupta84
Copy link

Thanks @grzegorzsobocinski2397 It worked for me. I opened The Hyper-V Manager then stop and start the service.

@docker-robott
Copy link
Collaborator

Issues go stale after 90 days of inactivity.
Mark the issue as fresh with /remove-lifecycle stale comment.
Stale issues will be closed after an additional 30 days of inactivity.

Prevent issues from auto-closing with an /lifecycle frozen comment.

If this issue is safe to close now please do so.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows.
/lifecycle stale

@StruninIhor
Copy link

/remove-lifecycle stale

@docker-robott
Copy link
Collaborator

Issues go stale after 90 days of inactivity.
Mark the issue as fresh with /remove-lifecycle stale comment.
Stale issues will be closed after an additional 30 days of inactivity.

Prevent issues from auto-closing with an /lifecycle frozen comment.

If this issue is safe to close now please do so.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows.
/lifecycle stale

@StruninIhor
Copy link

/lifecycle frozen

@StruninIhor
Copy link

/remove-lifecycle stale

@bzaks1424
Copy link

/remove-lifecycle stale

@bzaks1424
Copy link

I'm getting the same exception. on boot
Windows Version 10.0.19043 Build 19043

Faulting application name: Docker Desktop.exe, version: 4.1.1.0, time stamp: 0xb4d6f9e7
Faulting module name: KERNELBASE.dll, version: 10.0.19041.1202, time stamp: 0xc9db1934
Exception code: 0xe0434352
Fault offset: 0x0000000000034f99
Faulting process id: 0x3118
Faulting application start time: 0x01d7c1e2516b20ad
Faulting application path: C:\Program Files\Docker\Docker\Docker Desktop.exe
Faulting module path: C:\WINDOWS\System32\KERNELBASE.dll
Report Id: 1e38336a-94da-492c-ab1a-7e38ffd4f668
Faulting package full name: 
Faulting package-relative application ID: 
Application: Docker Desktop.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.UnauthorizedAccessException

Exception Info: Docker.Core.HttpBadResponseException
   at Docker.Core.Logging.HttpClientExceptionInterceptor+<InterceptResponseAsync>d__0.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(System.Threading.Tasks.Task)
   at Docker.Core.IPC.Client+<SendAsync>d__5.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(System.Threading.Tasks.Task)
   at System.Net.Http.HttpClient+<FinishSendAsyncBuffered>d__58.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(System.Threading.Tasks.Task)
   at Docker.Core.BackendAPI.ServiceAPIClient+<UpdateHostsAsync>d__5.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(System.Threading.Tasks.Task)
   at Docker.Core.TaskExtension+<Forget>d__0.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
   at System.Threading.ThreadPoolWorkQueue.Dispatch()

@oDn
Copy link

oDn commented Feb 25, 2022

I've been having the exact same issue as @bzaks1424 for months now.

Docker Desktop is not configured to start automatically when I log in. When I run Docker Desktop 4.5.1 (74721) the first time it crashed but succeeds when starting it again a couple of minutes later. In both cases Windows 10 21H2 (19044.1566) is fully booted up and WSL2 is running without any issues.

@Reyhn3
Copy link

Reyhn3 commented Sep 21, 2022

I too had the exact same problem as @bzaks1424.
I solved it by:

  1. Uninstalling Docker Desktop and restarted.
  2. Uninstalling the Windows features "Windows Subsystem for Linux" and "Hyper-V" (don't know if Hyper-V needs to be uninstalled, though) and restarted.
  3. Reinstalled "Windows Subsystem for Linux" and restarted.
  4. Reinstalled Ubuntu as WSL and restarted.
  5. Reinstalled the latest Docker Desktop and restarted.

When I installed Docker Desktop again, I ran from PowerShell:

Start-Process 'Docker Desktop Installer.exe' -Wait -ArgumentList ("install","--accept-license","backend=wsl-2")

This worked for me.

@1zyik
Copy link

1zyik commented Jan 31, 2023

I tried out MircoK8s and it messed with the default VM giving the same error.

My solution didn't require a restart.

Open CMD with admin privileges and paste

sc config LxssManager start=auto

This reverts the default VM back to wsl2. Hope it helps.

@anthonrodgrs01
Copy link

anthonrodgrs01 commented Feb 7, 2023

This error occured to me when I made changes in the wslconfig file, I copied and pasted all the stuff from the documentation to my wslconfig file, but all I needed was to limit docker desktop to 4gb of ram and processors

All you should try doing is delete all the lines except the ram and no. of process from wslconfig file:
it should look like this:

.wslconfig file-:

[wsl2]
memory=4GB
processors=2

@Jan-Snoeijs
Copy link

I tried out MircoK8s and it messed with the default VM giving the same error.

My solution didn't require a restart.

Open CMD with admin privileges and paste

sc config LxssManager start=auto

This reverts the default VM back to wsl2. Hope it helps.

This doesn't work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests