Bug 1576594

Summary: dnf debuginfo-install ignores out of date debuginfo packages
Product: [Fedora] Fedora Reporter: Lyude <lyude>
Component: dnf-plugins-coreAssignee: Jaroslav Mracek <jmracek>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 28CC: dmach, jmracek, mhatina, packaging-team-maint, rpm-software-management, vmukhame
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-06-28 08:32:51 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Lyude 2018-05-09 21:18:59 UTC
Description of problem:
Occasionally when trying to use dnf debuginfo-install, debuginfo-install seems to assume debuginfo packages are installed for their respective packages, even if the debuginfo package is for an older version of it's respective package and not the currently installed version. For example:

➜  ~ dnf list installed libinput
enabling updates-debuginfo repository
enabling fedora-debuginfo repository
enabling rpmfusion-free-updates-debuginfo repository
enabling rpmfusion-free-debuginfo repository
enabling rpmfusion-nonfree-updates-debuginfo repository
enabling rpmfusion-nonfree-debuginfo repository
Installed Packages
libinput.x86_64                                  1.10.6-1.fc28                                   @updates
➜  ~ dnf list installed libinput-debuginfo
enabling updates-debuginfo repository
enabling fedora-debuginfo repository
enabling rpmfusion-free-updates-debuginfo repository
enabling rpmfusion-free-debuginfo repository
enabling rpmfusion-nonfree-updates-debuginfo repository
enabling rpmfusion-nonfree-debuginfo repository
Installed Packages
libinput-debuginfo.x86_64                         1.10.4-1.fc28                         @fedora-debuginfo
➜  ~ dnf debuginfo-install -y libinput  
enabling updates-debuginfo repository
enabling fedora-debuginfo repository
enabling rpmfusion-free-updates-debuginfo repository
enabling rpmfusion-free-debuginfo repository
enabling rpmfusion-nonfree-updates-debuginfo repository
enabling rpmfusion-nonfree-debuginfo repository
Last metadata expiration check: 1:01:27 ago on Wed 09 May 2018 04:12:40 PM EDT.
Package libinput-debuginfo-1.10.4-1.fc28.x86_64 is already installed, skipping.
Dependencies resolved.
Nothing to do.
Complete!


Version-Release number of selected component (if applicable):
2.7.5-12.fc28

How reproducible:
Very

Steps to Reproduce:
1. Install a ton of debuginfo packages
2. Keep the machine up to date
3. Eventually (I'm not sure how long, but it can't be very long seeing as it's happening on just about every fedora machine I have) once the packages you installed debuginfo for update, some of them will eventually stop getting picked up as requiring an update when running dnf debuginfo-install

Comment 1 Jaroslav Mracek 2018-05-17 12:01:33 UTC
I believe that following info from documentation can help you:

-------------
Configuration
-------------

``/etc/dnf/plugins/debuginfo-install.conf``

The minimal content of conf file should contain ``main`` sections with ``enabled`` and
``autoupdate`` parameter.

``autoupdate``
    A boolean option which controls updates of debuginfo packages. If options is enabled
    and there are debuginfo packages installed it automatically enables all configured
    debuginfo repositories.
    (Disabled by default.)

Comment 2 Lyude 2018-05-17 16:20:20 UTC
(In reply to Jaroslav Mracek from comment #1)
> I believe that following info from documentation can help you:
> 
> -------------
> Configuration
> -------------
> 
> ``/etc/dnf/plugins/debuginfo-install.conf``
> 
> The minimal content of conf file should contain ``main`` sections with
> ``enabled`` and
> ``autoupdate`` parameter.
> 
> ``autoupdate``
>     A boolean option which controls updates of debuginfo packages. If
> options is enabled
>     and there are debuginfo packages installed it automatically enables all
> configured
>     debuginfo repositories.
>     (Disabled by default.)

Unfortunately that's not really the problem here though. Autoupdate handles updating debuginfo packages when the rest of the system is updated, but if the user doesn't have this enabled then there is no way of manually updating the currently installed debuginfo packages, even if you run dnf debuginfo-install on said packages with out of date debug information. You have to go through, remove all of the debuginfo packages, then reinstall them.

This seems like a bug since a lot of applications on fedora suggest dnf debuginfo-install when they can't find required debug information (such as gdb), coupled with the fact that there isn't actually any other way to update debuginfo packages other then changing your debuginfo config file and updating the whole system.

Comment 3 Jaroslav Mracek 2018-05-17 17:47:36 UTC
What about work around:

sudo dnf upgrade --enablerepo=*-debuginfo libinput-debuginfo

or 

sudo dnf upgrade --enablerepo=*-debuginfo "*-debuginfo"

Comment 4 Lyude 2018-05-18 18:35:02 UTC
gah-it appears I am having trouble reproducing this on any of my machines right now, I'm going to leave auto updating of debuginfo on them disabled and hopefully get back to you the next time I see this bug occur

Comment 5 Jaroslav Mracek 2018-05-24 15:21:45 UTC
I improved a documentation for debuginfo-install https://github.com/rpm-software-management/dnf-plugins-core/pull/266. Hope that it solves your problem completely.

Comment 6 Jaroslav Mracek 2018-06-28 08:32:51 UTC
The issue is solved by dnf-plugins-core-3.0.1-1 that was released into rawhide.