How to boot from an EUFI original or clone Linux partition

User discussion and information resource forum for BootIt Bare Metal and BootIt UEFI
brucebne
Posts: 159
Joined: Sat Jan 19, 2019 11:01 am

Re: How to boot from an EUFI original or clone Linux partiti

Post by brucebne »

Thanks for the heads up on hiding partitions.
I've only trialled BIU for 2 weeks, and I recall the partition hide function was more obvious in BING BIBM.

Re copy speed, the super slow rate happens on a Dell Latitude and Lenovo Yoga. Both have M.2 PCIe SSDs
If imaging is super fast, it would seem logical there is a coding solution.
Brian K
Posts: 2229
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: How to boot from an EUFI original or clone Linux partiti

Post by Brian K »

Bruce,

In Partition Work you can copy partitions. Copy/Paste buttons. For Microsoft OS there is a box, "Add to Boot Menu". This creates a Boot Item and edits the BCD so the copied OS boots without any editing. It would be nice to be able to do something similar with a Linux OS.

A few days ago you were concerned about /dev/sdax order changing. If desired, you can edit /dev/sdax numbers easily with the Reorder GPT button in Partition Work. I keep my partitions numbered as they appear on the disk.
brucebne
Posts: 159
Joined: Sat Jan 19, 2019 11:01 am

Re: How to boot from an EUFI original or clone Linux partiti

Post by brucebne »

Brian K wrote:
> Bruce,
>
> In Partition Work you can copy partitions. Copy/Paste buttons. For
> Microsoft OS there is a box, "Add to Boot Menu". This creates a
> Boot Item and edits the BCD so the copied OS boots without any editing. It
> would be nice to be able to do something similar with a Linux OS.
>

yes agree this is the parsimonious path for BIU to evolve.


> A few days ago you were concerned about /dev/sdax order changing. If
> desired, you can edit /dev/sdax numbers easily with the Reorder GPT button
> in Partition Work. I keep my partitions numbered as they appear on the
> disk.

My view is once a partition has been allocated in my case a /dev/nvme0nXpX number, it should not change based after adding/subtracting/moving partitions.
Why?
because some programs hard code addresses via /devs.
Though this is an issue of GPT, not BIU.
Brian K
Posts: 2229
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: How to boot from an EUFI original or clone Linux partiti

Post by Brian K »

I've made a second copy of Mint 19.1 (2 clones and the original). This one is ubuntu.112.

My cryptic notes have been updated...

create ubuntu.111 (using Paul's lines)
boot ifl flash drive
copy the linux partition
terminal
blkid
maximize screen if needed (to see all partitions eg /dev/nvme1n1p20)
e2fsck -vfy /dev/nvme1n1p20
uuidgen
mouse copy uuid
tune2fs /dev/nvme1n1p20 -U f0acce91-a416-474c-8a8c-43f3ed3768f9 (uuid is copy/pasted from uuidgen) use mouse, not ctrl-c
wait, don't press y
leave terminal open
mount p20 as mnt1
mount esp as mnt2
editor
file, open file
tbu/mnt1/etc/fstab
delete the uuid in fstab
mouse copy the new uuid in terminal
ctrl-v it into fstab
file, save file
file, exit
editor
file, open file
tbu/mnt1/boot/grub/grub.cfg
search, replace
paste the new UUID in Replace before copy/paste the old uuid from the text
replace all
file, save file
file, exit
editor
file, open file
/tbu/mnt2/EFI/ubuntu.111/grub.cfg
delete the uuid in grub.cfg
mouse copy the new uuid from the terminal again
ctrl-v it into grub.cfg
delete the extra space (if created) after the uuid (single press of delete)
file, save file
file, exit
close terminal
reboot
create boot item from ubuntu.111
boot ubuntu.111
sudo update-grub (probably not necessary)
brucebne
Posts: 159
Joined: Sat Jan 19, 2019 11:01 am

Re: How to boot from an EUFI original or clone Linux partiti

Post by brucebne »

Brian K wrote:
> I've made a second copy of Mint 19.1 (2 clones and the original). This one
> is ubuntu.112.
>
> My cryptic notes have been updated...
>
> blkid
> maximize screen if needed (to see all partitions eg /dev/nvme1n1p20)
> e2fsck -vfy /dev/nvme1n1p20
> uuidgen
> mouse copy uuid
> tune2fs /dev/nvme1n1p20 -U f0acce91-a416-474c-8a8c-43f3ed3768f9 (uuid is
> copy/pasted from uuidgen) use mouse, not ctrl-c
> wait, don't press y



I didn't realize you could paste any uuid to a partition.
I presume that means if for any reason a partition's uuid is changed by some operation, it can be restored to its original.

I follow your process above, and that's pretty cool that you can do all the edits within BIU.

What I used to aim for when I had an IT business was to auto-update the backup bootable OS partition, say once a month.
I'll have to have a look at BIU's autorun script features....and how regular cloning can avoid changes to clone OS's uuid.
brucebne
Posts: 159
Joined: Sat Jan 19, 2019 11:01 am

Re: How to boot from an EUFI original or clone Linux partiti

Post by brucebne »

I just had a go at creating a bootable Linux Mint clone on the Lenovo Yoga 720 (the one with the Linux unfriendly BIOS!!!

and....the whole operation done and dusted in ~10 minutes.

- I thought I'd done BIU copy operations on this laptop before, and they'd been slow like the Dell....but I must have been mistaken, as the BIU copy/paste of the 8/15GB Mint partition was as fast as imaging, around 20 seconds!
(I must trial booting in UEFI vs LEGACY mode to see if that makes a difference to BIU copy speed on the DELL).

- I then followed the rest of the process, and no glitches whatsoever.

- btw, unlike with the Dell laptop, this time when I created an EFI/boot/ubuntu.001 folder (and changed UUID to the new one), then rebooted, BIU made a new boot menu item automatically, which booted into the new OS partition....and the original boot menu item continued to boot into the original partition.
(The boot menu items reversed the OS partitions they booted with the Dell (maybe because I used /ubuntu.002/ before changing to *.001.)

OK....that was very satisfying to finally have some sense of control over UEFI:GPT partition operations and booting.

Brian, I'll have to try your process via a bootable IFL USB stick. Might save me a few reboots.
Brian K
Posts: 2229
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: How to boot from an EUFI original or clone Linux partiti

Post by Brian K »

I copied Mint 19.1 to a different SSD in the computer. No problems.

Total time from starting to create ubuntu.113 to finishing the Boot Edit was 13 minutes. You are faster.

I don't have the Boot Item created for me. When creating the ubuntu partition in EFI do you use this...

md ubuntu

or

md ubuntu.xxx
brucebne
Posts: 159
Joined: Sat Jan 19, 2019 11:01 am

Re: How to boot from an EUFI original or clone Linux partiti

Post by brucebne »

Brian K wrote:
> I copied Mint 19.1 to a different SSD in the computer. No problems.
>
> Total time from starting to create ubuntu.113 to finishing the Boot Edit
> was 13 minutes. You are faster.
>
> I don't have the Boot Item created for me. When creating the ubuntu
> partition in EFI do you use this...
>
> md ubuntu
>
> or
>
> md ubuntu.xxx


I do everything in Mint = In Nemo file manager, mouse click copy/paste
that creates "ubuntu (copy)"
then I rename it "ubuntu.00x"



Re speed, I may have

- smaller partitions

- faster ssd
M.2 NVMe PCIe

- faster laptop
Intel Core i7-7500U CPU @ 2.70GHz, 2 Core(s)
16GB RAM

- I did the operation from BIU installed. You did from IFL on a stick AFAIK.


When I woke up this morning I experimented with resizing Mint OS from 15 to 20GB.
So using BIU, I copied a partition to free space, then resized.
The e2fsck operation corrected partiton parameters I presume, then when I tried to do tune2fs, I got a request for another another e2fsck operation, which was clear.
hmm... then I had issues booting into the original and clone.
BIU would pass me to a grub command line.

I got lazy, downloaded and applied 'boot-repair', which got the clone working.
Will mess with it more later today.
But I don't learn anything using boot-repair.


I also recall you saying when you do a copy/paste operation in BIU, you get an option to create a boot menu item (at least for windows 10).
I don't get that on the Mint OS partitions.
Brian K
Posts: 2229
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: How to boot from an EUFI original or clone Linux partiti

Post by Brian K »

Bruce,

It was lucky I used IFL. I tried doing it from another Mint installation and couldn't access the ESP or edit fstab or grub.cfg. They were read only. How did you do it?
brucebne
Posts: 159
Joined: Sat Jan 19, 2019 11:01 am

Re: How to boot from an EUFI original or clone Linux partiti

Post by brucebne »

Brian K wrote:
> Bruce,
>
> It was lucky I used IFL. I tried doing it from another Mint installation
> and couldn't access the ESP or edit fstab or grub.cfg. They were read only.
> How did you do it?

- I boot the partition I want to make changes to fstab (or if unable to do that, use a Mint usb stick)
- then run 'disks' and mount ESP, and if necessary the relevant Mint OS /root
- then open terminal "sudo nemo"
which should
show ESP and allow editing of /boot/EFI/efi/boot/ubuntu.00x/grub.cfg
and Mint OS root and allow editing of /root/etc/fstab
Post Reply