Device eth0 does not seem to be present

Whenever i clone a VM in my Parallels Desktop (for mac) I always face this issue in new VM. It do not finds the eth0 on startup and when i do

#
ifup eth0
#

i always see this error

#
Device eth0 does not seem to be present
#

Main reason behind is CentOS remembers the OLD NIC information and still looking for that By Default. Even though New NIC information is there but it is in conflict and new NIC has been given a new name may be eth1 or eth2. so check that you need to edit the /etc/udev/rules.d/70-persistent-net.rules

#
nano /etc/udev/rules.d/70-persistent-net.rules
#

You will see something like this

# PCI device 0x8086:0x100f (e1000)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:1c:42:a4:53:77", 
ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

# PCI device 0x8086:0x100f (e1000)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:1c:42:a8:37:52", 
ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"

You may even see more devices, you need to identify which device is your current, normally it is the last one. so remove all other devices and leave only last one and change the “NAME=”eth1″ to NAME=”eth0”

# PCI device 0x8086:0x100f (e1000)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:1c:42:a8:37:52", 
ATTR{type}=="1", KERNEL=="eth*", NAME="eth00"

save the file,

now edit the /etc/sysconfig/network-scripts/ifcfg-eth0

DEVICE="eth0"
BOOTPROTO="static"
IPADDR=172.18.5.24
NETMASK=255.255.0.0
GATEWAY=172.18.3.254
BROADCAST=172.18.255.255
HWADDR="00:15:5D:03:97:22"
ONBOOT="yes"
TYPE="Ethernet"
UUID="cf26beab-96aa-4002-8ffe-f095b907264c"

See the highlighted lines , adjust those according to your new settings and remove the “UUID=”
save the file

update the udev configuration, if you want the changes to take effect without restarting your Operating system, else restart your OS and all things will work smoothly

just use following command

#
start_udev
#

restart the netwoek

#
service network restart
#

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.