change MAC Address in CentOS 7:

nano /etc/sysconfig/network-scripts/ifcfg-ens160

systemctl restart network.service

或者: /etc/init.d/network restart

You are done. Now, verify by issuing ifconfig command.

If you have a windows machine in the same network. Issue arp -d to delete current ARP table. Then ping CentOS 7 IP Address from Windows PC. Next issue arp -a. You will find the changed MAC next to your CentOS 7 IP Address.

注意: ifcfg-ens160本身的HWADDR不要改动: 
Note: in the file is a value HWADDR - This is not the same thing. Use MACADDR for permanent changes.

The HWADDR "directive is useful for machines with multiple NICs to ensure that the interfaces are assigned the correct device names regardless of the configured load order for each NIC's module. This directive should not be used in conjunction with MACADDR." ... The MACADDR "directive is used to assign a MAC address to an interface, overriding the one assigned to the physical NIC. This directive should not be used in conjunction with HWADDR."

osx上修改mac地址,先删除文件:

rm /Users/xxxx/Library/Preferences/com.teamviewer.TeamViewer.plist

rm /Users/xxxx/Library/Preferences/com.teamviewer.teamviewer.preferences.plist

sudo rm /Library/Preferences/com.teamviewer.teamviewer.preferences.plist

修改centos7/osx的MAC地址的更多相关文章

  1. Android中通过进程注入技术修改系统返回的Mac地址

    致谢 感谢看雪论坛中的这位大神,分享了这个技术:http://bbs.pediy.com/showthread.php?t=186054,从这篇文章中学习到了很多内容,如果没有这篇好文章,我在研究的过 ...

  2. 修改pc机的mac地址 以及 mac地址的组成

    在"开始"菜单的"运行"中输入regedit,打开注册表编辑器,展开注册表到:HKEY_LOCAL_ MACHINE/System/CurrentControl ...

  3. Openwrt:逆向永久修改Flash中的Mac地址

    get mtd device cat /proc/mtd dev: size erasesize name mtd0: 00800000 00010000 "ALL" mtd1: ...

  4. 怎么修改电脑MAC地址 电脑MAC地址修改图文教程

    本文转载:http://www.45fan.com/a/Router/2677.html MAC地址是指电脑网卡的硬件地址,此地址一般烧录在网卡上.MAC地址工作在OSI七层模型的第二层,即数据链接层 ...

  5. linux/Centos下查看和修改网卡Mac地址(ifconfig命令)

    本文转载自http://www.169it.com/article/14360294838474691537.html linux/Centos下查看网卡Mac地址,输入命令: #ifconfig - ...

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

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

  7. CentOS下使用KVM克隆虚拟机自动修改网卡的MAC地址

    克隆完虚拟机之后Mac地址还保留着母机的配置,此时需要修改成新的Mac地址才能继续,网上一般都是这样的手动操作: 参考:http://blog.51cto.com/freedyong/1361907 ...

  8. Linux/CentOS下修改MAC地址

    Linux/CentOS下修改MAC地址 摘自:https://blog.csdn.net/qq_33233768/article/details/64906265 2017年03月22日 11:06 ...

  9. 转 笔记本无线和有线的MAC地址修改

    版权声明:本文为博主原创文章,未经博主允许不得转载. https://blog.csdn.net/xueqiang03/article/details/80741734无线网卡的mac地址在出厂时就被 ...

随机推荐

  1. 修改centos地址连接为自动连接

    1.进入目录/etc/sysconfig/network-scripts/ 2.修改ifcfg-etn0 文件   (即你的网卡标识命名的配置文件) 3.将ONBOOT=no改成yes 4.保存后重启 ...

  2. MYSQL中INET_ATON()函数

    例如我们现在要在一个表中查出 ip 在 192.168.1.3 到 192.168.1.20 之间的 ip 地址,我们首先想到的就是通过字符串的比较来获取查找结果,但是如果我们通过这种方式来查找,结果 ...

  3. hibernate连接Oracle rac

    连接方式与普通的数据库不一样.connection.url 中使用了LOAD-BALANCE = yes 要不然会报错 <hibernate-configuration> <sess ...

  4. 8:django sessions(会话)

    django会话 django提供对匿名会话全方位的支持,会话框架可以存储和检索每个站点访问者的任意数据.会话数据是存储在服务器端的,并且简要了发送和接受cookie的过程,cookies只包含一个s ...

  5. 从Java Future到Guava ListenableFuture实现异步调用

    原文地址: http://blog.csdn.net/pistolove/article/details/51232004 Java Future     通过Executors可以创建不同类似的线程 ...

  6. node采用的commonJs规范

    AMD与commonJS规范不同 同步加载 主要就是一个输出,一个引入,我也建了两个文件,一个输出文件一个引入文件 export.js ; ; ; function incCounter(){ cou ...

  7. 运行在CentOS7.5上的Django项目时间不正确问题

    在Django的配置文件settings.py中,有两个配置参数是跟时间与时区有关的,分别是TIME_ZONE和USE_TZ 如果USE_TZ设置为True时,Django会使用系统默认设置的时区,即 ...

  8. 【ASP.NET MVC】HTML5+MVC上传文件显示进度

    head> <title>Index</title> <style type="text/css"> #statusBorder { po ...

  9. Project interpreter not specified(eclipse+pydev) (转)

    [小记] 最近因为想配置Android的开发环境,把原来的MyEclipse5.5删了,下载了最新的Eclipse3.7版本,因为之前在进行Python开 发,就下载了最新的Pydev2.4版本,安装 ...

  10. 深入解析php中的foreach问题

    本篇文章是对php中的foreach问题进行了详细的分析介绍,需要的朋友参考下   前言:php4中引入了foreach结构,这是一种遍历数组的简单方式.相比传统的for循环,foreach能够更加便 ...