CHAPTER 4 PCI Card Hot Maintenance in Red Hat Enterprise Linux 6
4.6 Hot Replacement of PCI Express Cards
96
C122-E175-01EN
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ¥
ATTR{address}=="00:0e:0c:70:c3:40", ATTR{type}=="1", ¥
KERNEL=="eth*", NAME="eth0"
# PCI device 0x****:0x**** (e1000)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ¥
ATTR{address}=="00:0e:0c:70:c3:41", ATTR{type}=="1", ¥
KERNEL=="eth*", NAME="eth1"
:
:
The ¥ at the end of a line indicates that there is no line feed.
c Reflect the edited rules again.
Repeat the process done in step 9 to reflect the rules.
# udevadm control ––reload-rules
d Power on the PCI Express slot.
Repeat the process done in step 10 to power on the PCI Express slot.
The interfaces created for the replacement NIC may be active because power is on to the PCI
Express slot. At this stage, since we recommend proceeding with the work with the interface on the
replaced NIC deactivated, repeat the operation in step 12.
e Collect the information about interfaces on the NIC again, and create a table.
Use the same procedure as in step 2 to update the interface name information in the table from step
13 showing the correspondence of the interface before and after NIC replacement.
Note
Confirm that each specified interface name is the same as before the NIC replacement.
Table4.10 Confirmation of interface names
Interface name
Hardware address
Bus address
Slot number
eth0
00:0e:0c:70:c3:40
0000:0b:01.0
20
eth1
00:0e:0c:70:c3:41
0000:0b:01.1
20
...
...
...
...
16. Edit the saved interface configuration file.
Write a new hardware address to replace the old one. In "HWADDR," set the hardware address of the
replacement NIC in ‘TABLE 4.9 Example of entered values corresponding to the interface names before
and after NIC replacement’’ or ‘TABLE 4.5 Hardware address description examples’. Also, for SLAVE
under bonding, the file contents are partly different, but the lines to be set are the same.
(Example)
DEVICE=eth0
NM_CONTROLLED=no BOOTPROTO=static HWADDR=00:0E:0C:70:C3:40
BROADCAST=192.168.16.255
IPADDR=192.168.16.1
NETMASK=255.255.255.0
NETWORK=192.168.16.0
ONBOOT=yes
TYPE=Ethernet
Do this editing for all the saved interfaces.
17. Restore the saved interface configuration file to the original file.
Restore the interface configuration file saved to the save directory to the original file by executing the
following command.
# cd /etc/sysconfig/network-scripts/temp
# mv ifcfg-ethX ..
(following also executed for bonding configuration)
# mv ifcfg-bondX ..
18. Activate the replaced interface.
The method for activating a single NIC interface differs from that for activating the SLAVE interfaces
under bonding.
[For a single NIC interface]
Execute the following command to activate the interface. Activate all the necessary interfaces.