永久修改MAC地址
方法一:
1)编辑“/etc/init.d/rc.local”文件(sudo gedit /etc/init.d/rc.local)
2)在此配置文件的最后面加上如(Ubuntu:修改网卡的MAC地址)的修改命令:
注:16.04版本里面将本地连接的名字由 "eth0" 改成了 "eno1"
在网络连接中,添加MAC克隆地址,如下:
在 IPV4中,设置好想要修改的 ip信息,最后断开网络,重新连接即可。
其次,修改etc/rc.local文件
ifconfig eth0 down
ifconfig eth0 hw ether 6c:0b:84:a4:a7:68
ifconfig eth0 up
然后重启rc.local
sudo /etc/init.d/rc.local start