Problem: After cloning CentOS 6.4 with VMware, it is found that only eth1 is in the system, and/etc/sysconfig/network-scripts/only, ifcfg-eth0 file, although the Internet access is available, but cannot set static IP.
Ifconfig eth0
Eth1: error fetching interface information: Device not found
Solution: vi/etc/udev/rules. d/70-persistent-net.rules is displayed as follows:
# 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"
Change NAME = "eth1" to NAME = "eth0"
And change the NIC address in ATTR {address} = "00: 0c: 29: 48: 85: 9c"
In the/etc/sysconfig/network-scripts/ifcfg-eth0 file, HWADDR = "00: 0C: 29: 48: 85: 9C" to match them.
Then 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 FIG: 1000
RX bytes: 5762656 (5.4 MiB) TX bytes: 209372 (204.4 KiB)
Complete.