Previous Topic: Create and Run the Restore JobNext Topic: Verify that the Target Machine is Restored


(Optional) Perform Post-BMR Operations

The following topics are optional configuration settings that you may have to perform after a BMR:

Configure X Windows

When you perform a BMR across a dissimilar hardware, X Windows of the restored OS does not function properly and the target node displays an error dialog. The error dialog appears because the display configuration has changed. To resolve this error, follow the instructions in the error dialog to configure the graphic card. After that, you can see the X Windows and the desktop UI.

Configure the System Fully Qualified Domain Name (FQDN)

When you need an FQDN, then you must configure the FQDN. The BMR process does not automatically configure the FQDN.

Maximum character count for FQDN: 63

Follow these steps to configure the FQDN:

  1. Edit the /etc/hosts file and provide the IP Address, the FQDN name, and the server name.
    #vi /etc/hosts
    
    ip_of_system  servername.domainname.com  servername
    
  2. Restart the network service.
    #/etc/init.d/network restart
    
  3. Verify the host name and the FQDN name.
    #hostname
    
    servername
    
    #hostname -f
    
    servername.domainname.com
    

The FQDN is configured.

Extend the Data Volume after a BMR on Dissimilar Disks

When you perform a BMR to a larger disk than the disk on the original node, some disk space is left unused. The BMR operation does not automatically process the unused disk space. You can format the disk space to a separate partition or resize the existed partition with the unused disk space. The volume that you want to resize must be unused, so you must avoid resizing a system volume. In this section, we will focus on how to extend a data volume with the unused disk space.

Note: To avoid data loss, resize your volumes immediately after the BMR process. You can also back up the node before starting the volume resizing task.

When the target machine successfully restarts after the BMR, you can extend the data volume.

Raw partition volume

For example, a 2-GB disk in the session is restored to a 16-GB disk named /dev/sdb with only one partition. The /dev/sdb1 raw partition is directly mounted on the /data directory.

This example is used to explain the procedure of extending Raw partition volume.

Follow these steps:

  1. Check the status of the /dev/sdb1 volume.
    # df -h /dev/sdb1
    
    /dev/sdb1             2.0G   40M  1.9G   3% /data
    
  2. Umount the /dev/sdb1 volume.
    # umount /data
    
  3. Resize /dev/sdb1 to occupy the entire disk space using the fdisk command.

    To perform this operation, first delete your existing partition and then recreate it with the same start sector number. The same start sector number is responsible for avoiding the data loss.

    # fdisk -u /dev/sdb
    
    Command (m for help): p
    
    Disk /dev/sdb: 17.1 GB, 17179869184 bytes
    
    255 heads, 63 sectors/track, 2088 cylinders, total 33554432 sectors
    
    Units = sectors of 1 * 512 = 512 bytes
    
    Device Boot      Start         End      Blocks   Id  System
    
    /dev/sdb1              63     4192964     2096451   83  Linux
    
    Command (m for help): d
    
    Selected partition 1
    
    Command (m for help): n
    
    Command action
    
    e   extended
    
    p   primary partition (1-4)
    
    p
    
    Partition number (1-4): 1
    
    First sector (63-33554431, default 63):
    
    Using default value 63
    
    Last sector or +size or +sizeM or +sizeK (63-33554431, default 33554431): 
    
    Using default value 33554431
    
    Command (m for help): p
    
    Disk /dev/sdb: 17.1 GB, 17179869184 bytes
    
    255 heads, 63 sectors/track, 2088 cylinders, total 33554432 sectors
    
    Units = sectors of 1 * 512 = 512 bytes
    
    Device Boot      Start         End      Blocks   Id  System
    
    /dev/sdb1              63    33554431    16777184+  83  Linux
    
    Command (m for help): w
    

    The partition changes to the same start sector number as the original partition and the end sector number is 33554431.

  4. Resize the volume using resize2fs command. If necessary, first run the e2fsck command.
    # e2fsck -f /dev/sdb1
    
    # resize2fs /dev/sdb1
    
  5. Mount the volume to the mount point and check the volume status again.
    # mount /dev/sdb1 /data
    
    # df -h /dev/sdb1
    
    /dev/sdb1              16G   43M   16G   1% /data
    

    The volume is extended to 16 GB and is ready for use.

LVM volume:

For example, an 8-GB disk in the session is restored to a 16-GB disk named /dev/sdc with only one partition. The /dev/sdc1 raw partition is used as the only physical volume of the /dev/mapper/VGTest-LVTest LVM logical volume whose mount point is /lvm.

This example is used to explain the procedure of extending LVM volume.

Follow these steps:

  1. Check the status of the /dev/mapper/VGTest-LVTest volume.
    # lvdisplay -m /dev/mapper/VGTest-LVTest
    
    --- Logical volume ---
    
    LV Name                /dev/VGTest/LVTest
    
    VG Name                VGTest
    
    LV UUID                udoBIx-XKBS-1Wky-3FVQ-mxMf-FayO-tpfPl8
    
    LV Write Access        read/write
    
    LV Status              available
    
    # open                 1
    
    LV Size                7.88 GB
    
    Current LE             2018
    
    Segments               1
    
    Allocation             inherit
    
    Read ahead sectors     0
    
    Block device           253:2
    
    ---Segments---
    
    Logical extent 0 to 2017:
    
    Type                linear
    
    Physical volume     /dev/sdc1
    
    Physical extents    0 to 2017
    

    The physical volume is /dev/sdc1, the volume group is VGTest, and the logical volume is /dev/VGTest/LVTest or /dev/mapper/VGTest-LVTest.

  2. Umount the /dev/mapper/VGTest-LVTest volume.
    # umount /lvm
    
  3. Disable the volume group in which the /dev/sdc1 physical volume is located.
    # vgchange -a n VGTest
    
  4. Create a partition to occupy the unused disk space using the fdisk command.
    # fdisk -u /dev/sdc
    
    Command (m for help): p
    
    Disk /dev/sdc: 17.1 GB, 17179869184 bytes
    
    255 heads, 63 sectors/track, 2088 cylinders, total 33554432 sectors
    
    Units = sectors of 1 * 512 = 512 bytes
    
    Device Boot      Start         End      Blocks   Id  System
    
    /dev/sdc1              63    16777215     8388576+  83  Linux
    
    Command (m for help): n
    
    Command action
    
    e   extended
    
    p   primary partition (1-4)
    
    p
    
    Partition number (1-4): 2
    
    First sector (16777216-33554431, default 16777216): 
    
    Using default value 16777216
    
    Last sector or +size or +sizeM or +sizeK (16777216-33554431, default 33554431): 
    
    Using default value 33554431
    
    Command (m for help): p
    
    Disk /dev/sdc: 17.1 GB, 17179869184 bytes
    
    255 heads, 63 sectors/track, 2088 cylinders, total 33554432 sectors
    
    Units = sectors of 1 * 512 = 512 bytes
    
    Device Boot      Start         End      Blocks   Id  System
    
    /dev/sdc1              63    16777215     8388576+  83  Linux
    
    /dev/sdc2        16777216    33554431     8388608   83  Linux
    
    Command (m for help): w
    

    The /dev/sdc2 partition is created.

  5. Create a new physical volume.
    # pvcreate /dev/sdc2
    
  6. Extend the volume group size.
    # vgextend VGTest /dev/sdc2
    
  7. Enable the volume group that you have already disabled.
    # vgchange -a y VGTest
    
  8. Extend the logical volume size using the lvextend command.
    # lvextend -L +8G /dev/VGTest/LVTest
    
  9. Resize the volume using the resize2fs command. If necessary, first run the e2fsck command.
    # e2fsck -f /dev/mapper/VGTest-LVTest
    
    # resize2fs /dev/mapper/VGTest-LVTest
    
  10. Mount the volume to the mount point and check the volume status again.
    # mount /dev/mapper/VGTest-LVTest /lvm
    
    # lvdisplay -m /dev/mapper/VGTest-LVTest
    
    ---Logical volume---
    
    LV Name                /dev/VGTest/LVTest
    
    VG Name                VGTest
    
    LV UUID                GTP0a1-kUL7-WUL8-bpbM-9eTR-SVzl-WgA11h
    
    LV Write Access        read/write
    
    LV Status              available
    
    # open                 0
    
    LV Size                15.88 GB
    
    Current LE             4066
    
    Segments               2
    
    Allocation             inherit
    
    Read ahead sectors     0
    
    Block device           253:2
    
    --- Segments ---
    
    Logical extent 0 to 2046:
    
    Type                linear
    
    Physical volume     /dev/sdc1
    
    Physical extents    0 to 2046
    
    Logical extent 2047 to 4065:
    
    Type                linear
    
    Physical volume     /dev/sdc2
    
    Physical extents    0 to 2018
    

    The LVM volume extends to 16 GB and is ready for use.