Hyper-V MAC Addresses Duplication or Collison

Networking in Hyper-V is one of the main feature in a virtual infrastructure.

like physical dimension, for each virtual machine ( for each virtual NIC) assigned a MAC address (classic and logic networking).

The question is:

– How these MAC addresses are created ?

– How these MAC addresses are assigned to Virtual machines ?

– How can i avoid MAC addresses collision ?

– Static Mac addresses or Dynamic MAC addresses ?

John Howard -MSFT has written an excellent blog about how MAC addresses are generated and assigned in Hyper-V.

http://blogs.technet.com/b/jhoward/archive/2008/07/15/hyper-v-mac-address-allocation-and-apparent-network-issues-mac-collisions-can-cause.aspx

What can we learn from John:

1- MAC addresses are generated based on the Microsoft IEEE Organizationally Unique Identifier 00-15-5D and the last 16 bytes from the Host IP address: MAC address RANGE = 00-15-5D-(Hex(last 16 bytes of Host IP))+00 to 00-15-5D-(Hex(last 16 bytes of Host IP))+ff

Example:

If my host IP address is 192.168.20.1, the last 16 bytes are 20.1, in hex 14-01 and the MAC address range is [00-15-5D-14-01-00;00-15-5D-14-01-ff]

2- How MAC addresses are assigned: Each new created virtual machine NIC receives the next available MAC address.

Example: (NIC1, 00-15-5D-14-01-00), (NIC1, 00-15-5D-14-01-01), (NIC1, 00-15-5D-14-01-02) …

3– If MAC addresses range is saturated: Virtual machine with virtual NIC will be unable to boot

4- Dynamic or Fixed MAC range:

  • In production environment, it’s recommended to fix your MAC      addresses range. This will simplifie management, tracking, avoid collision.
  • If your environment is large, and it’s possible to have two hosts      with the same last 16 bytes, think to fix your MAC addresses range
  • Try to manage your Virtual environment with SCVMM, it automatically      avoid MAC collision, it has global view of all your hosts.
Advertisements

One thought on “Hyper-V MAC Addresses Duplication or Collison

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s