Powering on a virtual machine after migrating to VMware vCenter Server 5.x fails with error: Invalid MAC address specified
search cancel

Powering on a virtual machine after migrating to VMware vCenter Server 5.x fails with error: Invalid MAC address specified

book

Article ID: 328003

calendar_today

Updated On:

Products

VMware

Issue/Introduction

Symptoms:
  • A virtual machine cannot be powered on after updating VMware vCenter Server or the ESXi host (from any version up to and including 5.1).
  • vCenter Server is running version 5.1.
  • ESXi is running version 5.1.
  • Attempting to power on a virtual machine fails with this error:

    An error was received from the ESX host while powering on VM virtual_machine_name.
    Failed to start the virtual machine.
    Module DevicePowerOn power on failed.
    Could not set up "macAddress" for ethernet0.
    Invalid MAC address specified.
    xx:xx:xx:xx:xx:xx is not a valid static Ethernet address. It conflicts with VMware reserved MACs for other usage.

    You may also see this error similar to:

    An error was received from the ESX host while powering on VM GroupCRMProd.
    Failed to start the virtual machine.
    Module DevicePowerOn power on failed.
    Could not set up "macAddress" for ethernet0.
    Invalid MAC address specified.
    xx:xx:xx:xx:xx:xy is not an allowed VPX-assigned Ethernet address. It conflicts with VMware reserved MACs for other usage.

    Note: This error indicates that the MAC address of the virtual machine is invalid.
  • You see similar error message in the vmware.log file:

    <YYYY-MM-DD><time> | vmx| I120: E1000: Failed to init MAC backend
    or
    <YYYY-MM-DD><time> | vmx| I120: VMXNET3 user: failed to register with MAC backend</time></time>


Cause

This issue occurs when the virtual machine has been configured with a static MAC address in the 00:50:56:xx:xx:xx range.

VMware vCenter Server 5.1 detects this as a protected range and refuses to power on the virtual machine.

Resolution

This issue is resolved in:


After applying this patch, you can power on the virtual machine by setting the value of ethernetx.checkMACAddress to FALSE in the VMX file of the virtual machine, so that the MAC address is not validated against the range.

To change the value for ethernetx.checkMACAddress:

Method 1:
  1. Shut down the virtual machine.
  2. Right-click the virtual machine.
  3. Click Remove from Inventory.
  4. Log in to a console session on the ESX/ESXi host as the root user.
  5. Go to the virtual machine home directory:

    # cd /vmfs/volumes/DatastoreName/VMFolderName

  6. Run this command to make a backup of the existing virtual machine's .vmx configuration file:

    cp vmname.vmx vmname.vmx.old

  7. Open the .vmx configuration file in an editor such as vi or nano.
  8. Add or change these entries:

    ethernetN.checkMACAddress = "false"
    ethernetN.addressType = "static"
    ethernetN.Address = "XX:XX:XX:XX:XX:XX"


    Where XX:XX:XX:XX:XX:XX is the new MAC address for the virtual machine. Change N in ethernetN with the Network Adapter value. For example:

    Network Adapter 1 -> ethernet0
    Network Adapter 2 -> ethernet1

  9. Register the virtual machine back to the Inventory. For more information, see Registering or adding a virtual machine to the inventory on vCenter Server or on an ESX/ESXi host (1006160).
  10. Start the virtual machine.

Method 2:

  1. Shut down the virtual machine.
  2. Log in to a console session on the ESX/ESXi host as the root user.
  3. Go to the virtual machine home directory:

    # cd /vmfs/volumes/DatastoreName/VMFolderName
  4. Run this command to make a backup of the existing virtual machine's .vmx configuration file:

    cp vmname.vmx vmname.vmx.old
  5. Open the .vmx configuration file in an editor such as vi or nano.
  6. Add or change these entries:

    ethernetN.checkMACAddress = "false"
    ethernetN.addressType = "static"
    ethernetN.Address = "XX:XX:XX:XX:XX:XX"


    Where XX:XX:XX:XX:XX:XX is the new MAC address for the virtual machine. Change N in ethernetN with the Network Adapter value. For example:

    Network Adapter 1 -> ethernet0
    Network Adapter 2 -> ethernet1
  7. Obtain the Inventory ID (Vmid) for the virtual machine using this command:

    # vim-cmd vmsvc/getallvms

    Note: The output shows virtual machines which are registered on the ESXi/ESX host.

    You see output similar to:

    Vmid Name File Guest OS Version
    2848 Win2003_storage_performance [local] Win .vmx winNetEnterpriseGuest vmx-07


    In this example, the Vmid is 2848.
  8. Reload the .vmx file using this command:

    # vim-cmd vmsvc/reload Vmid

    For more information, see Reloading a vmx file without removing the virtual machine from inventory (1026043).
  9. Power on the virtual machine.



Additional Information


How to register/add a VM to the Inventory in vCenter Server
Reloading a vmx file without removing the virtual machine from inventory
VMware ESXi 5.1, Patch Release ESXi510-201307001
VMware ESXi 5.1, Patch ESXi-5.1.0-20130704001-standard
VMware vCenter Server 5.x に移行した後で仮想マシンをパワーオンすると次のエラーで失敗する:無効な MAC アドレスが指定されました
迁移到 VMware vCenter Server 5.x 后打开虚拟机电源失败并显示错误:指定的 MAC 地址无效