0

I used clonezilla to create a clone on a USB drive of my Linux 22.04.1-Ubuntu SMP PREEMPT_DYNAMIC system that was booting directly from the embedded hard drive. This is for the purpose of having a backup drive in case my embedded HD craps out in some way.

For the most part I seemed to have achieved my goal with the drive cloned properly. As best I can tell when the USB drive is inserted I will boot from that drive with the /boot/efi mount pointing to the USB drive boot partition. If the USB drive is not installed at power up I will boot from the embedded HD (again as best I can tell).

As an aside to the main question is there a way to tell with certainty where a system booted from?

So the specific question I have for this group is there a more refined way to select where to boot from on power up. Below is some info and things I tried.

If I hold down "alt" while powering on with the USB inserted. I do enter Apples startup manager and I see both the SSD and the USB as options, but my selection seems to get overridden at some point and the USB is always used if inserted.

This overriding is the main thing I am trying to understand. I don't know if this overriding is something happening on the linux side or in apples startup manager. Note when using clonezilla to clone this disk I was able (and required) to use the startup manager to boot clonezilla from the USB.

As best I can tell I am using UEFI - not grub to boot, but being a bit of a noob I am not 100% sure of this and wonder if I am blind to some things the apple startup manager might be doing.

After booting from the embedded SSD the disks gui shows /dev/sda1 is mounted at /boot/efi it's UUID is 0C9A-DAC2 After booting from the USB the disks gui shows /dev/sdc1 is mounted at /boot/efi it's UUID is ALSO 0C9A-DAC2 In both cases the "Filesystem Root" points to the 2nd partition on the SSD (/dev/sda2). Separately I want to change this the file system root points to the 2nd partition on the same drive linux booted from.

Here is the efibootmgr output:

efibootmgr -v
BootCurrent: 0000
Timeout: 5 seconds
BootOrder: 0000,0080
Boot0000* ubuntu    HD(1,GPT,e54c74e0-6f0d-48af-acb9-fd0cbfbd6fc4,0x800,0x100000)/File(\EFI\ubuntu\shimx64.efi)
Boot0080* Mac OS X  PciRoot(0x0)/Pci(0x1,0x0)/Pci(0x0,0x0)/Sata(0,0,0)/HD(3,GPT,a765e1a0-b113-4e82-9e91-a7faa87ba393,0x1d250438,0x135f20)
Boot0082*   PciRoot(0x0)/Pci(0x1,0x0)/Pci(0x0,0x0)/Sata(0,0,0)/HD(3,GPT,a765e1a0-b113-4e82-9e91-a7faa87ba393,0x1d250438,0x135f20)

Perhaps this is extraneous to the primary question but I wanted to add that while trying to get clonezilla to boot from the USB I tried various efibootmgr commands to boot from the USB (e.g. adding a boot entry, setting boot-next, changing boot order, etc.).

None of those things worked. I always booted from the SSD until I used to the Apple startup manager to select the USB drive. So sometimes selecting via the startup manager does in fact work and is required.

Another side note this question probably has part of my answer but I wasn't able to fully understand it.

Thanks in advance for any help you can provide

andrew.46
  • 39,359

0 Answers0