'LVMVolumeGroupDevice' object has no attribute 'vg'

Hello

I cannot install any Red Hat products on my laptop, this includes Fedora, Centos, Almalinux, and RHEL. My method for recovering an installation is to reinstall from an Fedora ISO but I receive the following error when I boot into Anaconda:

dasbus.error.DBusError: ‘LVMVolumeGroupDevices’ object has no attribute ‘vg’

I also receive an error when trying to open blivet-gui:
AttributeError: ‘LVMVolumeGroupDevice’ object has no attribute ‘vg’

Here are the list of the logical volumes and volume groups on my computer

root@lpt51:/home/aaron# lvs -v
  LV               VG           #Seg Attr       LSize   Maj Min KMaj KMin Pool   Origin Data%  Meta%  Move Cpy%Sync Log Convert LV UUID                                LProfile
  flashdrive       data            1 -wi-a-----  10.00g  -1  -1  253   11                                                       b8qJjB-uwwH-WzW2-n15J-VYxU-clma-D0oSQL         
  home             data            1 twi-aotz-- 100.00g  -1  -1  253   14               0.00   10.43                            vzL5f1-EDgJ-vQOX-zqrd-m7h9-u8hy-FNOmxC         
  images           data            1 -wi-ao---- 300.00g  -1  -1  253    8                                                       fpgjtl-6bb8-4AdW-RTgR-qGJz-2KkU-1x5l2H         
  windows          data            1 -wi-a----- 300.00g  -1  -1  253   10                                                       2wuJy9-nTZZ-1J0t-Msbp-Z3xt-WwAK-e0OcjX         
  20220821-preMBPT fedora_lpt51    1 swi-I-s---  17.00g  -1  -1  253    6        root   100.00                                  2iViYK-eoQH-naew-mEXe-cFqf-QQSX-1qdUsH         
  pool00           fedora_lpt51    1 twi-aotz--  69.58g  -1  -1  253    2               99.80  43.01                            4ghtVl-XhWa-zfi9-vzA9-luw4-e1v0-lcXXg0         
  root             fedora_lpt51    1 owi-aotz--  69.58g  -1  -1  253    4 pool00        99.80                                   Sv4GNN-WMl1-ETt8-UXkg-D8u2-dGsd-zfYngZ         
root@lpt51:/home/aaron# vgs -v
  VG           Attr   Ext   #PV #LV #SN VSize   VFree    VG UUID                                VProfile
  data         wz--n- 4.00m   1   4   0   1.21t <532.37g U8m8yA-Ax1C-02NQ-1Eb8-ERRi-I6SA-XSU9c4         
  fedora_lpt51 wz--n- 4.00m   1   3   1 <87.16g  444.00m VYCtDr-mH5Y-Rn5l-LfDd-poC3-7FyE-yd3Pw6

Here is the back trace from anaconda

Traceback (most recent call last):
  File "/usr/lib64/python3.9/site-packages/pyanaconda/threading.py", line 275, in run
    threading.Thread.run(self)
  File "/usr/lib64/python3.9/threading.py", line 917, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/lib64/python3.9/site-packages/pyanaconda/ui/lib/storage.py", line 97, in reset_storage
    sync_run_task(task_proxy)
  File "/usr/lib64/python3.9/site-packages/pyanaconda/modules/common/task/__init__.py", line 46, in sync_run_task
    task_proxy.Finish()
  File "/usr/lib/python3.9/site-packages/dasbus/client/handler.py", line 444, in _call_method
    return self._get_method_reply(
  File "/usr/lib/python3.9/site-packages/dasbus/client/handler.py", line 477, in _get_method_reply
    return self._handle_method_error(error)
  File "/usr/lib/python3.9/site-packages/dasbus/client/handler.py", line 497, in _handle_method_error
    raise exception from None
dasbus.error.DBusError: 'LVMVolumeGroupDevice' object has no attribute 'vg'

I deleted to encrypted logical volules, then deleted the lines from the /etc/crypttab file. Any suggestions?

Thank you

Hello
Issue resolved. There was an issue with a snapshot I created, 20220821-preMBPT. I reviewed the storage.log from the anaconda error report. Followed this message:

INFO:program:stderr[9]: 
INFO:program:...done [9] (exit code: 0)
DEBUG:blivet:                         DeviceTree.get_device_by_name: name: fedora_lpt51-20220821-preMBPT ; incomplete: False ; hidden: False ;
DEBUG:blivet:                         DeviceTree.get_device_by_name returned None
INFO:blivet:found lvm snapshot volume 'fedora_lpt51-20220821-preMBPT'
INFO:program:Running [10] lvm lvs --noheadings -o origin fedora_lpt51/20220821-preMBPT --config= log {level=7 file=/tmp/lvm.log syslog=0} --devices=/dev/nvme0n1p3 ...
INFO:program:stdout[10]:   root  

INFO:program:stderr[10]: 
INFO:program:...done [10] (exit code: 0)
DEBUG:blivet:                          DeviceTree.get_device_by_name: name: fedora_lpt51-root ; incomplete: False ; hidden: False ;
DEBUG:blivet:                          DeviceTree.get_device_by_name returned None
DEBUG:blivet:                           DeviceTree.get_device_by_name: name: fedora_lpt51-root ; incomplete: False ; hidden: False ;
DEBUG:blivet:                           DeviceTree.get_device_by_name returned None
DEBUG:blivet:                           DeviceTree.get_device_by_uuid: uuid: Sv4GNN-WMl1-ETt8-UXkg-D8u2-dGsd-zfYngZ ; incomplete: False ; hidden: False ;
DEBUG:blivet:                           DeviceTree.get_device_by_uuid returned None
DEBUG:blivet:get_format('None') returning DeviceFormat instance with object id 71
DEBUG:blivet:                                          LVMVolumeGroupDevice.add_child: name: fedora_lpt51 ; child: root ; kids: 0 ;
INFO:anaconda.threading:Thread Failed: AnaTaskThread-ScanDevicesTask-1 (140155099563584)
ERROR:anaconda.modules.common.task.task:Thread AnaTaskThread-ScanDevicesTask-1 has failed: Traceback (most recent call last):
  File "/usr/lib64/python3.9/site-packages/pyanaconda/threading.py", line 275, in run
    threading.Thread.run(self)
  File "/usr/lib64/python3.9/threading.py", line 917, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/lib64/python3.9/site-packages/pyanaconda/modules/common/task/task.py", line 96, in _thread_run_callback
    self._task_run_callback()
  File "/usr/lib64/python3.9/site-packages/pyanaconda/modules/common/task/task.py", line 109, in _task_run_callback
    self._set_result(self.run())
  File "/usr/lib64/python3.9/site-packages/pyanaconda/modules/storage/reset.py", line 63, in run
    self._reset_storage(self._storage)
  File "/usr/lib64/python3.9/site-packages/pyanaconda/modules/storage/reset.py", line 82, in _reset_storage
    storage.reset()
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib64/python3.9/site-packages/pyanaconda/modules/storage/devicetree/model.py", line 261, in reset
    super().reset(cleanup_only=cleanup_only)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/blivet.py", line 141, in reset
    self.devicetree.populate(cleanup_only=cleanup_only)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/populator/populator.py", line 446, in populate
    self._populate()
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/populator/populator.py", line 490, in _populate
    self.handle_device(dev)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/populator/populator.py", line 309, in handle_device
    self.handle_format(info, device)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/populator/populator.py", line 337, in handle_format
    helper_class(self, info, device).run()
  File "/usr/lib/python3.9/site-packages/blivet/populator/helpers/lvm.py", line 431, in run
    self._update_lvs()
  File "/usr/lib/python3.9/site-packages/blivet/populator/helpers/lvm.py", line 337, in _update_lvs
    new_lv = add_lv(lv)
  File "/usr/lib/python3.9/site-packages/blivet/populator/helpers/lvm.py", line 216, in add_lv
    add_required_lv(origin_device_name,
  File "/usr/lib/python3.9/site-packages/blivet/populator/helpers/lvm.py", line 166, in add_required_lv
    new_lv = add_lv(lv_info[name])
  File "/usr/lib/python3.9/site-packages/blivet/populator/helpers/lvm.py", line 280, in add_lv
    lv_device = LVMLogicalVolumeDevice(lv_name, parents=lv_parents,
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/lvm.py", line 2396, in __init__
    LVMLogicalVolumeBase.__init__(self, name, parents, size, uuid, seg_type,
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/lvm.py", line 680, in __init__
    DMDevice.__init__(self, name, size=size, fmt=fmt,
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/dm.py", line 82, in __init__
    super(DMDevice, self).__init__(name, fmt=fmt, size=size,
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/storage.py", line 147, in __init__
    self.format = fmt
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/storage.py", line 806, in <lambda>
    lambda d, f: d._set_format(f),
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/lvm.py", line 2473, in decorated
    return meth(self, *args, **kwargs)  # pylint: disable=not-callable
  File "/usr/lib/python3.9/site-packages/blivet/devices/lvm.py", line 2575, in _set_format
    LVMLogicalVolumeBase._set_format(self, fmt)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/storage.py", line 746, in _set_format
    fmt = get_format(None, device=self.path, exists=self.exists)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/lvm.py", line 975, in path
    return "%s/%s" % (self._dev_dir, self.map_name)
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/lvm.py", line 970, in map_name
    return "%s-%s" % (self.vg.map_name, self._name.replace("-", "--"))
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/lvm.py", line 2468, in decorated
    found, ret = self._try_specific_call(meth.__name__, *args, **kwargs)  # pylint: disable=no-member
  File "/usr/lib/python3.9/site-packages/blivet/threads.py", line 53, in run_with_lock
    return m(*args, **kwargs)
  File "/usr/lib/python3.9/site-packages/blivet/devices/lvm.py", line 2447, in _try_specific_call
    ret = getattr(cls, name).__get__(self)
  File "/usr/lib/python3.9/site-packages/blivet/devices/lvm.py", line 1791, in vg
    return self.pool.vg
AttributeError: 'LVMVolumeGroupDevice' object has no attribute 'vg'

I deleted the snapshot, blivent and Anaconda are now working.

I hope this helps someone in the future.

1 Like

I marked your last post as solution so that others know at first glance that the topic is solved with that. Feel free to change that if anything is wrong with it.

Thanks for documenting your solution for others!