1

My setup before: SSD-1 containing windows 10 with all of its recovery etc. partitions SSD-2 empty HDD-1 containing ubuntu 20.04 root directory + grub partition HDD-2 containing /home directory, which I mounted

My goal: SSD-1: as is SSD-2: ubuntu root + grub HDD-1: format for windows HDD-2: leave as is

What I did: 1. Copied the ubuntu root partition to SSD-2 using the bash script found here: Bash script to backkup/clone Ubuntu to another partition -> this seemingly worked after adding /home/* to --exclude={/dev/,/proc/,/sys/,/tmp/,/run/,/mnt/,/media/*,/lost+found}

  1. After rebooting, the root directory was on the desired SSD and my /home was still mounting correctly. At this point nothing seems to be broken.

  2. I decided (in my infinite wisdom) that since it seems to work without the old root directory being mounted, that I could delete its data, which left me in the following state.

SSD-1 Windows 10 SSD-2 Ubuntu root HDD-1 grub partition (old root was deleted here) HDD-2 Ubuntu /home

  1. Now on reboot I get the grub error message: error: no such device: 2f09eae6-...-...-...-... error: unknown filesystem. Entering rescue mode... grub rescue>

I would like to have my grub on the same SSD as my root directory and I would prefer if it worked again :). I have tried using my Ubuntu live USB to perform the steps described here Boot error > no such device: grub rescue, but ran into this GPT partition contains no BIOS Boot Partition.

I think I am going at this issue in the wrong way, what would be the correct approach. Is reinstalling ubuntu and then somehow mounting my root and /home the correct approach?

Thanks for any help that I receive!

  • Sounds like a legacy install (on a DOS partitioned disk), was copied to a GPT parttioned disk, so no room between partitions for the bootloader blobs. What mode was Windows installed in (if it was on a DOS partitioned disk, that would be legacy)? Do you have UEFI/CSM (legacy) choices in your BIOS (implying a UEFI capable machine)? – ubfan1 Jun 3 at 15:33
  • @ubfan1 Yes I have UEFI options in my BIOS. I am not sure in which mode Windows was installed, how can I check this? – RedDead54 Jun 3 at 15:55
  • Add a tiny (2MB) partition flagged bios-grub to your GPT partitioned disk, and you may then install grub in legacy mode. Windows on GPT disk is UEFI, on DOS legacy. – ubfan1 Jun 3 at 16:29
  • @ubfan1 Just to be sure, using my USB live Ubuntu, I should use GParted/CLI to partition the SSD that contains the copied root directory? Is there anything I should pay attention to when installing grub? Thanks for the help – RedDead54 Jun 3 at 16:33
  • I've checked using sudo fdisk -l and you were correct I copied from a dos to a gpt drive. – RedDead54 Jun 3 at 16:36
0

Boot the system from an installer live session. Mount the existing system partition and use a text editor (nano from a terminal works fine) to take a look at the file:

/boot/efi/EFI/ubuntu/grub.cfg

It's a small file...mine is 117 bytes. Make sure the search.fs_uuid value is correct for your root partition. Change if necessary (might have to use sudo to get permissions), then save the file, back out of the live session and reboot the machine.

| improve this answer | |
  • It seems that I do not have this file. @rbmorse I booted from USB and mounted my root drive to /home/ubuntu/temp. Then I navigated to /home/ubuntu/temp/boot, which does not contain an efi directory. boot contains a grub folder, config-...-generic versions, initrd-...-generic versions and some vmlinuz stuff. – RedDead54 Jun 3 at 16:10
  • I do however have grub.cfg in the boot/grub folder – RedDead54 Jun 3 at 16:12
  • @RedDead54 Did your approach work – David Kariuki Jun 3 at 18:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.