Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-6952

Cannot recreate volume group when using Raid on LVM

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • rhel-7.9.z
    • rhel-7.9.z
    • rear
    • Major
    • sst_cs_system_management
    • ssg_core_services
    • None
    • False
    • Hide


    • None
    • If docs needed, set a value
    • None

      Description of problem:

      See Upstream PR https://github.com/rear/rear/pull/2564

      When having a LV in Raid, and 2 PVs making the VG, an error occurs when re-creating the VG in case Migration mode is used, which usually is the default since having multiple disks with same size make ReaR do a mapping and enter Migration mode.

      -------- 8< ---------------- 8< ---------------- 8< ---------------- 8< --------
      Start system layout restoration.
      Disk '/dev/vda': creating 'msdos' partition table
      Disk '/dev/vda': creating partition number 1 with name 'primary'
      Disk '/dev/vda': creating partition number 2 with name 'primary'
      Creating LVM PV /dev/vdb
      Creating LVM PV /dev/vdc
      Creating LVM PV /dev/vda2
      Creating LVM VG 'data'; Warning: some properties may not be preserved...
      The disk layout recreation script failed
      -------- 8< ---------------- 8< ---------------- 8< ---------------- 8< --------

      Internally the failure happens because a "vgcreate" is used on the existing VG, no "vgremove" is ever performed.

      Version-Release number of selected component (if applicable):

      All versions, including Upstream

      How reproducible:


      Steps to Reproduce:

      1. Install a system

      2. Add 2 additional disks that will be used to host a LVM VG with same size


      3. Create a Raid volume

      1. pvcreate /dev/vdb
      2. pvcreate /dev/vdc
      3. vgcreate data /dev/vdb /dev/vdc
      4. lvcreate -n vol1 -L 1G -m 1 data
      5. mkfs.xfs /dev/data/vol1
      6. mount /dev/data/vol1 /mnt

      4. Build a rescue image and perform a recovery

      Actual results:


      Expected results:

      No failure

      Additional info:

      There is no easy workaround, the admin needs to edit the diskrestore.sh file.

            rhn-support-pcahyna Pavel Cahyna
            rhn-support-rmetrich Renaud M├ętrich
            Pavel Cahyna Pavel Cahyna
            rhel-cs-system-management-subsystem-qe Bot rhel-cs-system-management-subsystem-qe Bot
            0 Vote for this issue
            3 Start watching this issue