Ubuntu Change Default Mac Address

Ubuntu used netplan as new network manager, but it’s different with previous version.

First create a new file /etc/systemd/network/10-override-mac.link

[Match]
MacAddress=52:54:00:12:34:56

[Link]
MACAddress=52:54:00:12:34:58

52:54:00:12:34:56 is old mac, and 52:54:00:12:34:58 is new mac .

Second, modify /etc/netplan/01-netcfg.yaml, create match: and macaddress field , example

network:
version: 2
ethernets:
eth0:
dhcp4: true
match:
macaddress: ’52:54:00:12:34:58′
set-name: eth0

ref.

Netplan not spoofing MAC as expected

On this day..

Comments

comments

Related Posts

Leave a Comment


NOTE - You can use these HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>