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

running dnf clean packages breaks dnf install from URI

Linking RHIVOS CVEs to...Migration: Automation ...SWIFT: POC ConversionSync from "Extern...XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Normal Normal
    • rhel-9.8
    • CentOS Stream 9
    • dnf
    • No
    • None
    • rhel-swm
    • ssg_core_services
    • None
    • Dev ack
    • False
    • False
    • Hide

      None

      Show
      None
    • Yes
    • None
    • Hide

      AC: dnf clean packages doesn't break concurent run of dnf install from URI.

      Show
      AC: dnf clean packages doesn't break concurent run of dnf install from URI.
    • None
    • None
    • Bug Fix
    • Hide
      Cause:
      Consequence:
      Fix:
      Result:
      Show
      Cause: Consequence: Fix: Result:
    • Proposed
    • Unspecified
    • Unspecified
    • Unspecified
    • None

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

      It looks like it's possible to run {{dnf clean packages }}while a DNF is downloading a package from a URI; this will result in the transaction failing because the package suddenly disappears.

      What is the impact of this issue to you?

      We hit this on multiple production systems where dnf clean packages is periodically run by configuration management, and this happened to overlap with a dnf install <URI> operation.

      Please provide the package NVR for which the bug is seen:

      dnf-4.14.0-25.el9.noarch

      How reproducible is this bug?:

      always

      Steps to reproduce

      1. mock -r centos-stream-9-aarch64 --install dnf tmux
      2. mock -r centos-stream-9-aarch64 --shell --enable-network
      3. run tmux, make two panes
      4. in pane 1, run dnf install https://kojihub.stream.centos.org/kojifiles/packages/kernel/5.14.0/571.el9/aarch64/kernel-5.14.0-571.el9.aarch64.rpm https://kojihub.stream.centos.org/kojifiles/packages/kernel/5.14.0/571.el9/aarch64/kernel-core-5.14.0-571.el9.aarch64.rpm https://kojihub.stream.centos.org/kojifiles/packages/kernel/5.14.0/571.el9/aarch64/kernel-modules-core-5.14.0-571.el9.aarch64.rpm
      5. wait for the download to start, then in pane 2 run dnf clean packages
      6. observe the failure (either Can not load RPM file or Could not open) depending on timing)

      Expected results

      The install should probably lock the cache, and dnf clean packages should wait until the lock is cleared (which shouldn't happen until the transaction is completed).

      Actual results

      either Can not load RPM file or Could not open depending on timing

              packaging-team-maint packaging-team-maint
              dcavalca Davide Cavalca
              packaging-team-maint packaging-team-maint
              Software Management QE Software Management QE
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: