澳门新蒲京娱乐

图片 3
Hadoop在CentOS下的单机配置,1伪分布式环境

编译开发系统澳门新蒲京娱乐:

Centos下查看和修改网卡Mac地址澳门新蒲京娱乐:

正文首要介绍下修改MAC地址的秘诀。
#1,查看当前MAC地址,何况备份

Centos下查看和修改网卡Mac地址

linux/Centos下查看网卡Mac地址,输入指令:

#ifconfig -a

eth0 Link encap:Ethernet HWaddr 00:e4:56:2E:D8:20

00:e4:56:2E:D8:20就是你的MAC地址。

linux/Centos下以root权限有时退换MAC地址:

1)闭网卡设备

  /sbin/ifconfig eth0 down

2)修改MAC地址

  /sbin/ifconfig eth0 hw ether MAC地址

3)重启网卡

  /sbin/ifconfig eth0 up

4)查看修改是不是见效:

ifconfig eth0 | grep HWaddr

瞩目:上述修改MAC地址只是一时的,系统重启后,系统会恢复生机原物理MAC地址。

Linux/Centos下何以恒久修改网卡MAC地址

网络有成都百货上千关于linux下修改MAC地址的方法,经过测量试验,最后消除办法如下:

误区一:

#ifconfig eth0 down /*禁掉eth0网卡,这里以eth0网卡为例*/

#ifconfig eth0 hw ether 00:AA:BB:CC:DD:EE /*修改eth0网卡的MAC地址*/

#ifconfig eth0 up /*重复起动eth0网卡*/

下一场再一次开动主机。

结论:遵照这种办法修改MAC地址,重新开动主机系统后,MAC地址会活动还原。

误区二:

#ifconfig eth0 down

#cd /etc/sysconfig/network-scripts

#vi ifcfg-eth0

修改其中的”HWADDOdyssey=xx:xx:xx:xx:xx:xx”

#ifconfig eth0 up

#service network start

敲定:依照这种艺术修改MAC地址后将不可能启用网络,会出现如下提醒:

澳门新蒲京娱乐 ,“Bringing up interface eth0: Device eth0 has different MAC address than
expected,ignoring.”

在linux/Centos情形下将修改后的MAC地址长久保存的没有错的步子如下:

#ifconfig eth0 down

#cd /etc/sysconfig/network-scripts

#vi ifcfg-eth0

修改其中的”HWADD福特Explorer=xx:xx:xx:xx:xx:xx”为”MACADD昂科威=xx:xx:xx:xx:xx:xx”

#ifconfig eth0 up

#service network start

注意:关键词HWADDOdyssey和MACADD君越是有分其他。

末尾附ifconfig命令格式:

ifconfig --help`` Usage:````ifconfig [-a] [-v] [-s] <interface> [[<AF>] <address>]````[add <address>[/<prefixlen>]]````[del <address>[/<prefixlen>]]````[[-]broadcast [<address>]] [[-]pointopoint [<address>]]````[netmask <address>] [dstaddr <address>] [tunnel <address>]````[outfill <NN>] [keepalive <NN>]````[hw <HW> <address>] [metric <NN>] [mtu <NN>]````[[-]trailers] [[-]arp] [[-]allmulti]````[multicast] [[-]promisc]````[mem_start <NN>] [io_addr <NN>] [irq <NN>] [media <type>]````[txqueuelen <NN>]````[[-]dynamic]````[up|down] ...````<HW>=Hardware Type.````List of possible hardware types:````loop (Local Loopback) slip (Serial Line IP) cslip (VJ Serial Line IP)````slip6 (6-bit Serial Line IP) cslip6 (VJ 6-bit Serial Line IP) adaptive (Adaptive Serial Line IP)````strip (Metricom Starmode IP) ash (Ash) ether (Ethernet)````tr (16/4 Mbps Token Ring) tr (16/4 Mbps Token Ring (New)) ax25 (AMPR AX.25)````netrom (AMPR NET/ROM) rose (AMPR ROSE) tunnel (IPIP Tunnel)````ppp (Point-to-Point Protocol) hdlc ((Cisco)-HDLC) lapb (LAPB)````arcnet (ARCnet) dlci (Frame Relay DLCI) frad (Frame Relay Access Device)````sit (IPv6-in-IPv4) fddi (Fiber Distributed Data Interface) hippi (HIPPI)````irda (IrLAP) ec (Econet) x25 (generic X.25)````infiniband (InfiniBand)````<AF>=Address family. Default: inet````List of possible address families:````unix (UNIX Domain) inet (DARPA Internet) inet6 (IPv6)````ax25 (AMPR AX.25) netrom (AMPR NET/ROM) rose (AMPR ROSE)````ipx (Novell IPX) ddp (Appletalk DDP) ec (Econet)````ash (Ash) x25 (CCITT X.25)

linux/Centos下查看网卡Mac地址,输入指令: #ifconfig -a eth0 Link
encap:Ethernet HWaddr 00:e4:56:2E:D8:20
00:e4:56:2E:D8:20即是你…

查阅当前MAC地址:

ifconfig | grep HWaddr

output:

eth0 Link encap:Ethernet HWaddr 00:19:48:2E:D1:2

00:19:48:2E:D1:2正是您的MAC地址,将其复制到一个文书中保留。

#2,以root权限修改MAC地址:

禁用eth0

ifdown eth0

修改MAC地址为00:E0:81:5C:B4:0F

ifconfig eth0 hw ether 00:E0:81:5C:B4:0F

生效修改:

相关文章

No Comments, Be The First!
近期评论
    功能
    网站地图xml地图