kernel ....update to 5.15.0-60

And yet, it was there...in the form of /etc/default/grub.d/50_linuxmint.cfg

But do you still have a separate, stand alone

/etc/default/grub

?

If so, can you give me the content of

/etc/default/grub

and

/etc/default/grub.d/50_linuxmint.cfg

... on the pc which had the problems?

Ta.

Wiz
 


Ill get that infi for you in a tic....in the meantime, I think the piece in red tells most of the story


te@te-desktop:~$ sudo apt-get update && sudo apt-get dist-upgrade
Hit:1 http://ubuntu.mirror.serversaustralia.com.au/ubuntu jammy InRelease
Hit:2 http://ubuntu.mirror.serversaustralia.com.au/ubuntu jammy-updates InRelease
Hit:3 http://ubuntu.mirror.serversaustralia.com.au/ubuntu jammy-backports InRelease
Ign:4 https://mirror.aarnet.edu.au/pub/linuxmint-packages vera InRelease
Hit:5 https://mirror.aarnet.edu.au/pub/linuxmint-packages vera Release
Get:7 http://security.ubuntu.com/ubuntu jammy-security InRelease [110 kB]
Fetched 110 kB in 2s (52.9 kB/s)
Reading package lists... Done
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Calculating upgrade... Done
0 to upgrade, 0 to newly install, 0 to remove and 0 not to upgrade.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
Setting up grub-pc (2.06-2ubuntu7.1) ...
Sourcing file `/etc/default/grub'
Sourcing file `/etc/default/grub.d/50_linuxmint.cfg'
Sourcing file `/etc/default/grub.d/init-select.cfg'
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-5.15.0-60-generic
Found initrd image: /boot/initrd.img-5.15.0-60-generic
Found linux image: /boot/vmlinuz-5.15.0-58-generic
Found initrd image: /boot/initrd.img-5.15.0-58-generic
Found linux image: /boot/vmlinuz-5.15.0-56-generic
Found initrd image: /boot/initrd.img-5.15.0-56-generic
Warning: os-prober will be executed to detect other bootable partitions.
Its output will be used to detect bootable binaries on them and create new boot entries.
Adding boot menu entry for UEFI Firmware Settings ...
done
Setting up linux-image-5.15.0-60-generic (5.15.0-60.66) ...
Processing triggers for linux-image-5.15.0-60-generic (5.15.0-60.66) ...
/etc/kernel/postinst.d/dkms:

* dkms: running auto installation service for kernel 5.15.0-60-generic
...done.
/etc/kernel/postinst.d/initramfs-tools:
update-initramfs: Generating /boot/initrd.img-5.15.0-60-generic
/etc/kernel/postinst.d/zz-update-grub:
Sourcing file `/etc/default/grub'
Sourcing file `/etc/default/grub.d/50_linuxmint.cfg'
Sourcing file `/etc/default/grub.d/init-select.cfg'
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-5.15.0-60-generic
Found initrd image: /boot/initrd.img-5.15.0-60-generic
Found linux image: /boot/vmlinuz-5.15.0-58-generic
Found initrd image: /boot/initrd.img-5.15.0-58-generic
Found linux image: /boot/vmlinuz-5.15.0-56-generic
Found initrd image: /boot/initrd.img-5.15.0-56-generic
Warning: os-prober will be executed to detect other bootable partitions.
Its output will be used to detect bootable binaries on them and create new boot entries.
Adding boot menu entry for UEFI Firmware Settings ...
done
te@te-desktop:~$
 
/etc/default grub

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
# info -f grub -n 'Simple configuration'


GRUB_DEFAULT=0
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""


# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_RECOVERY="true"

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"

------------------------------------------------------------------------------------------------------------
/etc/default/grub.d/50_linuxmint.cfg

#! /bin/sh
set -e
# Set distributor to "Ubuntu"
#
# In Mint 16:
# shim and grub come with hardcoded ubuntu strings upstream, without this EFI installation is broken
# https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1242417
#
# In Mint 17:
# Despite the bug report being marked as fixed, the situation is the same. Grub was patched by Ubuntu
# to assign the "ubuntu" distributor ID when it was given "Kubuntu". That results in Kubuntu finally
# getting EFI to work out of the box but still using "ubuntu" as far as grub-install is concerned.
# So we'll stick to "Ubuntu" for this iteration.
#
# In Mint 18:
# Some packages are still hardcoded with the "ubuntu" path.. fwupdate for instance.
# Visually, the grub boot menuentry name is set for derivatives in 10_linux,
# but underneath the EFI path remains "ubuntu" for everything to work properly.
GRUB_DISABLE_OS_PROBER=false
GRUB_DEFAULT=0
GRUB_SAVEDEFAULT=true
GRUB_TIMEOUT_STYLE=menu
# Re-enable OS Prober
# Since Mint 21
# https://lists.gnu.org/archive/html/grub-devel/2021-03/msg00120.html
GRUB_DISABLE_OS_PROBER=false

(2 x Grub_disable os prober )
 
Cheers Mate, I'll put some content together and come back here either before knockoff or tomorrow.

Wiz
 
@Condobloke, Glad you could get it sorted out. Though it would be interesting to know happened to cause the problem with that file in the first place. Cheers!
 
That pc appears to be still behaving itself !

Damn good job, that was.
 
Though it would be interesting to know happened to cause the problem with that file in the first place.

Could be PEBKAC ;)

WIZARD’S GLOSSARY

Clem – Clement Lefebvre, CEO of Linux Mint
A pristine /etc/default/grub.d/50_linuxmint.cfg for Linux Mint 21.0 ‘Vanessa’ or 21.1 ‘Vera’ will look as follows

Code:
#! /bin/sh

set -e


# Set distributor to "Ubuntu"

#

# In Mint 16:

# shim and grub come with hardcoded ubuntu strings upstream, without this EFI installation is broken

# https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1242417

#

# In Mint 17:

# Despite the bug report being marked as fixed, the situation is the same. Grub was patched by Ubuntu

# to assign the "ubuntu" distributor ID when it was given "Kubuntu". That results in Kubuntu finally

# getting EFI to work out of the box but still using "ubuntu" as far as grub-install is concerned.

# So we'll stick to "Ubuntu" for this iteration.

#

# In Mint 18:

# Some packages are still hardcoded with the "ubuntu" path.. fwupdate for instance.

# Visually, the grub boot menuentry name is set for derivatives in 10_linux,

# but underneath the EFI path remains "ubuntu" for everything to work properly.


GRUB_DISTRIBUTOR="Ubuntu"


# Re-enable OS Prober

# Since Mint 21

# https://lists.gnu.org/archive/html/grub-devel/2021-03/msg00120.html

GRUB_DISABLE_OS_PROBER=false


This file is approaching 10 years old since it was first used. If you are into reading about bugs, or the warm milk and cookies is not getting you to sleep, you can take a wander over to the link above

https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1242417

and have a read.

This relates to before I started using Linux Mint. I came in at 17.0 ‘Qiana’.

Most of this file is cruft, but it is obviously low on the list of priorities for Clem’s team to clean up, so it remains as is and just gets added to from time to time.

The only part that matters would reduce it to what follows

Code:
#! /bin/sh

set -e

GRUB_DISTRIBUTOR="Ubuntu"

# Re-enable OS Prober

# Since Mint 21

# https://lists.gnu.org/archive/html/grub-devel/2021-03/msg00120.html

GRUB_DISABLE_OS_PROBER=false


So what is this file for?

In Mint, current versions, when we run

sudo update-grub

the first output we get is

Code:
Sourcing file `/etc/default/grub'

Sourcing file `/etc/default/grub.d/50_linuxmint.cfg'

Sourcing file `/etc/default/grub.d/init-select.cfg'

Generating grub configuration file …

and that grub configuration file is

/boot/grub/grub.cfg

A similar approach applies when we boot or reboot.

The file /etc/default/grub.d/init-select.cfg contains

Code:
# Work around a bug in the obsolete init-select package which broke

# grub-mkconfig when init-select was removed but not purged.  This file does

# nothing and will be removed in a later release.

#

# See:

#   https://bugs.debian.org/858528

#   https://bugs.debian.org/863801


… and those bugs related to Debian and were archived in 2017 and 2019 respectively.

So “This file does nothing and will be removed in a later release.” begs the question

When?

It is cruft, but don’t remove it, or /etc/default/grub.d/50_linuxmint.cfg without first taking a Timeshift snapshot.

Why keep that last-mentioned one?

The hyperlink in it,
https://lists.gnu.org/archive/html/grub-devel/2021-03/msg00120.html
details a security issue identified with the use of os-prober, but the suggested workaround is, I am afraid, geek speak. I might try it one day, after a Timeshift snapshot, of course. :)

IMPORTANT NOTE

At this point, I should tell you that the content of /etc/default/grub.d/50_linuxmint.cfg and, if it had anything useful in it, /etc/default/grub.d/init-select.cfg – if they have any entries that are similar already in /etc/default/grub , will take priority, or overwrite, what is in /etc/default/grub .

What does this mean, practically?

If you have this line in your /etc/default/grub

GRUB_DISABLE_PROBER=true

and we know that Clem and his merry men (and women, I hope) have the following in /etc/default/grub.d/50_linuxmint.cfg

GRUB_DISABLE_PROBER=false

then it is the one with “false” which will apply.

I will come back to wrap this up, hopefully in a brief fashion (they cheer) on my tomorrow.
In the meantime, I would suggest not editing /etc/default/grub.d/50_linuxmint.cfg
...until I wrap it up.

Cheers
Wizard
 
Last edited:
From your deleted post (you can run but you can't hide)

pebkac......you know better than that.

But do I? And I mean the following kindly, read on.

When you had the CPU problems (and that was on your PC, not Te's is that right?), you had this

https://www.linux.org/threads/cpu1-...ing-at-15-varying-with-load.43287/post-179227

and I thought at the time "What's he doing mucking about in 50_linuxmint.cfg? But did not pursue it.

Previously I said

A pristine /etc/default/grub.d/50_linuxmint.cfg for Linux Mint 21.0 ‘Vanessa’ or 21.1 ‘Vera’ will look as follows

It should be left pristine. User changes should be made to /etc/default/grub in nearly all cases. If you muck around with /etc/default/grub.d/50_linuxmint.cfg, or worse, with /boot/grub/grub.cfg and you are not an expert (even I leave grub.cfg alone, lol), you are inviting trouble.

Had you altered the content of Te's /etc/default/grub.d/50_linuxmint.cfg ?

Anyway, take a look at the following three screenshots, and then I'll advise. They relate to Vera Cinnamon.

First up, in /etc/default/grub.d/50_linuxmint.cfg, get rid of the duplicate line

GRUB_DISABLE_OS_PROBER=false

and put the other entries you added to the file, into /etc/default/grub and run

sudo update-grub.

Then

5HTwDNz.jpg


and

ttsaZ8U.jpg


and

xoVLfRi.jpg


So it's her top recovery mode entry, then drop to root shell and you end up at a prompt showing you are Root.

From there, issue the following commands, without sudo

Code:
grub-install /dev/sda #if that is where her root partition is, if not substitute
update-grub
reboot

Let us know how you go, on our tomorrow.

Cheers

Wiz
 
and I thought at the time "What's he doing mucking about in 50_linuxmint.cfg? But did not pursue it.
I had taken an exact copy ....and because things had not gone as I hoped....I did exactly what I said......I reset grub back to the below this afternoon.

Had you altered the content of Te's /etc/default/grub.d/50_linu
No....Te's remained as it was....untouched. The alarm bell rang when a black and white screen presented itself on her pc immediately ....on first boot after being installed.....press f2 for this F11 for blah blah etc etc........and none of those f2's or esc or F11 had any effect whatsoever. I probably did nothing to help it after that (hindsight).....I screwed around royally trying to get all to behave.......whatever...the rest is history.

The pc's are on opposite sides of the room ...so I will forward this to Te's pc and open it there......save a bit of shoe leather and screwing around.

Edit to Add: It is entirely possible I screwed up grub......in my alacrity to get the rotten thing behaving in a normal manner......I pulled all sorts of stuff off the net in my (misguided) efforts. In fact no 'guidance' at al....I simply followed my nose !


In the end I copied the grubs etc from my pc...to Te's pc...and it worked !!!...beautifully !
It may not follow boofheads definition of 'pristine'.....but it worked.

The outcome below still does not appear to be correct (to me)

there are two grub_default_=0....in etc/default/grub.....it will be gone shortly....te is on her pc....if not tonight, then early tomorrow morning.
early rise tomorrow morning....4am......off to the snooze sack for me.
 
Last edited:
From the Recovery Mode....Install for x89_64-efi platform
Installed Fine....no errors

below is a copy and paste after reboot/after fix/after update-grub



etc/default/grub....after fix

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
# For full documentation of the options in this file, see:
# info -f grub -n 'Simple configuration'


GRUB_DEFAULT=0
GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""
GRUB_DISABLE_OS_PROBER=false
GRUB_DEFAULT=0
GRUB_SAVEDEFAULT=true
GRUB_TIMEOUT_STYLE=menu


# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"

# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console

# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480

# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_RECOVERY="true"

# Uncomment to get a beep at grub start
#GRUB_INIT_TUNE="480 440 1"
------------------------------------------------------------------------
----------------------------------------------------------------------
50_linuxmint.cfg after fix etc

#! /bin/sh
set -e

# Set distributor to "Ubuntu"
#
# In Mint 16:
# shim and grub come with hardcoded ubuntu strings upstream, without this EFI installation is broken
# https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1242417
#
# In Mint 17:
# Despite the bug report being marked as fixed, the situation is the same. Grub was patched by Ubuntu
# to assign the "ubuntu" distributor ID when it was given "Kubuntu". That results in Kubuntu finally
# getting EFI to work out of the box but still using "ubuntu" as far as grub-install is concerned.
# So we'll stick to "Ubuntu" for this iteration.
#
# In Mint 18:
# Some packages are still hardcoded with the "ubuntu" path.. fwupdate for instance.
# Visually, the grub boot menuentry name is set for derivatives in 10_linux,
# but underneath the EFI path remains "ubuntu" for everything to work properly.

GRUB_DISABLE_OS_PROBER=false
GRUB_DEFAULT=0
GRUB_SAVEDEFAULT=true
GRUB_TIMEOUT_STYLE=menu


# Re-enable OS Prober
# Since Mint 21
# https://lists.gnu.org/archive/html/grub-devel/2021-03/msg00120.html

back in 10....tea time

Tomorrow, I will clean this up a bit.
 
Last edited:
both 'grub' files are below......etc/default/grub is the first
(the asterisks are mine to ensure I got it right.)

GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""
GRUB_DISABLE_OS_PROBER=false *****
GRUB_DEFAULT=0 *****
GRUB_SAVEDEFAULT=true ******
GRUB_TIMEOUT_STYLE=menu *******

.cfg

GRUB_DISABLE_OS_PROBER=false *****
GRUB_DEFAULT=0 ******
GRUB_SAVEDEFAULT=true ******
GRUB_TIMEOUT_STYLE=menu *******



THEREFORE

/etc/default/grub has 4 lines that .cfg does not have:

GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX=""
 
Interestingly, I disabled fast boot. This had the effect of making f11 work to display a menu where I can boot from a usb stick again.

When I initially installed LM21.1 I was able to display that menu....but not since. (until now)
 
Two (2) errors on my part that I need to correct (and have with one, so far):

1. In #27, the bottom line in /etc/default/grub.d/50_linuxmint.cfg should read (the way Clem's team have done it)

Code:
GRUB_DISABLE_OS_PROBER=false

I have edited it to the correct "pristine" form. I had modified mine to shorten upgrade times for kernel and grub and I was quoting from that. Regret the confusion.

2. Also in that Post I had

The file /etc/default/grub.d/init-select.cfg contains...

This is actually not Mint's fault but that of Ubuntu, and persists up to and including Ubuntu 22.10 '\Kinetic Kudu' and likely for the foreseeable future unless the Ubuntu team place a priority on it.

That is not likely, because they already have a line in /etc/default/grub which has been obsolete for years, and goes back nearly 10 years.

That is

Code:
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`

This goes back to when Linux Distros had to identify themselves to Microsoft in order to be installed on a computer that was using Windows, in the early days of UEFI.

Mint have the correct line in 50_linuxmint.cfg, where it says

Code:
GRUB_DISTRIBUTOR="Ubuntu"

... which, as it will, overrides the obsolete line in /etc/default/grub

Brian, I note from #23 that you do not have that line in Te's 50_linuxmint.cfg - that might account for how you got the duplicate (red lines)
GRUB_DISABLE_OS_PROBER=false

(2 x Grub_disable os prober )

if you or some other process altered that.

It would not cause any problems with the kernel anomalies, but perhaps it needs to be addressed.

On kernels:

With 5.15.0-60., if all is in working order both on your computer and with the copied grub contents to Te, you might just choose to leave it for now and see how they go. If it ain't broke and so on.

Other than that, you can get a newer, 5.19.0-28 kernel through the Updater.

It doesn't appear yet in the list of Updates themselves, but if you use the Kernels function you can install it. I have on my Vera Xfce so far, and it seems to work fine.

Other than that, I don't think I have any further to add, and I have likely already hijacked your Thread long enough, regrets. :oops:

Of course, if you have any questions on the above, fire away.

Wiz
 
All good.
I am typing this from Te's pc.
This thing is running like a charm.
I made the necessary alterations etc
I am aware of kernel 5.19.........however, 5.15.0-60 is running so well I will leave it alone......both on Te's pc and also on mine.

I certainly didn't regard my thread as hijacked...all good solid, sound advice...as always.

Brian
 

Members online


Latest posts

Top