CentOS 7 nic Name change

Source: Internet
Author: User

Centos7 the NIC name defaults to ENOXXX when the installation is complete, the familiar ethx is not, always feel strange. If the ifconfig command is not found in the minimized installation, install the Net-tools package. The steps to change are as follows:


  1. [[email protected] ~] #vi/etc/sysconfig/network-scripts/ifcfg-enoxxx

    HWADDR=00:0C:29:AF:BF:18
    type=ethernet
    BOOTPROTO=dhcp
    defroute=yes
    peerdns=yes
    PEERROUTES=YES
    NAME=enoXXX                   / /change enoxxx here to ethx
    uuid=17cdd976-0b81-4286-80cf-185ec95f5ae8
    onboot=no                   ///To change No to Yes      

  2. [[Email protected] ~] #cd/etc/sysconfig/network-scripts

    [[Email protected] ~] #mv ifcfg-enoxxx Ifcfg-eth0

  3. [Email protected] ~]# Vi/etc/default/grub
    Grub_timeout=5
    Grub_distributor= "$ (SED ' s, release. *$,,g '/etc/system-release)"
    Grub_default=saved
    Grub_disable_submenu=true
    grub_terminal_output= "Console"
    grub_cmdline_linux= "Vconsole.keymap=us crashkernel=auto vconsole.font=latarcyrheb-sun16 net.ifnames=0 Biosdevname=0 RHGB Quiet "
    Grub_disable_recovery= "true"//Add two parameters marked in red

  4.     //execute this command to reload under Grub configuration
    Generating Grub Configuration file ...
    Found Linux Image:/boot/vmlinuz-3.10.0-123.el7.x86_64
    Found initrd Image:/boot/initramfs-3.10.0-123.el7.x86 _64.img
    Warning:please don ' t use the old title ' CentOS Linux, with the Linux 3.10.0-123.el7.x86_64 ' for Grub_default, use ' ADV anced options for CentOS Linux>centos Linux, with Linux 3.10.0-123.el7.x86_64 ' (for versions before 2.00) or ' gnulinux- advanced-66b96693-051c-4021-85ef-5f7ef0f970e2>gnulinux-3.10.0-123.el7.x86_64- Advanced-66b96693-051c-4021-85ef-5f7ef0f970e2 ' (for 2.00 or later)
    Found Linux Image:/boot/ vmlinuz-0-rescue-b6f54d97b52944738996d2d9aeb3d59b
    Found initrd Image:/boot/ Initramfs-0-rescue-b6f54d97b52944738996d2d9aeb3d59b.img
    Done

  5. [email protected] ~]# reboot

    After restarting the operating system, the name of the CENTOS7 network card is changed.


CentOS 7 nic Name change

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.