Score:-1

Grub can't find kernel when booting Lubuntu

in flag

I have an old PC I haven't used for about 10 years. It has Ubuntu 11.04 and Windows installed. I wanted to install Lubuntu on it and be able to use grub to choose what to boot into.

I installed Lubuntu 20.04 LTS and installation was fine. I have 3 disks on the PC and Ubuntu and Lubuntu are on /dev/sdc. When I first installed Lubuntu, there was no entry in grub for it. I then ran boot-repair and it added some entries. For example:

Ubuntu' --class ubuntu --class gnu-linux --class gnu --class os 'gnulinux-simple-xxxxxxxxxsome-guidxxxxxx (on dev/sda8)

When I tried to select the above, I get this:

error: file not found. error: you need to load the kernel first

I'm not sure what kind of diagnostic info would be helpful.

Edit: Ran sudo grub-mkconfig -o /boot/grub/grub.cfg.new and got the following output. Notice there is no new Linux kernel listed:

Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.38-10-generic
Found initrd image: /boot/initrd.img-2.6.38-10-generic
Found linux image: /boot/vmlinuz-2.6.35-22-generic
Found initrd image: /boot/initrd.img-2.6.35-22-generic
Found linux image: /boot/vmlinuz-2.6.32-24-generic
Found initrd image: /boot/initrd.img-2.6.32-24-generic
Found memtest86+ image: /boot/memtest86+.bin
Found Microsoft Windows XP Professional on /dev/sdc1
done
Score:-3
de flag
grub-mkconfig -o /boot/grub/grub.cfg

Update your grub file it should solve that issue.

in flag
boot ubuntu and run that command? I ran that command without update to see the output before but I didn't see it point to the Lubuntu partition. There might be some weird setup with my MBR that's causing this.
de flag
You need to use sudo first if you think it still not detected you can cat out to see the file try reinstalling grub or grub2.
in flag
I ran with sudo and here is the output. Notice the linux kernels are all really old: ```Generating grub.cfg ... Found linux image: /boot/vmlinuz-2.6.38-10-generic Found initrd image: /boot/initrd.img-2.6.38-10-generic Found linux image: /boot/vmlinuz-2.6.35-22-generic Found initrd image: /boot/initrd.img-2.6.35-22-generic Found linux image: /boot/vmlinuz-2.6.32-24-generic Found initrd image: /boot/initrd.img-2.6.32-24-generic Found memtest86+ image: /boot/memtest86+.bin Found Microsoft Windows XP Professional on /dev/sdc1 done ```
Someone avatar
my flag
If you're wondering what's happening with the votes: **Manually updating the GRUB files using `grub-mkconfig` are highly discouraged**, one should use the `sudo update-grub` command instead. Moreover, updating the GRUB files won't help in this case, so, your answer is incorrect and is downvoted as such.
in flag
Any suggestion as to how to fix it?
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.