# Same mac address on each device

**URL:** <https://hub.mender.io/t/same-mac-address-on-each-device/6935>\
**Category:** General Discussions\
**Tags:** raspberry-pi-4\
**Created:** [June 11, 2024, 3:14pm UTC](https://hub.mender.io/t/same-mac-address-on-each-device/6935 "2024-06-11T15:14:28Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Thorben](https://avatars.discourse-cdn.com/v4/letter/t/ec9cab/32.png) [@Thorben](https://hub.mender.io/u/Thorben)\
**Post date:** [June 11, 2024, 3:14pm UTC](https://hub.mender.io/t/same-mac-address-on-each-device/6935/1 "2024-06-11T15:14:28Z")

</div>

Hello, I have a problem with starting mender. I have installed the Bullseye image of mender on a Raspberry pi 4. Now I have the problem that I have the same mac address on all devices. The mac address is always the one from the first boot. How can I make sure that the mac addresses are not the same? The wrong mac address is also shown under /sys/class/net/eth0/address. The correct mac address is entered under /proc/cmdline. Unfortunately I can’t get any further and hope someone can help me.

---

<div class="post-metadata">

**Author:** ![pyxlwuff](https://avatars.discourse-cdn.com/v4/letter/p/898d66/32.png) [@pyxlwuff](https://hub.mender.io/u/pyxlwuff)\
**Post date:** [June 12, 2024, 9:29am UTC](https://hub.mender.io/t/same-mac-address-on-each-device/6935/2 "2024-06-12T09:29:09Z")

</div>

Hi there,

How are you distributing this image? Did you deploy on one Pi 4 and then use the SD card from that one to create an image for the rest?

---

<div class="post-metadata">

**Author:** ![Thorben](https://avatars.discourse-cdn.com/v4/letter/t/ec9cab/32.png) [@Thorben](https://hub.mender.io/u/Thorben)\
**Post date:** [June 12, 2024, 9:44am UTC](https://hub.mender.io/t/same-mac-address-on-each-device/6935/3 "2024-06-12T09:44:18Z")

</div>

Hi, yes, that’s exactly how I tried it. But I also have the same Mac address if I don’t clone the sd card. If I use the same SD card in different Pi’s they also have the same Mac address.

---

<div class="post-metadata">

**Author:** ![pyxlwuff](https://avatars.discourse-cdn.com/v4/letter/p/898d66/32.png) [@pyxlwuff](https://hub.mender.io/u/pyxlwuff)\
**Post date:** [June 12, 2024, 1:49pm UTC](https://hub.mender.io/t/same-mac-address-on-each-device/6935/4 "2024-06-12T13:49:11Z")

</div>

Yep, that’s [a behaviour that’s been around for quite a few years now](https://www.reddit.com/r/raspberry_pi/comments/ebapu0/psa_in_raspbian_mac_addresses_are_set_on_first/) on Raspberry Pi devices. Your best bet is to make an image via mender-convert and deploy the image you make through that onto your devices.

---

<div class="post-metadata">

**Author:** ![Thorben](https://avatars.discourse-cdn.com/v4/letter/t/ec9cab/32.png) [@Thorben](https://hub.mender.io/u/Thorben)\
**Post date:** [June 12, 2024, 3:26pm UTC](https://hub.mender.io/t/same-mac-address-on-each-device/6935/5 "2024-06-12T15:26:50Z")

</div>

Thank you very much in advance. I tried to convert a bullseye image with mender-convert and now I have the error that the pi cannot boot. When booting I get the message BusyBox v1.35.0. do you have an idea what I am doing wrong?

---

<div class="post-metadata">

**Author:** ![pyxlwuff](https://avatars.discourse-cdn.com/v4/letter/p/898d66/32.png) [@pyxlwuff](https://hub.mender.io/u/pyxlwuff)\
**Post date:** [June 12, 2024, 9:22pm UTC](https://hub.mender.io/t/same-mac-address-on-each-device/6935/6 "2024-06-12T21:22:37Z")

</div>

Unfortunately I don’t believe bullseye or later is supported (yet). The latest you can get through mender-convert is a 32 bit Buster image, which might not be ideal depending on your use case. We personally pivoted from a Raspberry Pi distribution to something built from Yocto earlier this year so there might be workarounds i’m not aware of

---

<div class="post-metadata">

**Author:** ![lueschem](https://yyz2.discourse-cdn.com/flex036/user_avatar/hub.mender.io/lueschem/32/214_2.png) [@lueschem](https://hub.mender.io/u/lueschem)\
**Post date:** [June 14, 2024, 9:06pm UTC](https://hub.mender.io/t/same-mac-address-on-each-device/6935/7 "2024-06-14T21:06:15Z")

</div>

I did a [Mender integration without U-Boot](https://github.com/lueschem/edi-pi). This might be the root cause why I never run into the issue of having “sticky” MAC addresses.

---

<div class="post-metadata">

**Author:** ![Thorben](https://avatars.discourse-cdn.com/v4/letter/t/ec9cab/32.png) [@Thorben](https://hub.mender.io/u/Thorben)\
**Post date:** [July 16, 2024, 9:58am UTC](https://hub.mender.io/t/same-mac-address-on-each-device/6935/8 "2024-07-16T09:58:25Z")

</div>

Hello,  
I was able to solve the problem with the stick mac address.  
uboot seems to fix the mac address with fw\_setenv ethaddr or fw\_setenv usbethaddr at the first boot. I checked it with fw\_printenv. To solve the problem i just deleted these variables before cloning.

I hope I could help you!
