Sometimes it can be necessary to configure a static MAC address in a VM. A typical issue during P2V is an application that has its licensing based on the MAC address.
VMware has defined that VirtualCenter does not use the following range: 00:50:56:00:00:00 to 00:50:56:3F:FF:FF where 00:50:56 is the OUI.
The steps:
- Power off & remove the server from the VirtualCenter inventory. This is a necessary step, because VC will overwrite your settings during Power On!
- Edit the .vmx file and locate the following generated MAC address:
Ethernet0.addressType =
and
Ethernet0.generatedAddress = - Change the value for ethernet0.addressType from “vpx” to “static”
- Change ethernet0.GeneratedAddress to ethernet0.Address
- Change the current MAC to a MAC address in the following range:
00:50:56:00:00:00-00:50:56:3F:FF:FF - In VirtualCenter, select an ESX host and go to storage
- Browse the data store & locate your VM
- Right-click on the .vmx file, and select Add to inventory
- Power On the server. Issue the command ipconfig /all and locate the VMware NIC. Your manually assigned MAC address should be there.
I know you can set your MAC address inside Windows, but I would avoid this.
4 opmerkingen:
You are correct that VirtualCenter will overwrite your settings.
However, if you start the VM from the command line on the ESX host, VirtualCenter will not overwrite the .vmx settings.
Also, you can force this setting from inside VirtualCenter.
With the VM powered off, choose Edit Settings, choose Options, choose Advanced, choose Configuration Parameters, then Add Row, you can enter the ethernet0.addresstype and ethernet0.address values.
Once added, they will disappear the next time you look at the Configuration Parameters window, but the changes will be there.
Good post though.
Thanks,
Jase
http://www.jasemccarty.com/
Or you could use the tool I wrote to automate this. Our environment requires a fixed MAC address for every server, and I got sick of doing them manually.
It is currently hosted over at www.run-virtual.com - you can get it here:
http://www.run-virtual.com/?page_id=173
I do agree with Rob: when you have to do it x-times, use his VirtualMACTool. Tried, tested & working :)
Changing the physical address in windows is fine.
Een reactie posten