Top
PRIMECLUSTER Global Link Services Configuration and AdministrationGuide 4.5Redundant Line Control Function
FUJITSU Software

6.3.1 Shutdown maintenance for a NIC

The following describes the procedure for swapping a NIC after stopping the system on RHEL6. When swapping multiple NICs, replace them one at a time without replacing them at once. Perform the swapping procedure for each swapped NIC.

  1. Collect the interface name of NIC.

    Collect the interface name from /sys/class/net directory.

    # cd /sys/class/net
    # ls
    eth0 eth1 lo
  2. Check the correspondence between NICs and MAC addresses.

    Check the MAC address for all the interface name collected in step 1.

    # cat eth0/address
    <MAC_address>
  3. Check the correspondence between NICs and bus addresses.

    Check the bus address of NIC for all the interface name collected in step 1.

    # ls -l eth0/device
    lrwxrwxrwx 1 root root 0 Apr 9 09:17 eth0/device -> ../../../0000:01:06.0

    The bus address is the file name (directory) of the lowest layer of the symbolic link destination file displayed in the output command result.

    The bus address is the address information for identifying the device configuring the following information.

    [<segment_number>:]<bus_number>:<slot_number>.<function_number>

    The segment number is not displayed depending on the model, because it is used as a part of bus number.

  4. Create a hardware address description of NIC from the information collected in steps 1 to 3.

    Table 6.1 Hardware address description of NIC (Example)

    Interface name

    MAC address

    Bus address

    eth0

    <MAC_address>

    <bus_number>:<slot_number>.<function_number>

    ...

    ...

    ...

  5. Edit the udev rule file to comment or delete the definition line of the NIC to be swapped.

    # vi /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.
    ..
    # PCI device 0xXXXX:0xXXXX (e1000)
    SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", \
    ATTR{address}=="XX:XX:XX:XX:XX:XX", ATTR{type}=="1", KERNEL=="eth*", NAME="ethX"

    The backslash (\) at the end of line indicates no break.

  6. Shut down the system.

    # shutdown -h now
  7. Swap NIC.

  8. Start up the system in the single user mode.

  9. Modify the operating system network configuration file.

    9-1. Perform steps 1 to 4 again to create a hardware address description of NIC after swapping.

    9-2. Compare the hardware address description of before and after swapping NIC. Extract the NIC whose MAC address does not match and then identify the port of the swapped NIC.

    9-3. Compare the correspondence between Interface name and Bus address for the NIC port that does not match with the MAC address checked in step 9-2.

    • If the correspondence between Interface name and Bus address matches with the before and after swapping NIC

      Interface names are not switched. In this case, set the MAC address in the hardware address description of after swapping NIC to the interface configuration file.

    • If the correspondence between Interface name and Bus address does not match with the before and after swapping NIC

      Perform the following actions because interface names are switched.

      1. Check the pre-swap bus address of the targeted NIC port.

      2. Search for the checked bus address from the hardware address description after swapping NIC.

      3. Acquire the MAC address for the bus address to modify the interface configuration file.

      4. Correct the MAC address of the corresponding interface name of the udev rule file.
        If the interface definition line corresponding to the port of the NIC before swapping remains in the udev rule file, delete the interface name definition line before swapping. An interface name definition line corresponding to the new MAC address has also been added. Correct the interface name of the new interface name definition line to the intended interface name.

    Note

    For multiple NIC ports, all ports of the interface configuration file must be edited.

    Repeat step 9-3.

  10. Check the udev rule file.
    Make sure that the MAC address and interface name of the udev rule file match the contents of the interface configuration file.

  11. Reboot the system.

    # shutdown -r now
  12. Modify the hardware address description of NIC.
    Modify the MAC address of the hardware address description of NIC created in step 4.