Boot Menu in UEFI system

User discussion and information resource forum for scripting of TeraByte products using script lanugages such as TBScript, VBScript, Batch Files, and more.
Post Reply
Brian K
Posts: 1911
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Boot Menu in UEFI system

Post by Brian K »

I have multiple bootable partitions on HD1 (a GPT disk) which can be booted with this menu. See screenshot at the bottom of this post. Win10 is on HD0.

Menu.cmd is...

@echo off

CD /d F:\_AUTOrestoreUEFI\Boot_items

cls
echo.
echo Please Select From The Options Below:
echo.

echo 1. Boot Active @
echo 2. Boot EasyUEFI
echo 3. Boot IFL
echo 4. Boot Mint Cinnamon
echo 5. Boot PartWork
echo 6. Boot PESE
echo 7. Boot TBOSDT UEFI
echo 8. Boot TBWinPE
echo 9. Boot TBWinRE
echo A. Boot Windows Boot Manager
echo B. Exit


echo.
choice.exe /c 123456789ab /m "Your choice "
echo.


if errorlevel 11 goto Exit
if errorlevel 10 goto WBM
if errorlevel 9 goto TBWinRE
if errorlevel 8 goto TBWinPE
if errorlevel 7 goto TBOSDT
if errorlevel 6 goto PESE
if errorlevel 5 goto PartWork
if errorlevel 4 goto Mint
if errorlevel 3 goto IFL
if errorlevel 2 goto EasyUEFI
if errorlevel 1 goto Active


:Active
echo This is Active @
echo.
active.cmd

:EasyUEFI
echo This is EasyUEFI
echo.
EasyUEFI.cmd

:IFL
echo This is IFL
echo.
ifl.cmd

:Mint
echo This is Mint Cinnamon
echo.
mint.cmd

:PartWork
echo This is PartWork
echo.
partwork.cmd

:PESE
echo This is PESE
echo.
PESE.cmd

:TBOSDT
echo This is TBOSDT UEFI
echo.
tbosdt.cmd

:TBWinPE
echo This is TBWinPE
echo.
tbwinpe.cmd

:TBWinRE
echo This is TBWinRE
echo.
tbwinre.cmd

:WBM
echo This is Windows Boot Manager
echo.
wbm.cmd

:Exit
echo This is Exit
echo.
goto exitbatch

:exitbatch




tbwinpe.cmd is...

@echo off
CD /d %~dp0
set TBOSDT=C:\Program Files (x86)\TeraByte Drive Image Backup and Restore Suite\TeraByte OSD Tool Suite Pro\win
"%TBOSDT%\tbosdtw.exe" tbwinpe.run
echo.
shutdown -r -t 0



tbwinpe.run is...

set uefi bootnext 0x0008


The remaining scripts are variants of the above two scripts.


.
Attachments
MENU.PNG
MENU.PNG (12.63 KiB) Viewed 11191 times
Brian K
Posts: 1911
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: Boot Menu in UEFI system

Post by Brian K »

You can add other items to the menu. Such as IFW backups and IFL auto restores of the OS partition.
Eric
Posts: 212
Joined: Mon Sep 05, 2011 6:53 pm
Location: France

Re: Boot Menu in UEFI system

Post by Eric »

Why would this be needed? On my computer (if pressing F9) I can choose which partition (and even file) I want to boot.
Brian K
Posts: 1911
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: Boot Menu in UEFI system

Post by Brian K »

I previously used the UEFI BIOS Boot Menu too. This method does the same thing (boots the partition) but initiated from Windows. I find it's faster.
Brian K
Posts: 1911
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: Boot Menu in UEFI system

Post by Brian K »

The menu can include entries for offline auto-backups and auto-restores.
Yottabytes
Posts: 54
Joined: Fri Nov 22, 2013 2:50 pm

Re: Boot Menu in UEFI system

Post by Yottabytes »

I realize this topic is old and may not be monitored but are you saying it is possible to create a boot menu on a GPT disk with and IFL or IFW entry that will allow you to restore the window or linux partition on that very GPT disk? I've been doing this with an external USB disk as I thought it was impossible to intiate a recovery from the very disk you are trying to restore. However, I see your path is "F:\_AUTOrestoreUEFI\Boot_items". So can you walk me through this?
 ( ◥◣___◢◤)
(__つ/ ̄ ̄ ̄/
  \/   /
Do the math!
Brian K
Posts: 1911
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: Boot Menu in UEFI system

Post by Brian K »

Yottabytes wrote:
> I realize this topic is old and may not be monitored but are you saying it
> is possible to create a boot menu on a GPT disk with and IFL or IFW entry
> that will allow you to restore the window or linux partition on that very
> GPT disk? I've been doing this with an external USB disk as I thought it
> was impossible to intiate a recovery from the very disk you are trying to
> restore. However, I see your path is
> "F:\_AUTOrestoreUEFI\Boot_items". So can you walk me through
> this?

Yottabytes,

My original post has been superceded by BootIt UEFI.

Let's say you have 5 partitions on your GPT disk.

EFI System partition
MSR
Win 10
RE
Backup

You can create a backup image of the first 4 partitions and write the image to the Backup partition. The first 4 partitions can be restored from the image.

However, it's not a good idea to have the backup image on the same disk as the OS. If the disk fails you lose everything.
Yottabytes
Posts: 54
Joined: Fri Nov 22, 2013 2:50 pm

Re: Boot Menu in UEFI system

Post by Yottabytes »

So, if I had a Linux distro installed as your "Backup" partition, for instance, could I boot to that, run IFL and restore an offline image that overwrites the first three partitions? Or does Linux rely on some information in the system partition to boot properly after the changes are made?
 ( ◥◣___◢◤)
(__つ/ ̄ ̄ ̄/
  \/   /
Do the math!
Brian K
Posts: 1911
Joined: Fri Aug 12, 2011 1:11 am
Location: NSW, Australia

Re: Boot Menu in UEFI system

Post by Brian K »

Yottabytes wrote:
> So, if I had a Linux distro installed as your "Backup" partition,
> for instance, could I boot to that, run IFL and restore an offline image
> that overwrites the first three partitions? Or does Linux rely on some
> information in the system partition to boot properly after the changes are
> made?

Yes. From Linux you can restore any or all the first 4 partitions and from Windows you can restore the Linux partition.
Post Reply