Change MAC address

Has anyone successfully changed the MAC address on their BBB running Debian? It seems all of my BBBs have the same MAC address. While this is handy for predicting what IP address it will pull from DHCP, it makes it tough to put more than one BBB on a layer 2 network.

With the official image (5-14-2014), setting hwaddress in /etc/network/interfaces will cause eth0 to fail. I installed kernel 3.8.13-bone68 and now editing /etc/network/interfaces has no effect. Eth0 initializes, but has the same MAC address as before.

If I down the interface and issue #ip link set dev eth0 address 78:a5:04:ca:4f:10 RTNETLINK answers: Operation not supported.

Any guidance would be much appreciated!

Look at your /etc/network/interfaces file, there is a line that say that you can specify the mac address.

Micka,

/etc/network/interfaces…

iface eth0 inet dhcp
hwaddress ether DE:AD:BE:EF:CA:FE

Again, with 5-14-2-14 image, this would cause eth0 to fail to initialize. With 3.8.13-bone68, it seems to have no effect. Eth0 starts up fine but has the same MAC address as before editing the interfaces file.

VT

Sorry for the late reply, I'm sorting through queued mail from the holidays.

/etc/network/interfaces...

iface eth0 inet dhcp
hwaddress ether DE:AD:BE:EF:CA:FE

Again, with 5-14-2-14 image, this would cause eth0 to fail to initialize.
With 3.8.13-bone68, it seems to have no effect. Eth0 starts up fine but
has the same MAC address as before editing the interfaces file.

What OS are you running, and where did you get your boards?

IIRC, the MAC address is pulled from the on-board EEPROM and written to
the PHY by U-Boot. If your EEPROMs all have the same data (I think this
happened with some clone boards) or your boot loader isn't properly
setup, you could see identical MAC addresses.

I have had no issues with a large number of (Circutco) built BeagleBone
boards here. I usually have 3 or 4 online at any given time, and each
one has a unique MAC.

I also don't believe the Linux driver for the on-chip Ethernet supports
modifying the MAC address, so setting this in /etc/network/interfaces
(or otherwise using standard networking commands like "ip link set")
isn't an option.

ethaddr: Ethernet MAC address for first/only ethernet interface (= eth0 in Linux).
This variable can be set only once (usually during manufacturing of the board). U-Boot refuses to delete or overwrite this variable once it has been set.

http://www.denx.de/wiki/view/DULG/UBootEnvVariables

I remember one of Robert’s scripts setting a random MAC address, but which one I do not remember. This was also quite some time ago, so things may have changed since.

I also remember trying to manually set the MAC address to a specific address, and it would not work. That is then when I found the link above, and called no joy.