Bug 1572950 - [PackageKit] ignores exclude directive in repo file
Summary: [PackageKit] ignores exclude directive in repo file
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: PackageKit
Version: 27
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Richard Hughes
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-04-29 07:06 UTC by Joachim Frieben
Modified: 2018-11-30 21:20 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2018-11-30 21:20:27 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Repo file for Fedora 27 updates (1.36 KB, text/plain)
2018-04-30 11:10 UTC, Joachim Frieben
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1440967 0 unspecified CLOSED PackageKit does not respect exclude parameter from repo file 2021-02-22 00:41:40 UTC

Internal Links: 1440967

Description Joachim Frieben 2018-04-29 07:06:55 UTC
Description of problem:
After having added "exclude=kernel*" to fedora-updates.repo, gnome-software continues to download, display, and install pending kernel updates.

Version-Release number of selected component (if applicable):
PackageKit-1.1.9-3.fc27

How reproducible:
Always

Steps to Reproduce:
1. Add "exclude=kernel*" to fedora-updates.repo.
2. Remove directory /var/cache/PackageKit/27.
3. Reboot system.

Actual results:
After searching for updates by means of gnome-software, pending kernel updates are listed.

Expected results:
After searching for updates by means of gnome-software, no pending kernel updates are listed.

Additional info:
- Running 'dnf list kernel' returns the correct result, namely no kernel updates are listed.
- This misbehaviour is even more annoying as gnome-software enforces that -all- pending updates be installed.

Comment 1 Rex Dieter 2018-04-29 11:37:46 UTC
Can you attach your edited fedora-updates.repo file?

Comment 2 Joachim Frieben 2018-04-29 12:13:02 UTC
The relevant section reads:

[updates]
name=Fedora $releasever - $basearch - Updates
failovermethod=priority
#baseurl=http://download.fedoraproject.org/pub/fedora/linux/updates/$releasever/$basearch/
metalink=https://mirrors.fedoraproject.org/metalink?repo=updates-released-f$releasever&arch=$basearch
enabled=1
repo_gpgcheck=0
type=rpm
gpgcheck=1
metadata_expire=6h
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-$releasever-$basearch
skip_if_unavailable=False
exclude=kernel*

Not that 'dnf list kernel' does not show any kernel update with this modification any longer.

Comment 3 Rex Dieter 2018-04-29 21:59:23 UTC
Please attach the whole thing

Comment 4 Joachim Frieben 2018-04-30 11:10:51 UTC
Created attachment 1428776 [details]
Repo file for Fedora 27 updates

Custom repo file for Fedora 27 updates with additional directive "exclude=kernel*"

Comment 5 Joachim Frieben 2018-04-30 11:15:45 UTC
Output of command 'dnf list 'kernel*'' for repo file attached in comment 4:

Last metadata expiration check: 0:19:51 ago on Sun 29 Apr 2018 12:45:38 PM CEST.
Installed Packages
kernel.x86_64                           4.15.16-300.fc27            @updates
kernel-core.x86_64                      4.15.16-300.fc27            @updates
kernel-modules.x86_64                   4.15.16-300.fc27            @updates
Available Packages
kernel-cross-headers.x86_64             4.13.9-300.fc27             fedora
kernel-debug.x86_64                     4.13.9-300.fc27             fedora
kernel-debug-core.x86_64                4.13.9-300.fc27             fedora
kernel-debug-devel.x86_64               4.13.9-300.fc27             fedora
kernel-debug-modules.x86_64             4.13.9-300.fc27             fedora
kernel-debug-modules-extra.x86_64       4.13.9-300.fc27             fedora
kernel-devel.x86_64                     4.13.9-300.fc27             fedora
kernel-headers.x86_64                   4.13.9-300.fc27             fedora
kernel-modules-extra.x86_64             4.13.9-300.fc27             fedora
kernel-rpm-macros.noarch                67-1.fc27                   fedora
kernel-tools.x86_64                     4.13.9-300.fc27             fedora
kernel-tools-libs.i686                  4.13.9-300.fc27             fedora
kernel-tools-libs.x86_64                4.13.9-300.fc27             fedora
kernel-tools-libs-devel.i686            4.13.9-300.fc27             fedora
kernel-tools-libs-devel.x86_64          4.13.9-300.fc27             fedora
kernelshark.x86_64                      2.6.1-3.fc27                fedora

Comment 6 Rex Dieter 2018-04-30 13:16:13 UTC
I cannot reproduce, at least not with PackageKit directly.  My test-case was using updates-testing (that I have enabled).

1.  sudo dnf update
...
 kernel                                          x86_64                            4.16.5-200.fc27                            updates-testing                              83 k

(cancel)

2.  pkcon get-updates
...
Available       kernel-4.16.5-200.fc27.x86_64 (updates-testing)                 The Linux kernel


3.  edit /etc/yum.repos.d/fedora-updates-testing.repo to add
exclude=kernel*

4.  pkcon refresh force

5.  sudo dnf update 
... nothing...

6.  pkcon get-updates
... nothing ...


I suspect the step missed for you may have been 4 ('pkcon refresh force'), to refresh PK cache/metadata... otherwise it may take waiting until your metadata cache expires.

Another possibility is that your issue is somehow gnome-software specific (but that's less likely)

Comment 7 Rex Dieter 2018-04-30 13:23:11 UTC

*** This bug has been marked as a duplicate of bug 1440967 ***

Comment 8 Joachim Frieben 2018-04-30 20:14:23 UTC
(In reply to Rex Dieter from comment #6)
The issue persists after installing today's updates including PackageKit-1.1.10-1.fc27 and rebooting the system:

$ dnf update
Last metadata expiration check: 0:09:37 ago on Mon Apr 30 21:44:42 2018.
Dependencies resolved.
Nothing to do.
Complete!

$ pkcon refresh force
$ pkcon get-updates
Getting updates               [=========================]
Querying                      [=========================]
Loading cache                 [=========================]
Finished                      [=========================]
Available       kernel-4.16.5-200.fc27.x86_64 (updates)                         The Linux kernel
Available       kernel-core-4.16.5-200.fc27.x86_64 (updates)                    The Linux kernel
Available       kernel-headers-4.16.5-200.fc27.x86_64 (updates)                 Header files for the Linux kernel for use by glibc
Available       kernel-modules-4.16.5-200.fc27.x86_64 (updates)                 kernel modules to match the core kernel

Comment 9 Joachim Frieben 2018-04-30 20:18:30 UTC
(In reply to Rex Dieter from comment #7)
This is not a duplicate of bug 1440967 since I had posted it deliberately and well aware of bug 1440967 for a -different- release, namely Fedora 27, which is in perfect agreement with the guidelines for bug reporting.

Comment 10 Rex Dieter 2018-04-30 20:31:23 UTC
Suit yourself, it's just going to be hard if this isn't readily reproducible :(

Comment 11 Joachim Frieben 2018-05-01 05:02:31 UTC
(In reply to Rex Dieter from comment #10)
Since kernel-4.16.5-200.fc27 was moved incidentally from updates-testing to updates just yesterday it seems likely that the varying delay in updating the mirror servers may be responsible of this seemingly erratic behaviour.
Currently, there is actually -no- kernel update in updates-testing. I therefore find your reported result not necessarily contradictory. You only get an unbiased result after disabling the mirror directive in fedora-updates.repo and fedora-updates-testing.repo and using https://dl.fedoraproject.org itself.

Comment 12 Ben Cotton 2018-11-27 15:56:53 UTC
This message is a reminder that Fedora 27 is nearing its end of life.
On 2018-Nov-30  Fedora will stop maintaining and issuing updates for
Fedora 27. It is Fedora's policy to close all bug reports from releases
that are no longer maintained. At that time this bug will be closed as
EOL if it remains open with a Fedora  'version' of '27'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 27 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 13 Ben Cotton 2018-11-30 21:20:27 UTC
Fedora 27 changed to end-of-life (EOL) status on 2018-11-30. Fedora 27 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


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