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

Docker port mapping issue (18.09) #3350

Open
tyger opened this issue Nov 19, 2018 · 41 comments

Comments

@tyger
Copy link

commented Nov 19, 2018

  • I have tried with the latest version of my channel (Stable or Edge)
  • I have uploaded Diagnostics
  • Diagnostics ID:DC2A0FF4-74B0-46AC-ADA6-F952741DC11C/20181119184237

Expected behavior

Actual behavior

Information

Problem with Docker on Mac after updating to Version 2.0.0.0-mac78 (28905) (engine v 18.09). Port mapping from host to container doesn't work.
The issue reveal itself right after update.
Restarting computer helps only for one container run.

  • macOS Version: 10.14.1 (18B75) Mojave

Diagnostic logs

Diagnose succeded

Steps to reproduce the behavior

to reproduce:

docker run -p 127.0.0.1:8000:8000 -it python bash

then on container:

python2.7 -m SimpleHTTPServer 8000

on host:

curl http://127.0.0.1:8000

^^^ this command wont work, though it is running successfully from the container itself.

@tyger

This comment has been minimized.

Copy link
Author

commented Nov 20, 2018

Update: After restart Docker using restart command in Desktop app it works again.
Very flaky behaviour, I will keep an eye on it.

@patoi

This comment has been minimized.

Copy link

commented Nov 20, 2018

Reproducable.

MacOS Mojave 10.14.1 (18B75)
Docker Desktop: Version 2.0.0.0-mac78 (28905)

curl --connect-timeout 10 --max-time 12 http://127.0.0.1:8000

@joebui

This comment has been minimized.

Copy link

commented Nov 20, 2018

The same for me too.

@Ky6uk

This comment has been minimized.

Copy link

commented Nov 20, 2018

Also upgraded to 2.0 and got freezing ports after some time. Only restart helps.

@patoi

This comment has been minimized.

Copy link

commented Nov 20, 2018

Try out a MacOS restart, maybe help.

@Ky6uk

This comment has been minimized.

Copy link

commented Nov 20, 2018

Try out a MacOS restart, maybe help.

Only restart helps.

It still happens again after some time and requires restart of docker for mac.

@tyger

This comment has been minimized.

Copy link
Author

commented Nov 20, 2018

It might be better (and faster) to restart Docker for mac itself - helps me.

@Ky6uk Ky6uk referenced this issue Nov 21, 2018
1 of 2 tasks complete
@Ky6uk

This comment has been minimized.

Copy link

commented Nov 21, 2018

Reverted to previous version from here: https://docs.docker.com/docker-for-mac/release-notes/
That's working fine.

@aidanlister

This comment has been minimized.

Copy link

commented Nov 22, 2018

Yes this auto-update has destroyed my setup - I can't access any of my containers via HTTP

@listenfree

This comment has been minimized.

Copy link

commented Nov 28, 2018

The same for me too.
mac 10.14.1,

It still happens again after some time and requires restart of docker for mac.

@tezequiel

This comment has been minimized.

Copy link

commented Nov 28, 2018

Same here.

@DavidNavalho

This comment has been minimized.

Copy link

commented Nov 29, 2018

Same happening to me. I'll revert to a previous version for now.

edit: Confirming that going down to a pre-2.0 version also fixed the problem for me.

@berliner

This comment has been minimized.

Copy link

commented Dec 4, 2018

I can confirm that downgrading to the latest pre-2.0 release fixes the problems for me.

@mikeharty

This comment has been minimized.

Copy link

commented Dec 5, 2018

Link to prior release without the bug: https://download.docker.com/mac/stable/26764/Docker.dmg

@jfmmm

This comment has been minimized.

Copy link

commented Feb 8, 2019

Same thing here, reverted to the version posted by @mikeharty and the problem went away.

@Ky6uk

This comment has been minimized.

Copy link

commented Feb 8, 2019

Is it safe to upgrade to latest version? Just not sure this is actual issue tracker because don't see any devs activity here. After the buggy version I got some newest updates but not sure it was fixed.

@jfmmm

This comment has been minimized.

Copy link

commented Feb 8, 2019

No don't I just spent the day debugging this issue with the current latest version and going back to an old version fixed it.

@andrix

This comment has been minimized.

Copy link

commented Feb 28, 2019

Hey @jfmmm what version fixed the issue for you? I'm having this same issue.

@Ky6uk

This comment has been minimized.

Copy link

commented Feb 28, 2019

@andrix 18.06.1-ce-mac73 (26764) is the latest version without the bug.

Can be found here: https://docs.docker.com/docker-for-mac/release-notes/
Direct link to dmg file is here.

@gitricko

This comment has been minimized.

Copy link

commented Mar 4, 2019

This issue still not fix ? I was having this issue for weeks... i tot my internal IT block docker or something wrong with my dockefile...

@andrix

This comment has been minimized.

Copy link

commented Mar 5, 2019

@gitricko I still have the issue. I downgraded to the version pointed by @Ky6uk and now everything is working like a charm. However, it must be imperative to fix it for the next version, as it's extremely annoying.

@abort

This comment has been minimized.

Copy link

commented Mar 8, 2019

I experience the same issue since upgrading Docker on Mac OS X 10.14.1 (18B75). Version of Docker that contains this issue for me: 18.09.2, build 6247962.

@cloojure

This comment has been minimized.

Copy link

commented Mar 12, 2019

Same result for me (MacBook Pro 2018, macOS High Sierra 10.13.6). Intermittent failure (mostly failure, occasionally it worked after a reboot of computer and/or Docker). Masked problem when I completely deleted and reinstalled Docker, then began failing again. I was on Docker version 18.09.2. Problem solved as @Ky6uk suggested:

  • Quit Docker Desktop (whale icon at top right of screen)
  • Uninstall Docker from command line:
    /Applications/Docker.app/Contents/MacOS/Docker --uninstall
  • Download and install Docker Docker Community Edition 18.06.1-ce-mac73 2018-08-29 from here
  • Be sure to replace previous version of Docker when installing the downgrade version.
@201721171057

This comment has been minimized.

Copy link

commented May 5, 2019

Same, Intermittent failure .Normal after restart, plz fix it .

@victorbr

This comment has been minimized.

Copy link

commented May 13, 2019

Same here - Mojave 10.14.4, Docker 2.0.0.3. After docker restart ports respond for some time, after several hours they stop. Restarting docker-compose doesn't help, only that of the server does.

@CafeLungo

This comment has been minimized.

Copy link

commented May 15, 2019

Same problem here. Mojave 10.14.4, Docker 2.0.0.3 (31259), docker engine 18.09.2. Highly frustrating. restarting docker (via whale icon in menu bar) seems to help... for awhile.

@steve-thousand

This comment has been minimized.

Copy link

commented May 21, 2019

I also experience this problem, Docker version 18.09.2, build 6247962 on Mojave 10.14.4. Spent about a day troubleshooting network issues with my container, simple restart of laptop fixed it.

@chenxiaolei

This comment has been minimized.

Copy link

commented May 23, 2019

Same+, plz fix it .

@mikegreiling

This comment has been minimized.

Copy link

commented May 23, 2019

This issue is driving me crazy. Seems to me like a pretty serious bug. Is there any way to signal boost this a bit more?

To get around this, I'm forced to run an old version (18.06.1), which is now potentially dangerous due to the security patches it is missing (CVE-2019-5736 et al).

@rnsc

This comment has been minimized.

Copy link

commented Jun 9, 2019

I have the same issue. Restarting Docker or the Mac doesn't help.
I can never access exposed ports.
Will try the 18.06.1. Otherwise, I'll revert to managing it myself in a VM.

(side note, I was running edge releases)

@ShantanuNair

This comment has been minimized.

Copy link

commented Jun 12, 2019

Also having this issue, chalked it off to a faulty image or too much disk IO causing it to crash (I have high random read-writes in my use case), but docker's been way way more stable after trying out the older release. Can't believe the difference.

@ethanentW

This comment has been minimized.

Copy link

commented Jun 18, 2019

Having the same issue here as well. Docker Desktop 31259 (2.0.0.3), MacBook Pro 2018, MacOS Mojave.

Restarting Docker Desktop resolved the issue, at least temporarily.

@steinwelberg

This comment has been minimized.

Copy link

commented Jun 27, 2019

I'm experiencing the same issue with exactly the same specs as @ethanentW: Docker Desktop 31259 (2.0.0.3), MacBook Pro 2018, MacOS Mojave.

Restarting whole Docker Desktop only temporarily fixes the issue. Restarting the Docker container that I can't connect to does not resolve the issue.

It's starting to get really annoying and downgrading to an older version is not an option for me due to security issues in the older version.

@szalair

This comment has been minimized.

Copy link

commented Jul 4, 2019

Same issue here with same specs (Docker Desktop 2.0.0.3 31259, macOS Mojave)
Restarting Docker Desktop solves the problem for a couple of minutes.

I don't want to change to an older version, but it seems like this is the only solution now. :/

@gtarnaras

This comment has been minimized.

Copy link

commented Jul 9, 2019

Same issue with MacBook Pro 2017 (Mojave) - Version 2.0.0.3 (31259). Had to downgrade.

@lucidtech

This comment has been minimized.

Copy link

commented Jul 10, 2019

DISCLAIMER - not at all a Docker expert.
And I don't want to jinx this... but: Had the 2.x problem. downgraded as per advice above - all OK. Later, during a rebuild of my app I hit a different bug (compose related) that required me to upgrade again. Before doing that I wiped all images, completely removed docker, installed 2.x, wiped my local application repo - re-cloned, re-built and pulled all new images. So far running OK for a week. Before was crashing every 20/30 minutes. Completely trashing and and then rebuilding everything under 2.x would be the only docker related thing in that process. FWIW other team members on same hw/OS do not have this problem. ¯_(ツ)_/¯

@Ky6uk

This comment has been minimized.

Copy link

commented Aug 5, 2019

It looks to be fixed in v2.1.0.0 (36874). Can anyone also confirm that?

@maljukan

This comment has been minimized.

Copy link

commented Aug 6, 2019

@Ky6uk Confirming! It works with v2.1.0.0 (36874)

@joebui

This comment has been minimized.

Copy link

commented Aug 8, 2019

Yep it is fixed

@luffyke

This comment has been minimized.

Copy link

commented Aug 9, 2019

I think this issue can be closed now.

@paddie

This comment has been minimized.

Copy link

commented Sep 16, 2019

Hmmm... I am seeing the same issue on version 2.1.0.2 (37877) on Mac OSX Catalina (19A558d)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
You can’t perform that action at this time.