Page 1 of 1

[SOLVED] Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 21st, '24, 22:43
by Garthhh
I had backed up my content by simply copying to an external drive [hdd1] formatted exfat
I accidentally left the usb plugged in & restarted [bios is set to boot usb 1st], did a hard shutdown
Unplugged usb, restarted, no boot loader sends me to CLI.

Plugged in a different usb3 nvme with Mageia installed, works fine, been using it for weeks
Can I use the Mageia install to fix/reinstall the Manjaro Grub?
I have trouble following the Manjaro/arch instructions, as they are written in coder speak [cli], not GUI speak

Made a backup of my content on a hdd2 formated btrfs using grsync, works fine
I would like to update Manjaro & give plasma 6 a spin

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 22nd, '24, 00:15
by doktor5000
Garthhh wrote:I had backed up my content by simply copying to an external drive [hdd1] formatted exfat
I accidentally left the usb plugged in & restarted [bios is set to boot usb 1st], did a hard shutdown
Unplugged usb, restarted, no boot loader

Sorry but that sounds quite confusing, can you please rephrase that ?
Simply plugging in an USB stick, copying stuff on it and unplugging it will do exactly nothing to your installed bootloader.

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 22nd, '24, 02:40
by xgrind
Do you want to use Mageia to restore Manjaro's grub? Have you asked on the Manjaro forum?
What error message are you getting?

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 22nd, '24, 04:56
by Garthhh
doktor5000 wrote:
Garthhh wrote:I had backed up my content by simply copying to an external drive [hdd1] formatted exfat
I accidentally left the usb plugged in & restarted [bios is set to boot usb 1st], did a hard shutdown
Unplugged usb, restarted, no boot loader

Sorry but that sounds quite confusing, can you please rephrase that ?
Simply plugging in an USB stick, copying stuff on it and unplugging it will do exactly nothing to your installed bootloader.

Starting laptop with the exfat formated hdd plugged in made the start up fail, I don't remember the exact sequence, I probably did a hard shut down after being met with a CLI prompt [see images]. Unplugged the usb, tried to start, got a prompt to check journal, which yielded many pages which I can't decipher
I'm assuming that since the computer won't boot the boot loader is broken/missing
I look forward to the day it's built into the kernel...

Here's what Manjaro says, what Mageia says for errors
https://photos.app.goo.gl/dZd5gR2yzktxtRyG6

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 22nd, '24, 08:41
by sturmvogel
Did you already check the UEFI/Bios boot order?

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 22nd, '24, 09:20
by benmc
Garthhh wrote:Can I use the Mageia install to fix/reinstall the Manjaro Grub?

probably not, unless you are very familiar with chrooting a system.

I take it the first text photo is a non-booting Mageia, the 2nd text photo is implied Manjaro non-boot.
The first image, as you dont know the root password, does make it difficult to fix. [ login incorrect ]
With care, you could possibly boot the 2nd image by editing the the grub text, but you would need to know the kernel and partition parameters.
press "e" at the grub selection screen, as displayed at the bottom of the screen.

I would suggest trying to fix the Manjaro first, from within Manjaro, making sure it is fully bootable.
Asyou have backed everything up, probably a complete reinstall and update.
If the installs are on separate devices, remove the Mageia device.

then, remove the Manjaro device and reconnect the Mageia device.
then use the Mageia boot stick to fix the Mageia install.
when it is fully bootable, move on to the next steps below.

this way both systems have their own bootloaders on their own devices.
then reconnect the other device.

if UEFI, you can use a boot hotkey to select the device and boot.
you could then update grub in both systems, this should add each other system to each bootlaoder.

If not separate devices, I would still suggest fixing Manjaro first.
I have read many times elsewhere that the Manjaro installer is not multi-boot friendly.

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 22nd, '24, 09:36
by benmc
Garthhh wrote:I would like to update Manjaro & give plasma 6 a spin


Why not fire up a Virtualbox machine and install cauldron ?
Currently running kernel 6.6.39-1.mga10.
Plasma version is 6.1.2-1, i.e.; latest.

A virtual machine, depending on your hardware ( and mine is old ) should perform as nearly bare metal install.

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 23rd, '24, 16:52
by doktor5000
Garthhh wrote:Starting laptop with the exfat formated hdd plugged in made the start up fail, I don't remember the exact sequence, I probably did a hard shut down after being met with a CLI prompt [see images]. Unplugged the usb, tried to start, got a prompt to check journal, which yielded many pages which I can't decipher
I'm assuming that since the computer won't boot the boot loader is broken/missing

If you get a prompt to check the journal which happens when you boot into maintenance/recovery mode, you are already past the bootloader and that is the initrd from the running system.
So from your description bootloader is not your issue.

You probably only need to run fsck -y on all your filesystems that are in /etc/fstab - that should fix the issue you described and shown on the first screenshot where it seems you logged in and then just pressed Ctrl+D which won't help.

For the Manjaro boot error on the third screenshot, that can also be fixed but you need to find out why the filename manually.
This can be done from the grub2 shell as that supports basic commands for file access, see e.g.
https://www.linuxfoundation.org/blog/bl ... 2-on-linux (see the GRUB 2 Command Shell section).

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 28th, '24, 19:04
by Garthhh
benmc wrote:
Garthhh wrote:I would like to update Manjaro & give plasma 6 a spin


Why not fire up a Virtualbox machine and install cauldron ?
Currently running kernel 6.6.39-1.mga10.
Plasma version is 6.1.2-1, i.e.; latest.

A virtual machine, depending on your hardware ( and mine is old ) should perform as nearly bare metal install.

I have no skill with virtual machines, seeming to spend more time learning vb than actually using whatever I'm trying to test, the result is about like running live, nearly functional
I usually just install whatever I want to test on an external drive

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 28th, '24, 19:06
by Garthhh
sturmvogel wrote:Did you already check the UEFI/Bios boot order?

Using legacy, the boot order makes no difference, no manjaro grub found

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 28th, '24, 19:06
by Garthhh
benmc wrote:
Garthhh wrote:Can I use the Mageia install to fix/reinstall the Manjaro Grub?

probably not, unless you are very familiar with chrooting a system.

I take it the first text photo is a non-booting Mageia, the 2nd text photo is implied Manjaro non-boot.
The first image, as you dont know the root password, does make it difficult to fix. [ login incorrect ]
With care, you could possibly boot the 2nd image by editing the the grub text, but you would need to know the kernel and partition parameters.
press "e" at the grub selection screen, as displayed at the bottom of the screen.

I would suggest trying to fix the Manjaro first, from within Manjaro, making sure it is fully bootable.
Asyou have backed everything up, probably a complete reinstall and update.
If the installs are on separate devices, remove the Mageia device.

then, remove the Manjaro device and reconnect the Mageia device.
then use the Mageia boot stick to fix the Mageia install.
when it is fully bootable, move on to the next steps below.

this way both systems have their own bootloaders on their own devices.
then reconnect the other device.

if UEFI, you can use a boot hotkey to select the device and boot.
you could then update grub in both systems, this should add each other system to each bootlaoder.

If not separate devices, I would still suggest fixing Manjaro first.
I have read many times elsewhere that the Manjaro installer is not multi-boot friendly.


I have several different distros each on their own external nvme/sdd/hdd, each is a full install, bios is set to legacy, boot order usb 1st
I can't get dualboots on the same drive to work consistently
The external dual boot is more reliable

The 1st image is manjaro not booting
The 2nd image is the mageia boot screen, showing a manjaro entry
3rd image is the result of trying to boot the manjaro entry

I'm running mageia through an external nvme plugged into usb3, boots right up, everything works, no problems other than having only one usb port & a convoluted path to my files
The main nvme installed in the laptop has the wounded manjaro install & all of my content

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 28th, '24, 20:03
by Garthhh
doktor5000 wrote:
You probably only need to run fsck -y on all your filesystems that are in /etc/fstab - that should fix the issue you described and shown on the first screenshot where it seems you logged in and then just pressed Ctrl+D which won't help.

For the Manjaro boot error on the third screenshot, that can also be fixed but you need to find out why the filename manually.
This can be done from the grub2 shell as that supports basic commands for file access, see e.g.
https://www.linuxfoundation.org/blog/bl ... 2-on-linux (see the GRUB 2 Command Shell section).


OK , getting closer
I don't find a file fstab in either systems ect, I don't understand what you are directing me to do with fsck -y command?

On your 2nd suggestion I don't understand
"For the Manjaro boot error on the third screenshot, that can also be fixed but you need to find out why the filename manually."

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Jul 29th, '24, 16:58
by doktor5000
Garthhh wrote:I don't find a file fstab in either systems ect, I don't understand what you are directing me to do with fsck -y command?

fsck is short and also the command for a filesystem check (including repairs).
You need to run fsck -y on every of your Mageia filesystem that shows errors during boot, as the one on your first screenshot.

Garthhh wrote:On your 2nd suggestion I don't understand
"For the Manjaro boot error on the third screenshot, that can also be fixed but you need to find out why the filename manually."

Not sure which part you don't understand. Your Mageia grub does not find the file that is referenced for the Manjaro entries.
There can be multiple reasons, either it has a different name or the filesystem is broken or not accessible.
Both can be fixed.

Re: Repairing missing Grub on Manjaro dual boot

PostPosted: Aug 3rd, '24, 20:31
by Garthhh
Thanks for the replies