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

Only newly created LVM PVs are added to system.devices config file

    • Icon: Bug Bug
    • Resolution: Done-Errata
    • Icon: Major Major
    • rhel-9.4
    • rhel-9.2.0
    • python-blivet
    • None
    • python-blivet-3.6.0-14.el9
    • None
    • Important
    • rhel-sst-storage-management
    • 24
    • 25
    • 2
    • False
    • Hide

      None

      Show
      None
    • None
    • Red Hat Enterprise Linux
    • None
    • None

      If the /etc/lvm/devices/system.devices config file doesn't already exist (for example when it was not created during installation), creating a new LVM setup using Blivet will create the file and only add the new PVs which means the pre-existing PVs and VGs will be now ignored by LVM.

      This can be easily reproduced by running a simple storage role playbook on a system without the  /etc/lvm/devices/system.devices config file:

      • name: configure swap
         hosts: localhost

       vars:

       roles:
         - name: linux-system-roles.storage
       vars:
         storage_pools:
         - name: swapvg
           disks:
             - /dev/sdd
           volumes:
             - name: swap
               size: 80%
               fs_type: swap
               state: present

       

      after running it, only the new PV on /dev/sdd will be added:

      # cat /etc/lvm/devices/system.devices  

      1. LVM uses devices listed in this file.
      2. Created by LVM command vgcreate pid 244151 at Wed May 17 18:55:54 2023
        VERSION=1.1.2
        IDTYPE=devname IDNAME=/dev/sdd DEVNAME=/dev/sdd PVID=THQL8MFocGOkw4k6oC2zQo6J0l8rrRp1

       

      Blivet should not create the devices file in this case or add all pre-existing PVs to it. A workaround to this issue is either running vgimportdevices --all before running the role or removing the devices file created by blivet afterwards.

              vtrefny@redhat.com Vojtěch Trefný
              vtrefny@redhat.com Vojtěch Trefný
              Vojtěch Trefný Vojtěch Trefný
              Release Test Team Release Test Team
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

                Created:
                Updated:
                Resolved: