VMWare ESXi change MAC Address of physical network adapter

This article explains how to change the MAC address of a physical network adapter on an VmWare ESXi 5.1 host.

1) Connect you with SSH to your ESXi Server

2) Open the file /etc/vmware/esx.conf
vi /etc/vmware/esx.conf

3) Search for your old MAC address and replace it with the new one. You can search in the VI editor by typing “/” without brackets.

4) Save your changes by typing :wq

5) Reboot

Xen: Device xxx (x) could not be connected. Failed to find an unused loop device

If you are using Xen and get an error Device xxxxx (xxx) could not be connected. Failed to find an unused loop device when you try to create a guest. This is because you are out of loop devices.

Run this on command line:
echo "options loop max_loop=32" > /etc/modprobe.d/xen

With the value 32 you are able to run 16 Guests on your host, assuming you aren’t using loop devices for other purposes. Use a number suitable for your needs.

Shutdown your guests and run this on command line:
rmmod loop && modprobe loop

Show all loop devices:
ls -l /dev/ | grep loop