Grub error after installing Qubes 4.2 on external SSD

Hello. Friend asked me to install the Qubes system on an external drive, I had the test version 4.2 rc.1 and it was an error. After the installation, the grub of My Qubes was corrupted on my PC and after installation it did not work what i show later.

After reinstalling on external SSD to stable version 4.1.2, Qubes already works on his external disk but now my is damaged.
When boot i have this announcement :
error : no such device ( and here number id … this external disk not mine )
error : unknow filesystem
grub resc

whats goin on ?

please help I need it quickly my qubes.

Read this:

I read it and honestly I don’t understand much, so I know it’s not a random error, but with other systems, mainly Fedora, there has never been a problem, so I didn’t check it before installation.

I don’t have access to dom0 here, only have grub rescue
because If i understand correctly that these names need to be changed there (or should it be done before install Qubes on external drive )? :

Copy files from /boot/efi/EFI/qubes/ to /boot/efi/EFI/BOOT/

sudo cp -r /boot/efi/EFI/qubes/* /boot/efi/EFI/BOOT/

Change filename grubx64.efi → BOOTX64.efi.

sudo mv /boot/efi/EFI/BOOT/grubx64.efi /boot/efi/EFI/BOOT/BOOTX64.efi

Change filename grub.cfg → BOOTX64.cfg

sudo mv /boot/efi/EFI/BOOT/grub.cfg /boot/efi/EFI/BOOT/BOOTX64.cfg

can do it from the qubes terminal on an external drive ? it seems that in my case it will be sda1 which has 1 GB sda2 is the main qubes partition (but i see it havent /boot like for sda1 like it is on sdb1 1GB (external drive with qubes) , but how to choose the purpose so that the changes are only on the sda1 partition, what should I enter in the terminal earlier… isn’t that the point? or maybe i should reinstall grub but the same question how do it step by step from cli for this case

Do you have Qubes OS installed using UEFI or Legacy BIOS mode?
If it’s UEFI and assuming your Qubes OS drive is sda then sda1 should be EFI System partition, sda2 should be boot partition and sda3 should be main Qubes OS partition.
You can boot from any LiveUSB OS or from Qubes OS installed, mount your Qubes OS EFI System partition (sda1) there and add the required changes.

This is the Legacy BIOS mode, so the disk of my Qubes is SDA and there are only two partitions :
sda1 1GB (without mountpoint like : /boot) and sda2 main partition 500GB

I’ve read more or less on the forums but I don’t want to screw anything up so as not to have another problem to fix, so if you would be so kind as to tell me in such a scenario that I’m already on the live USB system, I run the terminal and what next?

The issues that I linked are only applicable for the EFI systems so that problem is not the issue that you’re facing.

You can try to fix up your like this:
First boot into any LiveUSB OS or in Qubes OS installer, mount your system (either manually or automatically if you’re booting from Qubes OS installer in rescue mode), chroot into it and then fix grub config:

sudo mount --bind /dev/sdY /mnt/boot when enter this command : mount point does not exist

Did this command succeed?

sudo mount /dev/sdX /mnt

Where /dev/sdX is your Qubes OS main partition /dev/sdb2 if /dev/sdb is your Qubes OS drive.
You can check the Qubes OS disk name using output of this command:

sudo fdisk -l

Did this command succeed?

sudo mount /dev/sdX /mnt

Yes i have info
mount: /mnt: /dev/sda1 already mounted on /run/media/user/(someting numbers)

sudo fdisk -l
yes i know that sda1 i boot partition and sda2 main parition Qubes

but next command sudo mount --bind /dev/sda1 /mnt/boot when enter this command : mount point does not exist

Is there a typo and it should be /dev/sda2?

Try it like this

sudo umount /run/media/user/(someting numbers)
sudo mount /dev/sda2 /mnt
sudo mount /dev/sda1 /mnt/boot

I previously tried to run it from another disk with fedora39 from grub like “Windows 10” (dev/sda1) and :
error …/…/grub-core.commands/search.c.315:no such device: (number like 6857ED75 etc.)
setting partition type to 0x83
error: …/…grub-core/loader/i386/pc/chainloader.c213: invalid signature

I’m tired of this … do you see this program boot-repair-disk / Home / Home like live usb as a quicker alternative to fixing this?

But is it safe ( For BIOS ? ) Do you know this program? Thanks for your answers, I appreciate it

replying to your post
sudo mount /dev/sda2 /mnt :
mount: /mnt: special device /dev/sda2 does not exist.

sudo mount /dev/sda1 /mnt/boot :
mount: /mnt/boot : mount point does not exist

It won’t work.

You’ve said before that:

Change sda to some other drive name, e.g. sdb if it’s the correct Qubes OS drive name.

Still these errors.Looks like I won’t do anything about it anymore, it’s really screw up, it’s a shame to waste your time and you’ve sacrificed so much, thanks

it seems like the only thing left is to decrypt the disk, copy it to another one and reinstall the system … ?

Okay, someone tell me if it makes sense and is possible to create an image of an encrypted disk with Qubes, then reinstall cleanly Qubes and then replace the new partitions with this created image. Will this work well ?
Because I don’t consider it safe to copy all from a decrypted disk to another (used) USB and do it on new Qubes.

It’s possible but for it to work you’ll need to change the UUIDs of your encrypted disk, dom0 root and boot partitions in dom0 root and boot partition configs and have the same kernel boot files (initramfs, vmlinuz) in old boot partition that you have in new Qubes dom0.