zoukankan      html  css  js  c++  java
  • Linux虚拟机克隆后,启动系统发现网卡无法启动

    一、Linux虚拟机克隆后,启动系统发现网卡无法启动,然后ifup eth0网卡会提示(Device eth0 does not seem to be present, delaying initialization.)失败。

    二、处理方法:

    方法一:

    1、[root@yum ~]# vim /etc/udev/rules.d/70-persistent-net.rules 


    # This file was automatically generated by the /lib/udev/write_net_rules
    # program, run by the persistent-net-generator.rules rules file.
    #
    # You can modify it, as long as you keep each rule on a single
    # line, and change only the value of the NAME= key.
    # PCI device 0×1022:0×2000 (pcnet32)
    SUBSYSTEM==”net”, ACTION==”add”, DRIVERS==”?*”, ATTR{address}==”08:00:27:7e:8c:e7″, ATTR{type}==”1″, KERNEL==”eth*”, NAME=”eth0″
    # PCI device 0×1022:0×2000 (pcnet32)
    SUBSYSTEM==”net”, ACTION==”add”, DRIVERS==”?*”, ATTR{address}==”08:00:27:30:c2:57″, ATTR{type}==”1″, KERNEL==”eth*”, NAME=”eth1″

    记录下,eth1网卡的mac地址08:00:27:30:c2:57

    接下来,打开/etc/sysconfig/network-scripts/ifcfg-eth0

    2、[root@yum ~]#  vim /etc/sysconfig/network-scripts/ifcfg-eth0

    将 DEVICE=”eth0″ 改成 DEVICE=”eth1″ ,
    将 HWADDR=”08:00:27:7e:8c:e7″ 改成上面的mac地址 HWADDR=”08:00:27:30:c2:57″

    3、# ifdown eth0 && ifup eth0 或者# /etc/init.d/network restart 或service network restart

    方法二:

    1、删除(/etc/sysconfig/network-scripts/ifcfg-eth0)网卡MAC地址行(HWADDR=)数据。

    2、最后重启操作系统后正常。查看(ifconfig)是否正常。(不推荐该方法)

  • 相关阅读:
    Spring IOC三种注入方式(接口注入、setter注入、构造器注入)(摘抄)
    java设计模式之代理模式
    JAVA学习中好网站
    程序员学习能力提升三要素
    ognl中的#、%和$
    二级缓存
    hibernate主键自动生成
    专科考研学校要求一览表
    Chapter 3: Connector(连接器)
    Chapter 2: A Simple Servlet Container
  • 原文地址:https://www.cnblogs.com/zksfyz/p/5453911.html
Copyright © 2011-2022 走看看