jueves, 16 de mayo de 2013

LINUX-RHEL-solución a "Device eth2 has different MAC address than expected, ignoring"

Cuando se añade una o más interfaces de red al server, es común asignar una ip fija a cada una de ellas.
Para ello es necesario generar los archivos de configuración ifcfg-eth0, ifcfg-eth1 que se ubican en la ruta "/etc/sysconfig/network-scripts"

Sin embargo al configurar estos archivos, muchos olvidan ingresar el valor correcto de la dirección MAC_ADRESS de la NIC, lo que genera el siguiente error al intentar levantar las interfaces añadidas.


[root@Ashur network-scripts]# service network restart
Shutting down interface eth0:                              [  OK  ]
Shutting down loopback interface:                          [  OK  ]
Bringing up loopback interface:                            [  OK  ]
Bringing up interface eth0:  
Determining IP information for eth0... done.
                                                           [  OK  ]
Bringing up interface eth1:  Device eth1 has different MAC address than expected, ignoring.
                                                           [FAILED]
Bringing up interface eth2:  Device eth2 has different MAC address than expected, ignoring.
                                                           [FAILED]

Se debe verificar el valor de la MAC_ADRESS en el archivo 70-persistent-net.rules




[root@Ashur network-scripts]# cat /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 0x8086:0x100e (e1000)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="08:00:27:70:90:e4", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

# PCI device 0x8086:0x100e (e1000)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="08:00:27:7d:47:ae", ATTR{type}=="1", KERNEL=="eth*", NAME="eth1"

# PCI device 0x8086:0x100e (e1000)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="08:00:27:f7:a4:8d", ATTR{type}=="1", KERNEL=="eth*", NAME="eth2"
[root@Ashur network-scripts]# 

De esta forma se debe modificar el valor "HWADDR" del archivo ifcfg-eth"N"(donde N es 0,1,2, etc) ingresando el valor configurado en el archivo 70-persistent-net.rules


[root@Ashur network-scripts]# cat /etc/sysconfig/network-scripts/ifcfg-eth2
DEVICE=eth2
HWADDR=08:00:27:f7:a4:8d
TYPE=Ethernet
UUID=e6030157-34a0-46b0-a7ba-bb9f72253148
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=dhcp
[root@Ashur network-scripts]# 


Al cambiar el valor en la configuración de interfaces, se levantan correctamente:

 [root@Ashur network-scripts]# service network restart
Shutting down interface eth0:                              [  OK  ]
Shutting down loopback interface:                          [  OK  ]
Bringing up loopback interface:                            [  OK  ]
Bringing up interface eth0:  
Determining IP information for eth0...

 done.
                                                           [  OK  ]
Bringing up interface eth1:  
Determining IP information for eth1... done.
                                                           [  OK  ]
Bringing up interface eth2:  
Determining IP information for eth2... done.
                                                           [  OK  ]
[root@Ashur network-scripts]# 


No hay comentarios:

Publicar un comentario