Bug 466996 - while updating, yum removed the currently booted kernel
Summary: while updating, yum removed the currently booted kernel
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Fedora
Classification: Fedora
Component: PackageKit
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Robin Norwood
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-10-15 00:25 UTC by Thomas J. Baker
Modified: 2014-01-21 23:06 UTC (History)
11 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2008-10-26 10:30:16 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Thomas J. Baker 2008-10-15 00:25:34 UTC
I've got a laptop following rawhide. During the transition to kernel 2.6.27, ext4dev got changed to ext4 and before this info was widely publicised, I had several kernels that wouldn't boot. I kept going back to booting a working older kernel. After the third 2.6.27 kernel update was installed, yum? removed the oldest and currently booted kernel, leaving me with an unbootable system.

I'm 99% sure that yum didn't used to do this, that the currently booted kernel was always one that was kept.

Comment 1 Thomas J. Baker 2008-10-15 00:29:19 UTC
Just thought I should add that it's possible that the last update where the booted kernel was removed could have been done through packagekit. I don't know if that matters since it ultimately operates through yum but maybe it does so at a lower level where it applies it's own logic?

Comment 2 James Antill 2008-10-15 02:55:15 UTC
Are you sure you were running it when it was removed?
What is installonly_limit set to?
Going to set to PK, unless something looks suspicious.

Comment 3 Richard Hughes 2008-10-15 07:23:28 UTC
Shouldn't be PK specific, PK just does a yum transaction.

Comment 4 Thomas J. Baker 2008-10-15 12:38:51 UTC
I'm positive given that the newer kernels wouldn't boot due to the ext4dev filesystem not being supported. I couldn't run the new kernels so I had to keep running the old one. After it was removed and my laptop no longer booted, I went digging and found that the ext4dev -> ext4 transition was the cause. I'll see if I can duplicate it. I'll boot the oldest kernel before the next new kernel update.

Comment 5 Yanko Kaneti 2008-10-15 14:26:00 UTC
I've had the same happen with plain rpm -Fhv *.rpm  in a dir which accidentally had a newer kernel rpm in it. I'd expect rpm not to remove the currently running kernel.

Comment 6 seth vidal 2008-10-15 14:27:44 UTC
Well rpm is going to remove the currently running kernel. rpm has no mechanisms included to stop itself from doing that.

Yum, otoh, has a bunch of code in place to keep it from doing that.

Comment 7 James Antill 2008-10-15 14:43:26 UTC
To expand on that: rpm -F does an _upgrade_ if you have those pacakges installed, upgrade means remove the installed version and install the new version.

yum upgrade kernel-<version>

...is more intelligent, because it knows kernels should only be installed and not upgraded (but then installonly_limit will then remove the old versions again, if configured to do so).
 RPM doesn't know any of this, and just does what you tell it to (one of many reasons not to use it directly).


 I don't see how the installonly_limit could make yum uninstall the running kernel though ... which is why I wondered if it was PK (or that a different kernel was running).

Comment 8 Thomas J. Baker 2008-10-15 14:55:21 UTC
On my system, installonly_limit=3, which I have never changed.

Comment 9 Thomas J. Baker 2008-10-22 15:30:00 UTC
I've tried and can't duplicate this. I'm not sure what combinations of things caused it but it at least doesn't happen regularly.

Comment 10 Richard Hughes 2008-10-26 10:30:16 UTC
Okay, if you can reproduce, then please reopen. Thanks.


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