I am very new to Ubuntu and in learning phase. I was a windows user before and switched to Ubuntu for my work. Currently, I have Ubuntu 22.04.1 LTS with Linux 5.15.0-52-generic. I want to add another Linux kernel alongside the stated one. It is Linux 4.10.0-28-generic. I want to have both of these kernels in Ubuntu and at the system reboot, I shall select the desired one. Please help me how to do this. I am not very familiar much with the platform and command line so pardon me if this question is too basic (because for me, it is not)
Asked
Active
Viewed 776 times
0
-
1Please state why you need to boot an old kernel. Perhaps the best option would be to run a legacy system in a Virtual Machine. – Artur Meinild Nov 18 '22 at 10:14
1 Answers
0
You can install the desired kernel from the terminal (accessed by Ctrl+Alt+T) using sudo apt install linux-image-4.10.0-28-generic
, and you can reorder the bootloader menu by using grub customizer which you can install by sudo apt install grub-customizer
, but even without that, the new kernel should be added to the menu automatically after installation.

Troy
- 51
-
Thank you for your answer Troy. Do I need to download the said kernel version before? Because it is giving me this error. E: Unable to locate package linux-image-4.10.0-28-generic E: Couldn't find any package by glob 'linux-image-4.10.0-28-generic' – Maryam Nov 18 '22 at 18:59
-
@Maryam This is because you're trying to install a 17.04 kernel on a 22.10 Ubuntu, and the package is obsolete. As seen packages.ubuntu.com, the oldest available kernel is that of 18.04. Older releases are at http://old-releases.ubuntu.com/ubuntu/. These are discontinued and have to be manually installed, but I highly suggest you don't, since changing the kernel can cause issues. There is an answer at https://askubuntu.com/questions/700214/how-do-i-install-an-old-kernel#785194 which links to the community wiki page at https://wiki.ubuntu.com/Kernel/MainlineBuilds. – Troy Nov 18 '22 at 19:24
-
@Maryam Also, why install an outdated kernel? Why not use it in a Virtual Machine? I forgot to mention it at first, but to answer "Do I need to download the said kernel version before?": the error you got means that the package itself is unavailable to fetch and install, not unavailable on your system. – Troy Nov 18 '22 at 19:25
-
Your answers are very helpful. Actually, I am trying to run Flush+Reload attack on my machine. And the code is for kernel 4.10.0-28 generic. It is not extracting meaningful keys on my latest linux kernel. – Maryam Nov 19 '22 at 12:17