Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 2161181

Summary: [RHEL9.2] lvm_dbus_tests.LvmTestLVcreateRemove.test_lvcreate_lvremove failed
Product: Red Hat Enterprise Linux 9 Reporter: guazhang <guazhang>
Component: libblockdevAssignee: Vojtech Trefny <vtrefny>
Status: CLOSED ERRATA QA Contact: guazhang <guazhang>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 9.2CC: cwei, tbzatek
Target Milestone: rcKeywords: Triaged
Target Release: ---Flags: pm-rhel: mirror+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: libblockdev-2.28-5.el9 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-11-07 08:25:07 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description guazhang@redhat.com 2023-01-16 09:02:59 UTC
Description of problem:
libblockdev regression found the error, please have a look

Version-Release number of selected component (if applicable):
 libblockdev-2.28-3.el9.x86_64

How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

======================================================================
FAIL: test_lvcreate_lvremove (lvm_dbus_tests.LvmTestLVcreateRemove)
Verify that it's possible to create/destroy an LV
----------------------------------------------------------------------
gi.repository.GLib.GError: g-io-error-quark: Failed to call the 'LvCreate' method on the '/com/redhat/lvmdbus1/Vg/4' object: GDBus.Error:org.freedesktop.DBus.Python.dbus.exceptions.DBusException: ('com.redhat.lvmdbus1.Vg', 'Exit code 5, stderr = ') (36)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/root/rpmbuild/BUILD/libblockdev-2.28/tests/lvm_dbus_tests.py", line 697, in test_lvcreate_lvremove
    succ = BlockDev.lvm_lvcreate("testVG", "testLV", 1048 * 1024**2, None, [self.loop_dev], None)
AssertionError: "Insufficient free space" does not match "g-io-error-quark: Failed to call the 'LvCreate' method on the '/com/redhat/lvmdbus1/Vg/4' object: GDBus.Error:org.freedesktop.DBus.Python.dbus.exceptions.DBusException: ('com.redhat.lvmdbus1.Vg', 'Exit code 5, stderr = ') (36)"



the udisks2 also hit lvm errors, please have a look if it's same questions 
 udisks2-2.9.4-7.el9.x86_64 
======================================================================
ERROR: test_10_linear (test_20_LVM.UdisksLVMTest)
Test linear (plain) LV functionality
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/root/rpmbuild/BUILD/udisks-2.9.4/src/tests/dbus-tests/test_20_LVM.py", line 149, in test_10_linear
    lv.Resize(dbus.UInt64(lvsize.value/2), self.no_options, dbus_interface=self.iface_prefix + '.LogicalVolume')
  File "/usr/lib64/python3.9/site-packages/dbus/proxies.py", line 141, in __call__
    return self._connection.call_blocking(self._named_service,
  File "/root/rpmbuild/BUILD/udisks-2.9.4/src/tests/dbus-tests/udiskstestcase.py", line 42, in call_long
    return call(*args, **kwargs)
  File "/usr/lib64/python3.9/site-packages/dbus/connection.py", line 652, in call_blocking
    reply_message = self.send_message_with_reply_and_block(
dbus.exceptions.DBusException: org.freedesktop.UDisks2.Error.Failed: Error resizing logical volume: Process reported exit code 5:   The LV must be active to safely reduce (see --fs options.)

https://beaker.engineering.redhat.com/recipes/13232165#task154881563

Comment 1 Vojtech Trefny 2023-01-16 15:05:02 UTC
These are two unrelated issues. The libblockdev test failure is already reported to lvm upstream as https://bugzilla.redhat.com/show_bug.cgi?id=2145114 The udisks failure is new so I am moving this to udisks for further triage.

Comment 2 Tomáš Bžatek 2023-01-17 13:41:07 UTC
I think I've seen the "Insufficient free space" messages coming from the LVM2 UDisks plugin. The key for successful debugging would be a good reproducibility as this may be a random error, just like the others we're getting.

Please try to provide some steps to reproduce, something that may hit the issue at least with 10% chance during the tries.

Comment 3 Tomáš Bžatek 2023-02-21 16:13:20 UTC
Looking at the "Exit code 5" errors both failures appear to be the same issue, i.e. https://github.com/storaged-project/libblockdev/issues/841 ?

Comment 4 Tomáš Bžatek 2023-02-22 09:51:52 UTC
Temporary udisks workaround for the reference: https://github.com/storaged-project/udisks/pull/1057

Comment 5 Vojtech Trefny 2023-03-03 08:37:56 UTC
upstream PR: https://github.com/storaged-project/libblockdev/pull/855

Comment 6 guazhang@redhat.com 2023-04-04 06:44:35 UTC
Hi,
Test pass with fixed package.
python3 -s run_tests.py  lvm_dbus_tests.LvmTestLVcreateRemove

Comment 11 errata-xmlrpc 2023-11-07 08:25:07 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (libblockdev bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2023:6342