Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-16580

DNF fails on modular repo with a different architecture

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Minor Minor
    • None
    • rhel-9.3.0.z
    • libdnf
    • None
    • Impediment
    • Low
    • FutureFeature
    • rhel-sst-cs-software-management
    • ssg_core_services
    • 5
    • Dev nak
    • True
    • Hide

      None

      Show
      None
    • Yes
    • Red Hat Enterprise Linux
    • None
    • Hide

      AC: On system with enabled modular repository of different architecture than the system itself, upon calling dnf module enable, dnf informs user clearly that the repository architecture doesn't match the system architecture.

      Test: to be written according to AC.

      Show
      AC: On system with enabled modular repository of different architecture than the system itself, upon calling dnf module enable, dnf informs user clearly that the repository architecture doesn't match the system architecture. Test: to be written according to AC.
    • None
    • None
    • Bug Fix
    • Hide
      Cause (the user action or circumstances that trigger the bug):
      User tries to enable a module with an architecture incompatible with their system

      Consequence (what the user experience is when the bug occurs):
      DNF errors with an unhelpful message, e.g. "Problem: nothing provides requested module(...)"

      Fix (what has changed to fix the bug; do not include overly technical details):
      `module enable` now explicitly requests to install one of the packages provided by the module, which results in a more helpful error message.

      Result (what happens now that the patch is applied):
      The error message now mentions the architecture incompatibility, e.g.
      "module ... from ... does not have a compatible architecture".
      Show
      Cause (the user action or circumstances that trigger the bug): User tries to enable a module with an architecture incompatible with their system Consequence (what the user experience is when the bug occurs): DNF errors with an unhelpful message, e.g. "Problem: nothing provides requested module(...)" Fix (what has changed to fix the bug; do not include overly technical details): `module enable` now explicitly requests to install one of the packages provided by the module, which results in a more helpful error message. Result (what happens now that the patch is applied): The error message now mentions the architecture incompatibility, e.g. "module ... from ... does not have a compatible architecture".
    • Proposed
    • All
    • None

       

      What were you trying to do that didn't work?

      In order to install a custom flavour of PHP (from "Remi's repos"), customer "reposynced" the repo in question on its Satellite server, in a repo named "rhel-php-latest". He was not able to install the 'php:<stream_wanted>' DNF module after following the upstream (3rd party) instructions, which were absolutely standard ('module reset php' then 'module enable <module>'). The error was absolutely not self-explanatory, and we, the support, were hiding behind the fact it's a 3rd party.

      Into practice, the customer synchronized the repo for a wrong architecture (aarch64 instead of x86_64), leading to this misleading error. Checking what modules provide for 'php' finally put us on the good track ('dnf module provides php').

      Setting the severity as Minor, since the issue is likely very rare.

      Please provide the package NVR for which bug is seen:

      dnf-4.7.0-16.el8_8.noarch

      libsolv-0.7.20-4.el8_7.x86_64

      How reproducible:

      Always

      Steps to reproduce

      • Setup the below repositories on an x86_64 system
        https://rpms.remirepo.net/enterprise/8/remi/aarch64
        https://rpms.remirepo.net/enterprise/8/modular/aarch64
      • Run the following commands to enable a given php flavour:
        # dnf module reset php
        # dnf module enable php:remi-7.4
        

        Expected results

      Something like this to put the user on the right track:

      - module XXX does not have a compatible architecture
      - nothing provides ld-linux-aarch64.so.1(GLIBC_2.17)(64bit) needed by php-7.4.33-9.el8.remi.aarch64
      

      Actual results

      # dnf module enable php:remi-7.4
       :
      Modular dependency problem: Problem: nothing provides requested module(composer:2:20231113181904)
      Error: Problems in request:
      Modular dependency problems: 
       Problem 1: nothing provides requested module(composer:2:20231113181904)
       Problem 2: nothing provides requested module(php:remi-7.4:20231113181904) 

              rh-ee-egoode Evan Goode
              rhn-support-cbesson Christophe Besson
              packaging-team-maint packaging-team-maint
              Software Management QE Software Management QE
              Mariya Pershina Mariya Pershina
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: