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 1940830 - yum and rpm become broken after installing module
Summary: yum and rpm become broken after installing module
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: lua
Version: 8.4
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: rc
: ---
Assignee: Packaging Maintenance Team
QA Contact: BaseOS QE - Apps
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-03-19 10:09 UTC by Andrei Stepanov
Modified: 2021-03-30 06:23 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-03-30 06:23:51 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Andrei Stepanov 2021-03-19 10:09:19 UTC
After installing a package from module rpm/yum becomes broken:

yum-utils-4.0.18-4.el8.noarch.rpm
yum-4.4.2-11.el8.noarch.rpm 
dnf-data-4.4.2-11.el8.noarch.rpm 
dnf-4.4.2-11.el8.noarch.rpm
dnf-plugin-subscription-manager-1.28
dnf-plugins-core-4.0.18-4.el8.noarch
rpm-4.14.3-13.el8.x86_64.rpm



# yum install copy-jdk-configs-3.7-4.module+el8.4.0+10375+644ee9c3
Last metadata expiration check: 0:27:19 ago on Fri 19 Mar 2021 05:26:43 AM EDT.
Dependencies resolved.
=============================================================================================================================================================================
 Package                                Architecture                 Version                                                        Repository                          Size
=============================================================================================================================================================================
Installing:
 copy-jdk-configs                       noarch                       3.7-4.module+el8.4.0+10375+644ee9c3                            brew-1540137                        26 k
Upgrading:
 lua-libs                               x86_64                       5.3.4-11.module+el8.4.0+10375+644ee9c3                         brew-1540137                       117 k
Installing dependencies:
 lua                                    x86_64                       5.3.4-11.module+el8.4.0+10375+644ee9c3                         brew-1540137                       190 k

Transaction Summary
=============================================================================================================================================================================
Install  2 Packages
Upgrade  1 Package

Total size: 333 k
Is this ok [y/N]: y
Downloading Packages:
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Running scriptlet: copy-jdk-configs-3.7-4.module+el8.4.0+10375+644ee9c3.noarch                                                                                         1/1 
  Preparing        :                                                                                                                                                     1/1 
  Upgrading        : lua-libs-5.3.4-11.module+el8.4.0+10375+644ee9c3.x86_64                                                                                              1/4 
  Installing       : lua-5.3.4-11.module+el8.4.0+10375+644ee9c3.x86_64                                                                                                   2/4 
  Installing       : copy-jdk-configs-3.7-4.module+el8.4.0+10375+644ee9c3.noarch                                                                                         3/4 
  Cleanup          : lua-libs-5.3.4-11.el8.x86_64                                                                                                                        4/4 
  Running scriptlet: copy-jdk-configs-3.7-4.module+el8.4.0+10375+644ee9c3.noarch                                                                                         4/4 
  Running scriptlet: lua-libs-5.3.4-11.el8.x86_64                                                                                                                        4/4 
  Verifying        : copy-jdk-configs-3.7-4.module+el8.4.0+10375+644ee9c3.noarch                                                                                         1/4 
  Verifying        : lua-5.3.4-11.module+el8.4.0+10375+644ee9c3.x86_64                                                                                                   2/4 
  Verifying        : lua-libs-5.3.4-11.module+el8.4.0+10375+644ee9c3.x86_64                                                                                              3/4 
  Verifying        : lua-libs-5.3.4-11.el8.x86_64                                                                                                                        4/4 

Upgraded:
  lua-libs-5.3.4-11.module+el8.4.0+10375+644ee9c3.x86_64                                                                                                                     
Installed:
  copy-jdk-configs-3.7-4.module+el8.4.0+10375+644ee9c3.noarch                                lua-5.3.4-11.module+el8.4.0+10375+644ee9c3.x86_64                               

Complete!


[root@rhel8-31212 ~]# yum remove copy-jdk-configs
Traceback (most recent call last):
  File "/usr/lib64/python3.6/site-packages/libdnf/error.py", line 14, in swig_import_helper
    return importlib.import_module(mname)
  File "/usr/lib64/python3.6/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 994, in _gcd_import
  File "<frozen importlib._bootstrap>", line 971, in _find_and_load
  File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 658, in _load_unlocked
  File "<frozen importlib._bootstrap>", line 571, in module_from_spec
  File "<frozen importlib._bootstrap_external>", line 922, in create_module
  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
ImportError: liblua-5.3.so: cannot open shared object file: No such file or directory

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/bin/yum", line 57, in <module>
    from dnf.cli import main
  File "/usr/lib/python3.6/site-packages/dnf/__init__.py", line 30, in <module>
    import dnf.base
  File "/usr/lib/python3.6/site-packages/dnf/base.py", line 29, in <module>
    import libdnf.transaction
  File "/usr/lib64/python3.6/site-packages/libdnf/__init__.py", line 8, in <module>
    from . import error
  File "/usr/lib64/python3.6/site-packages/libdnf/error.py", line 17, in <module>
    _error = swig_import_helper()
  File "/usr/lib64/python3.6/site-packages/libdnf/error.py", line 16, in swig_import_helper
    return importlib.import_module('_error')
  File "/usr/lib64/python3.6/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
ModuleNotFoundError: No module named '_error'
[root@rhel8-31212 ~]# rpm -qf /usr/lib64/python3.6/site-packages/libdnf
rpm: error while loading shared libraries: liblua-5.3.so: cannot open shared object file: No such file or directory


[root@rhel8-31212 ~]# rpm -qf /usr/lib64/python3.6/site-packages/libdnf/error.py 
rpm: error while loading shared libraries: liblua-5.3.so: cannot open shared object file: No such file or directory
[root@rhel8-31212 ~]# rpm -qa | grep dnf
rpm: error while loading shared libraries: liblua-5.3.so: cannot open shared object file: No such file or directory


# find /usr/lib64/lua
find: ‘/usr/lib64/lua’: No such file or directory

Comment 1 Andrei Stepanov 2021-03-19 10:33:50 UTC
The module has its own version of lua:

https://mbs.engineering.redhat.com/module-build-service/1/module-builds/10375
lua-5.3.4-11.module+el8.4.0+10375+644ee9c3
https://brewweb.engineering.redhat.com/brew/taskinfo?taskID=35496756
Lua package from the module has:
/app/lib64/liblua-5.3.so <--- this is not the default place for shared libraries
Original path for this library is:
/usr/lib64/liblua-5.3.so

+ original lua was removed.

When this package is installed, the system becomes broken.

I would say this is a bug in the module. Or you should add /app/lib64 to /etc/ld.so.conf

I think this bug can be closed.

Comment 2 Panu Matilainen 2021-03-19 10:49:15 UTC
One could argue that modules should not be allowed to replace packages in the protected packages dependency chain.

Comment 3 Daniel Mach 2021-03-19 11:47:34 UTC
(In reply to Andrei Stepanov from comment #1)
> Lua package from the module has:
> /app/lib64/liblua-5.3.so <--- this is not the default place for shared libraries

Are you sure you're doing the right thing with using the module on a regular system?
Doesn't the /app path prefix indicate that the module build is meant for building a flatpack and nothing else?

Comment 4 Andrei Stepanov 2021-03-19 11:56:42 UTC
Daniel Mach hi.

brew list-history --build libreoffice-flatpak-8040020210317074620.cd723800
Thu Mar 18 12:39:58 2021 libreoffice-flatpak-8040020210317074620.cd723800 tagged into rhel-8.4.0-modules-gate by msg-tagger [still active]

I understand that his module is meant for usage as "flatpak".
This module was tagged into rhel-8.4.0-modules-gate tag.
This tag is for builds that follow RHEL-gating process.
Of course we can filter-out modules with "flatpak" stream.
OSCI team can do this by request from maintainer, and always give green light for "flatpak" stream.
Or, as for example, the maintainer can ask to configure MBS to tag "flatpak" modules to other Brew tag/target.

Comment 5 Jaroslav Mracek 2021-03-29 09:54:38 UTC
From the discussion I suggest that the issue is not in libdnf.

It looks like that the issue is related to liblua that is not compatible with the rest of the system.

[root@rhel8-31212 ~]# rpm -qf /usr/lib64/python3.6/site-packages/libdnf
rpm: error while loading shared libraries: liblua-5.3.so: cannot open shared object file: No such file or directory

I believe that module that provides the broken version of lua (`5.3.4-11.module+el8.4.0+10375+644ee9c3`) is a better component, but I don't see the package in RHEL8 distribution. I suggest that even lua component is not a proper component, but probably more related than libdnf.

Comment 6 Daniel Mach 2021-03-30 06:23:51 UTC
This cannot be fixed anywhere in lua, rpm stack or dnf stack.
The root cause is an incorrectly tagged module build in the build system.
Closing NOTABUG.

Please contact Martin Curlej if you want to propose any changes to modularity.


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