Bug 1928056

Summary: [dnf-nightly copr] PackageKit crashes in dnf_context_get_installonly_pkgs
Product: [Fedora] Fedora Reporter: Martin Pitt <mpitt>
Component: dnfAssignee: Jaroslav Rohel <jrohel>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 33CC: dmach, jmracek, jrohel, mblaha, mhatina, packaging-team-maint, pkratoch, rpm-software-management, vmukhame
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: dnf-4.7.0-1.fc33 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-02-16 05:22:35 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 Martin Pitt 2021-02-12 09:43:12 UTC
In cockpit we regularly (~ twice a week) run our integration tests against fedora-33 with updates-testing and the rpmsoftwaremanagement/dnf-nightly COPR.

Today's fedora-testing refresh [1] with the nightly dnf copr has found a regression [2]: PackageKit now crashes, as can be seen in e.g. this journal [3]:

| PackageKit[2178]: uid 0 is trying to obtain org.freedesktop.packagekit.system-sources-refresh auth (only_trusted:0)
| PackageKit[2178]: uid 0 obtained auth for org.freedesktop.packagekit.system-sources-refresh
| PackageKit[2178]: refresh-cache transaction /1_bbbaddbd from uid 0 finished with success after 510ms
| PackageKit[2178]: get-updates transaction /2_deceaaad from uid 0 finished with success after 161ms
| PackageKit[2178]: get-update-detail transaction /3_aabcbcee from uid 0 finished with success after 115ms
| PackageKit[2178]: uid 0 is trying to obtain org.freedesktop.packagekit.package-install-untrusted auth (only_trusted:0)
| PackageKit[2178]: new update-packages transaction /5_becbebce scheduled from uid 0
| PackageKit[2178]: uid 0 obtained auth for org.freedesktop.packagekit.package-install-untrusted
| Process 2178 (packagekitd) of user 0 dumped core.
| Stack trace of thread 2215:
| #0  0x00007f67c4471d5f dnf_context_get_installonly_pkgs (libdnf.so.2 + 0x88d5f)
| #1  0x00007f67c4482db2 dnf_package_is_installonly (libdnf.so.2 + 0x99db2)
| #2  0x00007f67c45f0187 pk_backend_update_packages_thread (libpk_backend_dnf.so + 0xf187)
| #3  0x0000556c41ef9e8e pk_backend_job_thread_setup (packagekitd + 0x27e8e)
| #4  0x00007f67d40b53c2 g_thread_proxy (libglib-2.0.so.0 + 0x813c2)
| #5  0x00007f67d39723f9 start_thread (libpthread.so.0 + 0x93f9)
| #6  0x00007f67d3b05b53 __clone (libc.so.6 + 0x101b53)

[1] https://github.com/cockpit-project/bots/pull/1668
[2] https://logs.cockpit-project.org/logs/pull-1668-20210212-024200-87704894-fedora-testing-dnf-copr-cockpit-project-cockpit/log.html
[3]
+https://logs.cockpit-project.org/logs/pull-1668-20210212-024200-87704894-fedora-testing-dnf-copr-cockpit-project-cockpit/TestAutoUpdatesInstall-testUnsupported-fed
+ora-testing-127.0.0.2-2401-FAIL.log.gz



Version-Release number of selected component (if applicable):

 createrepo_c               x86_64  0.17.0-1.fc33             copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   72 k
 createrepo_c-libs          x86_64  0.17.0-1.fc33             copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   99 k
 dnf                        noarch  4.6.0-17g960e6ecd.fc33    copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly  431 k
 dnf-automatic              noarch  4.6.0-17g960e6ecd.fc33    copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   28 k
 dnf-data                   noarch  4.6.0-17g960e6ecd.fc33    copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   32 k
 dnf-plugins-core           noarch  4.0.19-2gfa0c8b7.fc33     copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   30 k
 dnf-utils                  noarch  4.0.19-2gfa0c8b7.fc33     copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   33 k
 drpm                       x86_64  0.5.0-3g6f82bd6.fc33      copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   62 k
 libcomps                   x86_64  0.1.15-7g16b3f64.fc33     copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   78 k
 libdnf                     x86_64  0.59.0-0.14gbd68ed95.fc33 copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly  618 k
 libmodulemd                x86_64  2.12.0-1g83f7924.fc33     copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly  229 k
 librepo                    x86_64  1.13.0-2g199e6d3.fc33     copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   95 k
 python3-dnf                noarch  4.6.0-17g960e6ecd.fc33    copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly  399 k
 python3-dnf-plugins-core   noarch  4.0.19-2gfa0c8b7.fc33     copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly  192 k
 python3-hawkey             x86_64  0.59.0-0.14gbd68ed95.fc33 copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly  101 k
 python3-libcomps           x86_64  0.1.15-7g16b3f64.fc33     copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   47 k
 python3-libdnf             x86_64  0.59.0-0.14gbd68ed95.fc33 copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly  774 k
 python3-librepo            x86_64  1.13.0-2g199e6d3.fc33     copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   48 k
 yum                        noarch  4.6.0-17g960e6ecd.fc33    copr:copr.fedorainfracloud.org:rpmsoftwaremanagement:dnf-nightly   29 k

Comment 1 Jaroslav Rohel 2021-02-12 18:06:49 UTC
Fixed PR https://github.com/rpm-software-management/libdnf/pull/1142

Comment 2 Martin Pitt 2021-02-16 05:22:35 UTC
Thanks! Last night's run was happy again:

https://logs.cockpit-project.org/logs/pull-1682-20210216-023358-26d4618f-fedora-testing-dnf-copr-cockpit-project-cockpit/log.html

This was with 4.6.0-20g6e91824b.fc33 .

Comment 3 Fedora Update System 2021-04-19 16:12:58 UTC
FEDORA-2021-447fb19490 has been submitted as an update to Fedora 33. https://bodhi.fedoraproject.org/updates/FEDORA-2021-447fb19490

Comment 4 Fedora Update System 2021-04-19 18:33:46 UTC
FEDORA-2021-447fb19490 has been pushed to the Fedora 33 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-447fb19490`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-447fb19490

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 5 Fedora Update System 2021-05-03 01:48:24 UTC
FEDORA-2021-447fb19490 has been pushed to the Fedora 33 stable repository.
If problem still persists, please make note of it in this bug report.