docker / for-mac

Bug reports for Docker Desktop for Mac
https://www.docker.com/products/docker#/mac
2.42k stars 116 forks source link

macvlan driver doesn't work in MacOS #3926

Open ajoldham opened 4 years ago

ajoldham commented 4 years ago

Continuation of : https://github.com/docker/for-mac/issues/3447 as it was auto-closed. This isn't fixed in the latest Docker Edge 19.03.2 with MacOS 10.14.6.


$ ifconfig en9 en9: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500 options=4 ether 58:ef:68:7d:06:05 inet6 fe80::1028:71b1:5694:b4bf%en9 prefixlen 64 secured scopeid 0x12 inet 10.42.34.91 netmask 0xfffffc00 broadcast 10.42.35.255 nd6 options=201<PERFORMNUD,DAD> media: autoselect (1000baseT ) status: active $ docker network create -d macvlan --subnet=10.42.32.0/22 --gateway=10.42.32.1 -o parent=en9 pub_net Error response from daemon: invalid subinterface vlan name en9, example formatting is eth0.10

maxpavlov commented 4 years ago

+1

If you specify eth0 in parent, it will get created, but won't work =)

ViperRNMC commented 4 years ago

same problem here with en0

adocehic commented 4 years ago

I've been losing my mind in various attempts in getting macvlan working, and this is why. Blindly using eth0 instead of the actual en0 interface appears to work when it shouldn't.

obmuc commented 4 years ago

Any workarounds for this?

HunterDG commented 4 years ago

following

amaisano commented 4 years ago

Still not working in Docker 2.2.0.4.

adocehic commented 4 years ago

I ended up buying a Dell R620. It was easier to actually set up a whole linux server to really take advantage of Docker than it was to waste time working around this bug or waiting for it to get fixed.

It's rather annoying as this is a very clear and reproducible bug that on the surface appears to be simple.

On Jan 7, 2020, at 2:19 PM, obmuc notifications@github.com wrote:

Any workarounds for this?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/docker/for-mac/issues/3926?email_source=notifications&email_token=ABUXDOJHGHKJO523LWEJ7NLQ4T5VPA5CNFSM4I2V6M62YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEIKPQFA#issuecomment-571799572, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABUXDOKNKYUF7D7JAQ6RSP3Q4T5VPANCNFSM4I2V6M6Q.

amaisano commented 4 years ago

@adocehic are you saying typing eth0 actually works with en0 (even though it shouldn't)?

mastix commented 4 years ago

I can confirm that it's still not working with Docker Desktop 2.2.0.5 & Docker 19.03.8.

rfoltz commented 4 years ago

@mikeparker I think we would really wish for this to be implemented for Mac OS, this is stopping me from using Docker in my home lab.

dciancu commented 3 years ago

Still not working with Docker Desktop 2.3.0.4 & macOS 10.15.6

dinhkk commented 3 years ago
docker network create -d macvlan \
  --subnet=192.168.2.0/24 \
  --gateway=192.168.2.1 \
  -o parent=eth0 \
  my-macvlan-net

I have tested above command on my macOSX 10.15.6. This seems to be a lie. It works. But ifconfig does not show eth0, but en0

ajoldham commented 3 years ago

Thanks. It seems to configure, but when I run a container using that network, I can't seem to ping or communicate out of it.

ctyrider commented 3 years ago

Yes, macOS Docker allows configuring macvlan bound to parent eth0 interface (which doesn't exist on the host). Multiple Containers placed in that macvlan can communicate with each out, but not out of the host.. which is what I would expect when binding a network to a phony adapter.

Any thoughts on when we can actually see this fixed? Disappointing that core Docker feature like this doesn't work on macOS.

Alexivia commented 3 years ago

This would be such a useful feature... I can confirm that on my Mac I can't configure a macvlan network interface with Docker version 19.03.13, build 4484c46d9d.

michaelprescott commented 3 years ago

It's looking like this bug might not be getting fixed for a while. What are other options? How else can we configure and launch a set of containers via 'docker-compose up' to make them accessible to other machines on a LAN?

michaelprescott commented 3 years ago

And, same failure for ipvlan. I wish Docker docs made this bold and clear that both are broken on macOS. I learned a lot trying to solve it, but ultimately it was a waste of time for me.

It takes a little longer to setup what I need with VMs and VMWare Fusion, but it works. Interestingly, in Fusion it's categorized under the "Bridged Networking" configuration. Noting that, I circled back to Docker and tried setting up a bridged network. Still no luck. The containers still don't appear on the LAN. Anyhow, if you are free to move to a linux development machine where macvlan and ipvlan work, here are some really great articles about macvlan https://hicu.be/tag/macvlan

mminks commented 3 years ago

Confirmed.

onlinefchen commented 3 years ago

Confirmed.

waiting

docker-robott commented 3 years ago

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

barinet commented 3 years ago

/lifecycle frozen

barinet commented 3 years ago

/remove-lifecycle stale

Rubberduck1971 commented 3 years ago

/remove-lifecycle stale

Rubberduck1971 commented 3 years ago

/lifecycle frozen

fdevans commented 2 years ago

+1

pkishino commented 2 years ago

+1

thueske commented 2 years ago

+1

arrrgi commented 2 years ago

+1

joaoceron commented 2 years ago

+1

Edisonliiii commented 2 years ago

+1

Abirdcfly commented 2 years ago

+1

owalid commented 2 years ago

+1

junoteam commented 2 years ago

+1

jamauai commented 2 years ago

+1

bournex commented 2 years ago

+1

jkneer commented 2 years ago

+1

pablosed commented 2 years ago

+1

francisgro commented 2 years ago

+1

pgasiorowski-es commented 2 years ago

+1

mjanson commented 2 years ago

+1

michaelprescott commented 2 years ago

+1

conotto commented 2 years ago

+1

rcmarini commented 2 years ago

+1

dineshkumar-vi commented 2 years ago

+1

oshadhavg commented 2 years ago

Issue is till in Docker version 20.10.11, build dea9396

oshadhavg commented 2 years ago

Issue is till in Docker version 20.10.11, build dea9396

Not working in Docker version 20.10.12, build e91ed57 as well.

oshadhavg commented 2 years ago

Is there a workaround for this? This docker macvlan is not working on either MACOS or Windows. This is really a frustrating situation. Please resolve this!

rcmarini commented 2 years ago

You can try creating a reverse proxy on the host machine, redirecting a local port to the remote service you need to call, and calling the host port through the container. Resolves for some types of services.

phonezhou commented 2 years ago

s there a workaround for this? This docker macvlan is not working on either MACOS or Windows. This is really a frustrating situation. Please resolve this!

wojciechowskidawid commented 2 years ago

+1