I want to change the mac address of eth0 of my Raspberry Pi.
I haven't any problems with the wlan0 (macchanger -A wlan0 works)

General information: I have

  • a Raspberry Pi Model B
  • with Arch Linux ARM (archlinux-hf-2013-06-06)

I used

# macchanger -A eth0 

and get this result

Current MAC:   b8:27:eb:bc:d5:fd (Raspberry Pi Foundation)
Permanent MAC: 00:00:00:00:00:00 (Xerox Corporation)
[ERROR] Could not change MAC: interface up or insufficient permissions: Device or resource busy


# ifconfig eth0 down hw ether 01:02:03:04:05:06

with this error

SIOCSIFHWADDR: Cannot assign requested address

I googled a bit and found this. I think there is someone with the same problem but I can't find a solution.

The question is now: Why i get these error messages (when do macchanger / ifconfig makes such an output?) and maybe what can I do to remove them and finally change the mac address?

  • would you prefer a C code to do the MAC setting? – askmish Jul 31 '14 at 12:11
  1. Write a script

    ifconfig eth0 down hw ether 00:00:00:00:00:00
    ifconfig eth0 up

where "00:00:00:00:00:00" - your mac address Let's say you called it mac.sh.

  1. Put it in the /etc/init.d/ directory. And make this file executable using # chmod +x mac.sh

  2. Then run: # update-rc.d mac.sh defaults

That's make your script bootable.

  1. After rebooting mac will be changed

I got this from internet.


Did you forgot sudo? So try sudo macchanger -A eth0 And why you want to change the mac address?

  • no i was logged in as root (look at the '#', if you are a normal user you will get a '$') – Fabian N. Jul 11 '13 at 20:00
  • Ow sorry! I probably looked over it! – Matthijs Logemann Jul 11 '13 at 21:52

Just add smsc95xx.macaddr=00:00:00:00:00:00 to /boot/cmdline.txt.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.