跳转到内容
主菜单
主菜单
移至侧栏
隐藏
导航
首页
最近更改
随机页面
MediaWiki帮助
Mcuzone Wiki
搜索
搜索
登录
个人工具
登录
查看“模板:RTL8125 MAC SINGLE EN”的源代码
模板
讨论
大陆简体
阅读
查看源代码
查看历史
工具
工具
移至侧栏
隐藏
操作
阅读
查看源代码
查看历史
常规
链入页面
相关更改
特殊页面
页面信息
←
模板:RTL8125 MAC SINGLE EN
因为以下原因,您没有权限编辑本页:
您请求的操作仅限属于该用户组的用户执行:
用户
您可以查看和复制此页面的源代码。
The 2.5G Ethernet port uses the RTL8125 network card, and during use, the MAC address is not fixed. Each time the device is powered on again, the MAC address changes randomly. The following explains how to set a fixed MAC address for the RTL8125 network card. This explanation also applies to the Ubuntu system. First, check the identification information of the RTL8125 network card in terminal: <code>ipconfig -a</code> http://www.mcuzone.com/wiki/0015_MP2_5G/0015_MP2_5G_28.jpg Here, the RTL8125 network card is identified as eth1, but in practice, the name recognized by the system might be different. Then input: <code>sudo mousepad /etc/systemd/system/macspoof@eth1.service</code> Or: <code>sudo nano /etc/systemd/system/macspoof@eth1.service</code> eth1 is the name recognized by the system for the network card shown above. Executing the above command will create a new document, then enter the following text: [<code>Unit]</code> <code>Description=MAC Address Change %I</code> <code>Wants=network-pre.target</code> <code>Before=network-pre.target</code> <code>BindsTo=sys-subsystem-net-devices-%i.device</code> <code>After=sys-subsystem-net-devices-%i.device</code> <code>[Service]</code> <code>Type=oneshot</code> <code>ExecStart=/usr/bin/ip link set dev %i address xx:xx:xx:xx:xx:xx</code> <code>ExecStart=/usr/bin/ip link set dev %i up</code> <code>[Install]</code> <code>WantedBy=multi-user.target</code> Here, "xx:xx:xx:xx:xx:xx" represents the MAC address you wish to assign. You can determine it according to the MAC address format (make sure it does not duplicate the MAC address of other network devices). After setting it, save and exit. Then execute the following command to enable the service: <code>sudo systemctl enable macspoof@eth1.service</code> This completes the fixation of the MAC address for eth1. After completing all operations, restart the system. Once the system has finished rebooting, execute <code>ipconfig -a</code> to see that the MAC address has been successfully changed. http://www.mcuzone.com/wiki/0015_MP2_5G/0015_MP2_5G_29.jpg
返回
模板:RTL8125 MAC SINGLE EN
。
开关有限宽度模式