方法一:
$ifconfig eth0 hw ether XX:XX:XX:XX:XX:XX
$/etc/init.d/networking restart(重启网卡)
方法二:
以上只是暂时的修改硬件地址要永久修改,直接编辑 /etc/network/interfaces 文件,在 iface eth0 inet static 后面添加一行: pre-up ifconfig eth0 hw ether xx:xx:xx:xx:xx:xx(要改成的MAC)
$ sudo /etc/init.d/networking restart(重启网卡)
本文介绍了两种在Linux系统中更改网卡MAC地址的方法。一种是临时修改,使用ifconfig命令;另一种是永久修改,通过编辑interfaces文件实现。
844

被折叠的 条评论
为什么被折叠?



