• Contact
  • Homelab
Dimitris Tonias
  • Management
  • Monitoring
  • Cloud
  • Virtualization
  • Networking
  • Productivity
No Result
View All Result
  • Management
  • Monitoring
  • Cloud
  • Virtualization
  • Networking
  • Productivity
No Result
View All Result
Dimitris Tonias
No Result
View All Result

Configure Dynamic MAC addresses on a Hyper-V 2016 host

Dimitris Tonias by Dimitris Tonias
February 17, 2018 - Updated on April 21, 2024
in Virtualization
Reading Time: 2 mins read
A A
0
Share on FacebookShare on Twitter

When you create a new VM on Hyper-V, which means that it will have one or more network adapters, a MAC address for each adapter is dynamically assigned at the start of the VM. This is the default behavior.

The source of the MAC addresses comes from a default MAC Address Pool of Hyper-V that you can see through the Virtual Switch Manager settings, specifically in the MAC Address Range section, as shown in the figure below.

Configure dynamic MAC addresses on a Hyper-V 2016 host

According to Microsoft documentation, the number of dynamic MAC addresses that a Hyper-V host can produce is 256. Suppose we have the MAC address aa-bb-cc-dd-ee-ff.

  • The first 3 octets (aa-bb-cc) refer to a Microsoft’s Unique Identifier that is used in all Hyper-V hosts (00: 15: 5D).
  • The next 2 octets (dd-ee) are generated by the last two octets of the IP address that was first set up on the Hyper-V server.
  • The last octet (ff) is generated from the range 0x0 – 0xFF.

Why do you have to know all this? Let’s look at it with an example.

Suppose we just installed a new Hyper-V host that took the IP address 10.10.10.10 from a DHCP server and then we set a static IP address. The dynamic MAC addresses it generates, however, depend on the first dynamic IP address it took from the DHCP Server.

This means that if we add another Hyper-V host to the infrastructure and it gets the same IP 10.10.10.10 from the DHCP Server that had the first host, then the dynamic MAC addresses it generates will be the same as the first host.

To avoid such cases, Microsoft makes it possible to change the range of dynamic MAC addresses generated by a Hyper-V host. Also, this way you can increase the limit of 256 addresses by changing the appropriate octets. This can be done using both from the GUI and from PowerShell.

By opening the Virtual Switch Manager settings and specifically in the MAC Address Range section, you can specify the range of these addresses. As the information in the box says, changing the range does not automatically change the MAC address of the already created network adapters. To get the new address, you’ll need to remove them and create them again.

For those who prefer PowerShell, the cmdlet we use in this case is Set-VMHost as shown below.

Set-VMHost -MacAddressMinimum 00155DEC6300 -MacAddressMaximum 00155DEC63FF

Set-VMHost -MacAddressMinimum 00155DEC6300 -MacAddressMaximum 00155DEC63FF

To see the range of dynamic MAC addresses, use the following command.

Get-VMHost | Select ComputerName, MacAddressMinimum, MacAddressMaximum | ft

Get-VMHost | Select ComputerName, MacAddressMinimum, MacAddressMaximum | ft

An important point to note if you are going to change the Minimum and Maximum values ​​of dynamic MAC addresses is not to include in the range and static MAC addresses that you might use in some VMs.

Tags: Hyper-VMAC AddressVirtual MachineWindows Server 2016
ShareTweetPin
Previous Post

Set static MAC address on a Hyper-V Server 2016 VM

Next Post

Configure DHCP Server 2016 Filters

Related Posts

Altaro VM Backup Review
Virtualization

Altaro VM Backup Review

Set static MAC address on a Hyper-V Server 2016 VM
Virtualization

Set static MAC address on a Hyper-V Server 2016 VM

View MAC address of Hyper-V Server VMs
Virtualization

View MAC address of Hyper-V Server VMs

Install Hyper-V Server 2016 as a Standalone Hypervisor
Virtualization

Install Hyper-V Server 2016 as a Standalone Hypervisor

Find which virtual machines use Dynamic Memory on Hyper-V
Virtualization

Find which virtual machines use Dynamic Memory on Hyper-V

How to build a Virtual Lab with VMware Workstation
Virtualization

How to build a Virtual Lab with VMware Workstation

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

No Result
View All Result
Zabbix server: More than 75% used in the trends cache
Monitoring

Zabbix server: More than 75% used in the trends cache

In Zabbix, "trends" are a type of data storage representing aggregated historical data. Zabbix monitors and collects a vast amount...

Read moreDetails
Check word count on Google Docs

Check word count on Google Docs

Zabbix server: More than 75% used in the configuration cache

Zabbix server: More than 75% used in the configuration cache

Approve updates in WSUS 2016

Approve updates in WSUS 2016

Configure Group Policy to deploy updates using WSUS 2016

Configure Group Policy to deploy updates using WSUS 2016

Configure computer groups in WSUS 2016

Configure computer groups in WSUS 2016

The initial configuration of WSUS 2016

The initial configuration of WSUS 2016

Get more stuff

Subscribe to our mailing list and get interesting stuff and updates to your email inbox.

Thank you for subscribing.

Something went wrong.

we respect your privacy and take protecting it seriously

  • Contact
  • Homelab

© 2024 Dimitris Tonias

No Result
View All Result
  • About
  • Contact
  • Free Tools
  • Home
  • Homelab

© 2024 Dimitris Tonias

This website uses cookies. By continuing to use this website you are giving consent to cookies being used.