将RHEL7系统网卡名称eno16777736改为eth0

访客 阅读:16 2024-06-29 03:39:55 评论:0
美化布局示例

欧易(OKX)最新版本

【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   全球官网 大陆官网

币安(Binance)最新版本

币安交易所app【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址

火币HTX最新版本

火币老牌交易所【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址

在红帽RHEL7与Centos7系统中网卡命名规则被重新定义,您的网卡名称可能会是”eno167777xx”,可是已经习惯了eth0这种名称了,怎么办?那么按照《Linux就该这么学》书中的方法将让您将网卡重新命名为eth0,炒鸡煎蛋!!

In the Red Hat RHEL7 and Centos7 system, the name of the net card has been redefined, and your card may be called "eno16777xx", but it's used to the name eth0. So what if you rename the card eth0, fried chicken eggs according to the method used in Linux's book?

  • 一台Rhel7或Centos7系统的Linux主机。
  1. 1

    第1步:当红帽RHEL7系统安装完成,您的网卡名称会是这样的。

    Step 1: When the Red Hat RHEL7 system is installed, the name of your card will be the same.

    将RHEL7系统网卡名称eno16777736改为eth0
  2. 2

    第2步:将网卡配置文件的NAME参数项修改为eth0。

    Step 2: Amend the NAME parameter entry for the network card configuration file to eth0.

    将RHEL7系统网卡名称eno16777736改为eth0
  3. 3

    第3步:将网卡配置文件ifcfg-eno1677736重命名为ifcfg-eth0:

    Step 3: Rename the web card configuration file ifcfg-eno 1677336 as ifcfg-eth0:

    将RHEL7系统网卡名称eno16777736改为eth0
  4. 4

    第4步:修改grub文件来禁用内核继续使用该命名规则,步骤:

    Step 4: Amend the grub file to disable the kernel from continuing to use the naming rule, step by step:

    编辑grub配置文件”/etc/sysconfig/grub“:

    Edit grub profile "/etc/sysconfig/grub":

    在”GRUB_CMDLINE_LINUX“变量中添加一句”net.ifnames=0 biosdevname=0“.

    Add "net.ifnames=0 biosdevname=0" to "GRUB_CMDLINE_LINUX" variable.

    将RHEL7系统网卡名称eno16777736改为eth0
  5. 5

    第5步:重新生成grub配置并更新内核参数:

    Step 5: Regenerate grub configuration and update kernel parameters:

    运行命令:”grub2-mkconfig -o /boot/grub2/grub.cfg“

    Run command: "grub2-mkconfig-o/boot/grub2/grub.cfg"

    将RHEL7系统网卡名称eno16777736改为eth0
  6. 6

    第6步:添加udev的规则(很有必要!)

    Step 6: add the rules forudev (required!)

    需要在”/etc/udev/rules.d“目录中创建一个网卡规则”70-persistent-net.rules“,并写入下面的语句:

    You need to create a webcard rule in the "/etc/udev/rules.d" directory "70-persistent-net.rules" and write the following statement:

    SUBSYSTEM=="net",ACTION=="add",DRIVERS=="?*",ATTR{address}=="您的网卡MAC地址",ATTR{type}=="1" ,KERNEL=="eth*",NAME="eth0"

    SUBSYSTEM==&quat;net&quat;,ACTION==&quat;add&quat;, DRIVERS==&quat; *&quat; *, ATTR{address}=&quat; your Internet card MAC address &quat;, ATT{type}=&quat; 1&quat;, KERENEL==&quat; eth*&quat; NAME=&quat; et0&quat;

    将RHEL7系统网卡名称eno16777736改为eth0
  7. 7

    第7步:重启系统后验证下吧!

    Step 7: Verify when the system is restarted!

    将RHEL7系统网卡名称eno16777736改为eth0
    END
  • 请确保您的系统是RHEL7或Centos7系统。
经验内容仅供参考,如果您需解决具体问题(尤其法律、医学等领域),建议您详细咨询相关领域专业人士。
作者声明:本篇经验系本人依照真实经历原创,未经许可,谢绝转载。
展开阅读全部

文字格式和图片示例

注册有任何问题请添加 微信:MVIP619 拉你进入群

弹窗与图片大小一致 文章转载注明 网址:https://netpsp.com/?id=69313

美化布局示例

欧易(OKX)最新版本

【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   全球官网 大陆官网

币安(Binance)最新版本

币安交易所app【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址

火币HTX最新版本

火币老牌交易所【遇到注册下载问题请加文章最下面的客服微信】永久享受返佣20%手续费!

APP下载   官网地址
可以去百度分享获取分享代码输入这里。
声明

1.本站遵循行业规范,任何转载的稿件都会明确标注作者和来源;2.本站的原创文章,请转载时务必注明文章作者和来源,不尊重原创的行为我们将追究责任;3.作者投稿可能会经我们编辑修改或补充。

发表评论
平台列表
美化布局示例

欧易(OKX)

  全球官网 大陆官网

币安(Binance)

  官网

火币(HTX)

  官网

Gate.io

  官网

Bitget

  官网

deepcoin

  官网
关注我们

若遇到问题,加微信客服---清歌

搜索
排行榜
扫一扫,加我为微信好友加我为微信好友