免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
1234
最近访问板块 发新帖
楼主: sunmoonsea
打印 上一主题 下一主题

[网络管理] 如何修改mac地址让它一直生效? [复制链接]

论坛徽章:
0
31 [报告]
发表于 2008-07-10 08:33 |只看该作者
原帖由 kenduest 于 2006-5-30 13:29 发表


若是你是使用 RHEL 这类版本的话,请考虑先看一下 /etc/sysconfig/network-scripts/ifup 看一下:


# this isn't the same as the MAC in the configuration filename.  It is
# available as a config ...

相当专业

论坛徽章:
0
32 [报告]
发表于 2008-07-10 22:16 |只看该作者

长见识了,5 楼

真详细!

致敬

论坛徽章:
0
33 [报告]
发表于 2009-11-03 18:50 |只看该作者
试验过,还是没法永久生效。

论坛徽章:
0
34 [报告]
发表于 2010-05-12 10:51 |只看该作者
在VMware环境下测试楼主的三个命令不成功:
我的环境是RHEL5.3
  1. [root@mysql2 ~]# ifconfig eth0
  2. eth0      Link encap:Ethernet  HWaddr 00:00:F8:F8:E5:BF  
  3.           inet addr:192.168.79.129  Bcast:192.168.79.255  Mask:255.255.255.0
  4.           BROADCAST MULTICAST  MTU:1500  Metric:1
  5.           RX packets:827652 errors:0 dropped:0 overruns:0 frame:0
  6.           TX packets:51616 errors:0 dropped:0 overruns:0 carrier:0
  7.           collisions:0 txqueuelen:1000
  8.           RX bytes:74188764 (70.7 MiB)  TX bytes:30689098 (29.2 MiB)
  9.           Interrupt:67 Base address:0x2000
复制代码
  1. [root@mysql2 ~]# ifconfig eth0 down
  2. [root@mysql2 ~]# ifconfig
  3. lo        Link encap:Local Loopback  
  4.           inet addr:127.0.0.1  Mask:255.0.0.0
  5.           inet6 addr: ::1/128 Scope:Host
  6.           UP LOOPBACK RUNNING  MTU:16436  Metric:1
  7.           RX packets:72 errors:0 dropped:0 overruns:0 frame:0
  8.           TX packets:72 errors:0 dropped:0 overruns:0 carrier:0
  9.           collisions:0 txqueuelen:0
  10.           RX bytes:11116 (10.8 KiB)  TX bytes:11116 (10.8 KiB)
复制代码
  1. [root@mysql2 ~]# ifconfig eth0 hw ether 00 11 22 33 44 55
  2. [root@mysql2 ~]# ifconfig eth0
  3. eth0      Link encap:Ethernet  HWaddr 00:00:38:43:8F:BF  
  4.           inet addr:0.0.0.55  Bcast:255.255.255.255  Mask:0.0.0.0
  5.           inet6 addr: fe80::200:38ff:fe43:8fbf/64 Scope:Link
  6.           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
  7.           RX packets:828030 errors:0 dropped:0 overruns:0 frame:0
  8.           TX packets:51640 errors:0 dropped:0 overruns:0 carrier:0
  9.           collisions:0 txqueuelen:1000
  10.           RX bytes:74218693 (70.7 MiB)  TX bytes:30693991 (29.2 MiB)
  11.           Interrupt:67 Base address:0x2000
复制代码
  1. [root@mysql2 ~]# ifconfig eth0 up
  2. [root@mysql2 ~]# ifconfig eth0
  3. eth0      Link encap:Ethernet  HWaddr 00:00:38:43:8F:BF  
  4.           inet addr:0.0.0.55  Bcast:255.255.255.255  Mask:0.0.0.0
  5.           inet6 addr: fe80::200:38ff:fe43:8fbf/64 Scope:Link
  6.           UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
  7.           RX packets:828862 errors:0 dropped:0 overruns:0 frame:0
  8.           TX packets:51644 errors:0 dropped:0 overruns:0 carrier:0
  9.           collisions:0 txqueuelen:1000
  10.           RX bytes:74304278 (70.8 MiB)  TX bytes:30694247 (29.2 MiB)
  11.           Interrupt:67 Base address:0x2000
复制代码
未见改变。。
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP