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. Activiti如何替换已部署流程图

    首先交代下背景:我们有一个已经上线的activiti工作流系统,对于流程图的操作已经封装好部署,查看,删除的接口.此时客户提出要修改个别流程图里的节点名称. 我的第一个想法就是本地修改流程图bpmn文 ...

  2. linux系统下部署war包

    http://blog.csdn.net/hellowangchaochao/article/details/73223773

  3. transition结合:after,:before实现动画

    div代码 <div class='div'> hover </div> css代码 .div{ width:200px; height:100px; line-height: ...

  4. Restful Framework (三)

    目录 一.版本 二.解析器 三.序列化 四.请求数据验证 一.版本 回到顶部 程序也来越大时,可能通过版本不同做不同的处理 没用rest_framework之前,我们可以通过以下这样的方式去获取. c ...

  5. 微软企业库5.0 学习之路——第八步、使用Configuration Setting模块等多种方式分类管理企业库配置信息

    在介绍完企业库几个常用模块后,我今天要对企业库的配置文件进行处理,缘由是我打开web.config想进行一些配置的时候发现web.config已经变的异常的臃肿(大量的企业库配置信息充斥其中),所以决 ...

  6. 如何开启apache的PHP-FPM实例

    PHP-FPM 作为 FastCGI 进程管理器而广为熟知,它是PHPFastCGI 实现的改进,带有更为有用的功能,用于处理高负载的服务器和网站.下面列出其中一些功能: 新功能 拥有具有优雅(gra ...

  7. 最小生成树算法详解(prim+kruskal)

    最小生成树概念: 一个有 n 个结点的连通图的生成树是原图的极小连通子图,且包含原图中的所有 n 个结点,并且有保持图连通的最少的边. 最小生成树可以用kruskal(克鲁斯卡尔)算法或prim(普里 ...

  8. 嵌套循环连接(Nested Loops Joins)

    The nested loops join, also called nested iteration, uses one join input as the outer input table(sh ...

  9. ZOJ 2974 Just Pour the Water

    矩阵快速幂. 构造一个矩阵,$a[i][j]$表示一次操作后,$j$会从$i$那里得到水的比例.注意$k=0$的时候,要将$a[i][j]$置为$1$. #pragma comment(linker, ...

  10. Luogu P2590 树的统计(树链剖分+线段树)

    题意 原文很清楚了 题解 重链剖分模板题,用线段树维护即可. #include <cstdio> #include <cstring> #include <algorit ...