Dans certains cas, on peut vouloir configurer l'adresse MAC de la carte Ethernet :
# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 00:C0:0C:03:EC:83
inet addr:192.168.1.4 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::c0:c03:ec83/10 Scope:Link
inet6 addr: fe80::2c0:cff:fe03:ec83/10 Scope:Link
UP BROADCAST RUNNING MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:32 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
Interrupt:3 Base address:0x300
# ifconfig eth0 down
# ifconfig eth0 hw ether 11:22:33:44:55:66
# ifconfig eth0 192.168.1.4
# ifconfig eth0
eth0 Link encap:Ethernet HWaddr 11:22:33:44:55:66
inet addr:192.168.1.4 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::1122:3344:5566/10 Scope:Link
inet6 addr: fe80::1322:33ff:fe44:5566/10 Scope:Link
UP BROADCAST RUNNING MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:40 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
Interrupt:3 Base address:0x300
#
On voit ici que l'adresse MAC est passée de 00:C0:0C:03:EC:83 (HWaddr 00:C0:0C:03:EC:83) à 11:22:33:44:55:66 (HWaddr 11:22:33:44:55:66).
# ip link show eth0
2: eth0: <BROADCAST> mtu 1500 qdisc pfifo_fast qlen 100
link/ether 00:c0:0c:03:ec:83 brd ff:ff:ff:ff:ff:ff
# ip link set eth0 down
# ip link set eth0 address 11:22:33:44:55:66
# ip link show eth0
2: eth0: <BROADCAST> mtu 1500 qdisc pfifo_fast qlen 100
link/ether 11:22:33:44:55:66 brd ff:ff:ff:ff:ff:ff
#
On voit ici que l'adresse MAC est passée de 00:C0:0C:03:EC:83 (link/ether 00:c0:0c:03:ec:83) à 11:22:33:44:55:66 (link/ether 11:22:33:44:55:66).