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 1994220 - [Udisks2] Error reading statistics from /sys/kvdo/udisks_test_vdo_vg-udisks_test_vdopool-vpool/statistics
Summary: [Udisks2] Error reading statistics from /sys/kvdo/udisks_test_vdo_vg-udisks_t...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: libblockdev
Version: 9.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: beta
: ---
Assignee: Vojtech Trefny
QA Contact: guazhang@redhat.com
URL:
Whiteboard:
Depends On: 1999568
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-08-17 04:54 UTC by guazhang@redhat.com
Modified: 2022-06-07 03:30 UTC (History)
2 users (show)

Fixed In Version: libblockdev-2.25-10.el9
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-05-17 13:24:34 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-93806 0 None None None 2021-08-17 10:01:25 UTC
Red Hat Product Errata RHBA-2022:2503 0 None None None 2022-05-17 13:24:41 UTC

Description guazhang@redhat.com 2021-08-17 04:54:00 UTC
Description of problem:
RHEL9 Udisks2 regression testing hit the error, please have a look if hit a bug

Version-Release number of selected component (if applicable):
udisks2-2.9.2-5.el9.x86_64 

How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:
hit error 

Expected results:
no error

Additional info:



======================================================================
ERROR: test_create (test_20_LVM.UdisksLVMVDOTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/root/rpmbuild/BUILD/udisks-2.9.2/src/tests/dbus-tests/test_20_LVM.py", line 508, in test_create
    stats = lv.GetStatistics(self.no_options, dbus_interface=self.iface_prefix + '.VDOVolume')
  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.2/src/tests/dbus-tests/udiskstestcase.py", line 41, 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 retrieving volume statistics: Error reading statistics from /sys/kvdo/udisks_test_vdo_vg-udisks_test_vdopool-vpool/statistics: Error opening directory “/sys/kvdo/udisks_test_vdo_vg-udisks_test_vdopool-vpool/statistics”: No such file or directory


https://beaker-archive.host.prod.eng.bos.redhat.com/beaker-logs/2021/08/57065/5706542/10495752/130490111/taskout.log
https://beaker.engineering.redhat.com/recipes/10495752#task130490111

Comment 1 Tomáš Bžatek 2021-08-17 10:00:11 UTC
The code lives in libblockdev. However, what was your kernel and kmod-kvdo rpm package version please?

Comment 2 guazhang@redhat.com 2021-08-17 12:12:24 UTC
Hi

kmod-kvdo-8.1.0.316-2.el9.x86_64
vdo-8.1.0.316-1.el9.x86_64

5.14.0-0.rc4.35.el9.x86_64
RHEL-9.0.0-20210816.2 


[root@storageqe-58 udisks-2.9.2]# python3 src/tests/dbus-tests/run_tests.py -s test_20_LVM.UdisksLVMVDOTest.test_create 
Configuration restored from src/tests/dbus-tests/targetcli_config.json
Not spawning own process: testing the system installed instance.
test_create (test_20_LVM.UdisksLVMVDOTest) ... ERROR

======================================================================
ERROR: test_create (test_20_LVM.UdisksLVMVDOTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/root/rpmbuild/BUILD/udisks-2.9.2/src/tests/dbus-tests/test_20_LVM.py", line 508, in test_create
    stats = lv.GetStatistics(self.no_options, dbus_interface=self.iface_prefix + '.VDOVolume')
  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.2/src/tests/dbus-tests/udiskstestcase.py", line 41, 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 retrieving volume statistics: Error reading statistics from /sys/kvdo/udisks_test_vdo_vg-udisks_test_vdopool-vpool/statistics: Error opening directory “/sys/kvdo/udisks_test_vdo_vg-udisks_test_vdopool-vpool/statistics”: No such file or directory

----------------------------------------------------------------------
Ran 1 test in 3.965s

FAILED (errors=1)
All configuration cleared
[root@storageqe-58 udisks-2.9.2]#

Comment 3 Vojtech Trefny 2021-08-25 16:13:10 UTC
VDO changed its sysfs API, we are reading the VDO pool stats from /sys/kvdo/<device>/statistics right now, with (K)VDO version 8 this is no longer available and we need to use /sys/block/<device>/vdo/statistics.

Libblockdev tests are also failing on this so it's not necessary to use UDisks test suite for testing. UDisks is currently only user of this API so I don't think this is severe enough for a 9-Beta exception and we can move this bug to 9.0.0. UDisks can skip the test if needed.

-----

$ sudo python3 tests/run_tests.py -i lvm_test.LVMVDOTest.test_stats
test_stats (lvm_test.LVMVDOTest) ... ERROR

======================================================================
ERROR: test_stats (lvm_test.LVMVDOTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/vtrefny/libblockdev/tests/lvm_test.py", line 1878, in test_stats
    vdo_stats = BlockDev.lvm_vdo_get_stats("testVDOVG", "vdoPool")
gi.repository.GLib.GError: g-file-error-quark: Error reading statistics from /sys/kvdo/testVDOVG-vdoPool-vpool/statistics: Error opening directory “/sys/kvdo/testVDOVG-vdoPool-vpool/statistics”: No such file or directory (4)

----------------------------------------------------------------------
Ran 1 test in 2.846s

FAILED (errors=1)

Comment 4 Vojtech Trefny 2021-09-03 12:09:33 UTC
upstream PR: https://github.com/storaged-project/libblockdev/pull/659

This fixes the libblockdev part, the tests will still fail, we also use LVM to get some of the statistics and LVM also uses /sys/kvdo (see the linked bug for more details).

Comment 8 guazhang@redhat.com 2021-12-09 02:12:30 UTC
Hi,

[root@storageqe-69 libblockdev-2.25]# python3 tests/run_tests.py  lvm_test.LVMVDOTest.test_stats
/root/rpmbuild/BUILD/libblockdev-2.25/tests/lvm_test.py:13: PyGIWarning: BlockDev was imported without specifying a version first. Use gi.require_version('BlockDev', '2.0') before import to ensure that the right version gets loaded.
  from gi.repository import BlockDev, GLib
skipped 'VDO kernel module not available, skipping.'

----------------------------------------------------------------------
Ran 0 tests in 0.000s

OK (skipped=1)
[root@storageqe-69 libblockdev-2.25]# modprobe kvdo
modprobe: FATAL: Module kvdo not found in directory /lib/modules/5.14.0-24.el9.x86_64
[root@storageqe-69 libblockdev-2.25]# 

the vdo kernel module is not actively, but the case still try to load vdo kernel module, Is it expected ?

Comment 9 Vojtech Trefny 2021-12-09 07:50:15 UTC
I tested this with the latest compose RHEL-9.0.0-20211208.3 and the VDO module works there:

# rpm -qq kmod-kvdo
kmod-kvdo-8.1.0.316-6.el9.x86_64
# uname -r
5.14.0-26.el9.x86_64

Generally if the kernel you are currently running isn't compatible with the installed version of kmod-kvdo, running "weak-modules --add-kernel --no-initramfs" should also help.

Comment 10 guazhang@redhat.com 2021-12-10 00:32:13 UTC
Hi,

After install last compose, the fixed package works well.

vdo-8.1.0.316-1.el9.1.x86_64
kmod-kvdo-8.1.0.316-6.el9.x86_64
libblockdev-2.25-10.el9.x86_64



[root@storageqe-70 libblockdev-2.25]# python3 tests/run_tests.py  lvm_test.LVMVDOTest
/root/rpmbuild/BUILD/libblockdev-2.25/tests/lvm_test.py:13: PyGIWarning: BlockDev was imported without specifying a version first. Use gi.require_version('BlockDev', '2.0') before import to ensure that the right version gets loaded.
  from gi.repository import BlockDev, GLib
test_enabla_disable_compression (lvm_test.LVMVDOTest) ... ok
test_enable_disable_deduplication (lvm_test.LVMVDOTest) ... ok
test_resize (lvm_test.LVMVDOTest) ... ok
test_stats (lvm_test.LVMVDOTest) ... ok
test_vdo_pool_convert (lvm_test.LVMVDOTest) ... ok
test_vdo_pool_create (lvm_test.LVMVDOTest) ... ok
test_vdo_pool_create_options (lvm_test.LVMVDOTest) ... ok

----------------------------------------------------------------------
Ran 7 tests in 22.181s

OK
[root@storageqe-70 libblockdev-2.25]#

Comment 14 errata-xmlrpc 2022-05-17 13:24:34 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 (new packages: libblockdev), 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-2022:2503


Note You need to log in before you can comment on or make changes to this bug.