Bug 23107 - System does not run the latest kernel
Summary: System does not run the latest kernel
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 6
Hardware: All Linux
Priority: Normal major
Target Milestone: ---
Assignee: Mageia Bug Squad
QA Contact:
URL:
Whiteboard:
Keywords: NEEDINFO
Depends on:
Blocks:
 
Reported: 2018-06-01 20:32 CEST by Gilles Allard
Modified: 2018-06-05 01:08 CEST (History)
3 users (show)

See Also:
Source RPM:
CVE:
Status comment:


Attachments

Description Gilles Allard 2018-06-01 20:32:10 CEST
Description of problem:
For the last 5 months, I've downloaded and installed 9 different releases of 4.14.kernel. All of them are still in /boot
I'm just discovering that I still use the 4.9 kernel (according to uname).
Is it possible that grub2 selects the latest kernel with an alphanumeric sort instead of a numeric sort?


Version-Release number of selected component (if applicable):
Mageia 6 (up-to-date)

How reproducible:


Steps to Reproduce:
1.
2.
3.
Comment 1 Marja Van Waes 2018-06-01 22:09:14 CEST
Hi Gilles,

This might be a duplicate of bug 22274 (drakboot proposes to set the oldest kernel as default). 

Do you remember whether you've ever adjusted bootloader settings in MCC (or directlly with drakboot) after you installed Mageia, or maybe already while you installed Mageia?

If you don't remember having adjusted such settings: which iso did you use to install Mageia?

Please give the output of

   grub2-editenv /boot/grub2/grubenv list

CC: sysadmin-bugs => marja11, zen25000
Component: Release (media or process) => RPM Packages
Keywords: (none) => NEEDINFO

Comment 2 Bit Twister 2018-06-02 00:39:20 CEST
Do keep in mind, Mageia grub2 setup is configured to boot the last booted selection as default.

You would need to pick the latest kernel from the menu and that will become the default boot.

As I misunderstand it, /boot/grub2/grubenv contains the information as to which selection is the default boot.

The recommended method for changing that files from the command line would be to use grub2-set-default whatever_wanted_here.

As I look through my /boot/grub2/grub.cfg 'Mageia (desktop) 6' will boot using linux16 /boot/vmlinuz-desktop  and initrd16 /boot/initrd-desktop.img which are links pointing to the latest installed desktop images.

In my stupid opinion, it looks like someone needs to create a script in /etc/grub.d/ to create a menu entry that boots /boot/vmlinuz /boot/initrd.img and have it as the first selection in the grub menu.

CC: (none) => bittwister2

Comment 3 Gilles Allard 2018-06-05 01:08:21 CEST
Marja (comment #1) and Bit Twister (comment #2) are both right.

/etc/default/grub contain 2 questionable statements:
GRUB_DEFAULT=saved
GRUB_SAVEDEFAULT=true

/boot/grub/grubenv (dated Aug 21 2017) contained a reference to kernel 4.9

I don't think I manually selected a kernel in last August but I just rebooted and noticed that "Advanced Options" line was highlighted. I selected the first line (Mageia6) and then, everything fixed itself. I'm now running 4.14.44
I suspect that, at that time, I accidentally selected the second line.

That means that for the last 10 months, I downloaded and installed many kernels, some of them being "security critical" and none of them was effective.
That's a security issue.

Thanks to those who answered.

Status: NEW => RESOLVED
Resolution: (none) => FIXED


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