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

MAC Address changes after container restart even with ip specified. #2399

Closed
Umer-Javaid opened this issue Aug 8, 2018 · 2 comments
Closed
Assignees

Comments

@Umer-Javaid
Copy link

I have created a microsoft/dotnet-framework:4.7.2-runtime container using docker for windows. Each time the container restarts a new MAC address is assigned to it even though I have explicitly specified IP-Address at the creation.

Expected behavior

MAC address should not change after container restart when IP-Address is specified explicitly.

Actual behavior

MAC address changes after each restart.

PS C:\> docker create --name=testContainer --net=transNet1 --ip=10.2.0.251 microsoft/dotnet-framework:4.7.2-runtime
e041405ce6ec21cb28e87923d8ca919919f1f38b9246332fbabaf32be25ba4ab
PS C:\> docker start testContainer
testContainer
PS C:\> docker inspect --format='{{range .NetworkSettings.Networks}}{{println .MacAddress}}{{end}}' testContainer
00:15:5d:71:18:58

PS C:\> docker stop testContainer
testContainer
PS C:\> docker start testContainer
testContainer
PS C:\> docker inspect --format='{{range .NetworkSettings.Networks}}{{println .MacAddress}}{{end}}' testContainer
00:15:5d:71:1e:f4

Information

  • Windows Version:
  Platform ServicePack Version      VersionString
  -------- ----------- -------      -------------
  Win32NT             10.0.14393.0 Microsoft Windows NT 10.0.14393.0
  • Docker for Windows Version:
  Client:
   Version:      18.03.1-ee-2
   API version:  1.37
   Go version:   go1.10.2
   Git commit:   ebbcd7e
   Built:        Tue Jul 10 21:32:32 2018
   OS/Arch:      windows/amd64
   Experimental: false
  
  Server:
   Engine:
   Version:      18.03.1-ee-2
   API version:  1.37 (minimum version 1.24)
   Go version:   go1.10.2
   Git commit:   ebbcd7e
   Built:        Tue Jul 10 21:49:06 2018
   OS/Arch:      windows/amd64
   Experimental: false

Steps to reproduce the behavior

  1. docker pull microsoft/dotnet-framework:4.7.2-runtime
  2. Create a container with explicit IP-Address specified
  3. Start the container
  4. Inspect the container to see MAC-Address
  5. Stop the container and then start again
  6. Inspect the container again to see MAC-Address
@ebriney
Copy link
Member

ebriney commented Aug 16, 2018

Hi @Umer-Javaid , it's specific to Windows daemon, can you fill an issue in https://github.com/moby/moby/issues please.

@docker-robott
Copy link
Collaborator

Closed issues are locked after 30 days of inactivity.
This helps our team focus on active issues.

If you have found a problem that seems similar to this, please open a new issue.

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

@docker docker locked and limited conversation to collaborators Jun 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants