Created attachment 1272233 [details] dnf debug dir Description of problem: When doing a dnf update it fails with a message "The operation would result in removing the following protected packages: kernel" Version-Release number of selected component (if applicable): dnf-2.3.0-1.fc26.noarch How reproducible: 100% Steps to Reproduce: 1. dnf update (on my laptop) 2. 3. Actual results: Fails to update and gives ""The operation would result in removing the following protected packages: kernel" Expected results: Installation of the latest updates Additional info: Debug file attached Example: $ sudo dnf update --best Last metadata expiration check: 0:23:29 ago on Tue Apr 18 09:21:08 2017 CEST. Error: The operation would result in removing the following protected packages: kernel (try to add '--allowerasing' to command line to replace conflicting packages)
Please can you provide additional info: What is content of dnf.conf? What is running kernel? Is it the oldest one?
Hi I was using kernel-4.11.0-0.rc5.git0.1.fc26.x86_64 at the time Today I managed to get to rc7 by changing my dnf.conf to keep 5 ... # cat /etc/dnf/dnf.conf [main] gpgcheck=1 installonly_limit=5 clean_requirements_on_remove=True #installonlypkgs=electron #exclude=atom-* libgcrypt* I just changed it back to 3 and got the same error $ sudo dnf update Last metadata expiration check: 2:36:00 ago on Thu Apr 20 15:24:18 2017 CEST. Error: The operation would result in removing the following protected packages: kernel (try to add '--allowerasing' to command line to replace conflicting packages) $ uname -a Linux laptop.adrians.computer 4.11.0-0.rc7.git0.1.fc26.x86_64 #1 SMP Mon Apr 17 18:09:42 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux $ rpm -qa | grep ^kernel kernel-devel-4.11.0-0.rc7.git0.1.fc26.x86_64 kernel-4.11.0-0.rc5.git0.1.fc26.x86_64 kernel-modules-4.10.8-200.fc25.x86_64 kernel-4.11.0-0.rc7.git0.1.fc26.x86_64 kernel-modules-4.10.6-200.fc25.x86_64 kernel-4.10.8-200.fc25.x86_64 kernel-devel-4.11.0-0.rc5.git0.1.fc26.x86_64 kernel-devel-4.10.8-200.fc25.x86_64 kernel-core-4.10.8-200.fc25.x86_64 kernel-modules-4.11.0-0.rc7.git0.1.fc26.x86_64 kernel-core-4.10.6-200.fc25.x86_64 kernel-4.10.6-200.fc25.x86_64 kernel-devel-4.10.6-200.fc25.x86_64 kernel-modules-4.11.0-0.rc5.git0.1.fc26.x86_64 kernel-core-4.11.0-0.rc5.git0.1.fc26.x86_64 kernel-core-4.11.0-0.rc7.git0.1.fc26.x86_64 kernel-headers-4.11.0-0.rc7.git0.1.fc26.x86_64
Please can you perform "dnf remove kernel*-4.10.6-200.fc25.x86_64" ?
Is something obsoletes kernel? You can get it form "sudo dnf repoquery --whatobsoletes kernel".
You report the problem for "dnf update", please try "dnf update kernel", if update kernel works and general update doesn't please try to select problematic combination of packages.
$ sudo dnf remove kernel*-4.10.6-200.fc25.x86_64 Error: The operation would result in removing the following protected packages: kernel $ sudo dnf repoquery --whatobsoletes kernel Last metadata expiration check: 0:30:06 ago on Tue Apr 25 09:08:32 2017 CEST.
$ sudo dnf update kernel Last metadata expiration check: 0:30:58 ago on Tue Apr 25 09:08:32 2017 CEST. Error: The operation would result in removing the following protected packages: kernel (try to add '--allowerasing' to command line to replace conflicting packages)
Let's try something else. Please can you look for content in files /etc/yum/protected.d/*.conf and /etc/dnf/protected.d/*.conf . I have there only dnf, systemd, systemd-udev. I expect that you have additionally "kernel" there. If yes, removal of "kernel" entry will solve your problem. Also identification of the package that provided that entry would be interesting. Please, can you provide if this helped.
You are right, this is the output $ sudo ls /etc/yum/protected.d/*.conf /etc/yum/protected.d/sudo.conf /etc/yum/protected.d/systemd.conf $ sudo ls /etc/dnf/protected.d/*.conf /etc/dnf/protected.d/dnf.conf /etc/dnf/protected.d/kernel.conf I can check the fix you suggest at the moment as I dont have a kernel to upgrade (Ive been using rpm -e to erase them manually so I could update) Will update here once there is an update available, thanks for your help
I can confirm, removing the following file allowed me to update as normal /etc/dnf/protected.d/kernel.conf Happy to close this, many thanks
You are welcome.