Score:0

Headless Ubuntu 20.04 change default Kernel

ps flag

I agree this question had been asked before. I have tried one of them and I lost the connection so to be sure I am asking again.

I have a headless server which I can connect to only with SSH. After apt upgrade I realized that the new kernel can't work with our virtualization solution.

current kernel:

uname -r
5.4.0-137-generic

now I have to turn back to

5.4.0-121-generic.

sudo grub-mkconfig | grep -iE "menuentry 'Ubuntu, with Linux" | awk '{print i++ " : "$1, $2, $3, $4, $5, $6, $7}'

0 : menuentry 'Ubuntu, with Linux 5.4.0-137-generic' --class ubuntu
1 : menuentry 'Ubuntu, with Linux 5.4.0-137-generic (recovery mode)'
2 : menuentry 'Ubuntu, with Linux 5.4.0-121-generic' --class ubuntu
3 : menuentry 'Ubuntu, with Linux 5.4.0-121-generic (recovery mode)'

I have followed this one before

"modified GRUB_DEFAULT="1>2" value in /etc/default/grub executed below command to regenerate a grub config file with modified GRUB_DEFAULT settings."

update-grub
reboot

I could not access to my server again. This one is the second server with the same configuration and to be honest I am scared if things may happen again.

I need your help. What is the safest method to bypass 137 and automatically boot from 121 after reboot.

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.