zoukankan      html  css  js  c++  java
  • Vmware克隆Centos 不能上网的解决方案

    问题:用Vmware克隆Centos 6.4后,发现系统内只有eth1,而且/etc/sysconfig/network-scripts/下只有,ifcfg-eth0文件,虽然可以上网,但无法设置静态IP。

    ifconfig eth0

    eth1: error fetching interface information: Device not found


    解决:vi /etc/udev/rules.d/70-persistent-net.rules 显示为:

    # PCI device 0x8086:0x100f (e1000)

    SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:0c:29:48:85:9c", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"


    将 NAME="eth1" 改成NAME="eth0"

    并将 ATTR{address}=="00:0c:29:48:85:9c",中的网卡地址改到

    /etc/sysconfig/network-scripts/ifcfg-eth0 文件中,HWADDR="00:0C:29:48:85:9C",使他们对应。

    然后reboot

    ifconfig eth0

    eth0      Link encap:Ethernet  HWaddr 00:0C:29:48:85:9C  

             inet addr:192.168.74.148  Bcast:192.168.74.255  Mask:255.255.255.0

             inet6 addr: fe80::20c:29ff:fe48:859c/64 Scope:Link

             UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

             RX packets:5032 errors:0 dropped:0 overruns:0 frame:0

             TX packets:3674 errors:0 dropped:0 overruns:0 carrier:0

             collisions:0 txqueuelen:1000

             RX bytes:5762656 (5.4 MiB)  TX bytes:209372 (204.4 KiB)


    完成。

  • 相关阅读:
    (字符串)子串变位词
    反转链表 II
    翻转链表
    覆盖索引
    MySQL索引结构之Hash索引、full-text全文索引(面)
    MySQL索引结构之B+树索引(面)
    MYSQL 存储引擎(面)
    MySQL架构(面)
    如何在Linux Mint 20系统上安装Pip
    如何在CentOS 8系统服务器上安装Nginx
  • 原文地址:https://www.cnblogs.com/jamesf/p/4751506.html
Copyright © 2011-2022 走看看