Bug 1678596 - unable to install module content into nonstandard install root
Summary: unable to install module content into nonstandard install root
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: dnf
Version: 8.0
Hardware: Unspecified
OS: Unspecified
low
unspecified
Target Milestone: rc
: 8.0
Assignee: Jaroslav Mracek
QA Contact: Eva Mrakova
URL:
Whiteboard:
Depends On: 1681084
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-02-19 07:37 UTC by Martin Kyral
Modified: 2021-12-01 17:31 UTC (History)
8 users (show)

Fixed In Version: libdnf-0.33.0-1.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-11-05 22:21:13 UTC
Type: Bug
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2019:3583 0 None None None 2019-11-05 22:21:30 UTC

Description Martin Kyral 2019-02-19 07:37:10 UTC
Description of problem:

yum can't install modularized content into user specified install root because of missing /etc/os-release in the install root. IMO, the file shall be read from the standard location, if not found in the destination.

# yum --installroot=/var/tmp/tmp.FPC0jWdbj7 --nogpg install postgresql-server -y
Unable to detect release version (use '--releasever' to specify release version)
Updating Subscription Management repositories.
... 
Detection of Platform Module failed: Cannot open file: /var/tmp/tmp.FPC0jWdbj7/etc/os-release
Modular dependency problems:

 Problem 1: conflicting requests
  - nothing provides module(platform:el8) needed by module subversion:1.10:820181215112250:a51370e3-0.x86_64
 Problem 2: conflicting requests
  - nothing provides module(platform:el8) needed by module idm:client:820181214203528:49cc9d1b-0.x86_64
...
 Problem 40: conflicting requests
  - nothing provides module(platform:el8) needed by module perl-YAML:1.24:820181214175558:8652dbeb-0.x86_64
  - nothing provides module(platform:el8) needed by module perl-YAML:1.24:820181214175558:7c757546-0.x86_64
No match for argument: postgresql-server
Error: Unable to find a match
#

Installing of non-module components works as expected.

Version-Release number of selected component (if applicable):
dnf-4.0.9.2-5.el8

How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Workaround: copy /etc/os-release to the install root

Comment 1 Martin Kyral 2019-02-19 10:12:22 UTC
I was instructed that there is --setopt=module_platform_id=platform:el8 option allowing instalation of modularized content into install root. Tried, tested - it works. It is documented but the mention is hidden in the huge man page. So hint in case of this failure (similar to --allowerasing / --skip-broken hints in case of package transaction problem) could help a great deal and would be enough as a fix for this bug.

Comment 2 Jaroslav Mracek 2019-03-12 18:16:42 UTC
I created a patch (https://github.com/rpm-software-management/dnf/pull/1355) that provides a hint how to set up the platform module.

Comment 3 Jaroslav Mracek 2019-06-10 10:06:17 UTC
I believe that the issue is solved by changed detection of module_platform_id. Now it is taken from available package that provides a system-release.

Comment 7 Karel Srot 2019-08-21 14:23:04 UTC
(In reply to Jaroslav Mracek from comment #3)
> I believe that the issue is solved by changed detection of
> module_platform_id. Now it is taken from available package that provides a
> system-release.

Hi Jarda,
could you please provide more details on how this is supposed to work? Thank you.

Comment 8 Karel Srot 2019-08-21 14:38:17 UTC
Found the answer here https://github.com/rpm-software-management/libdnf/pull/712
However bug 1698942 is not fixed and thus the detection capabilities are limited.

Comment 10 errata-xmlrpc 2019-11-05 22:21:13 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, 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/RHSA-2019:3583


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