Solved UEFI boot on Q1900-ITX

jcassette

Cadet
Joined
Nov 18, 2021
Messages
6
Hello

I wanted to share how I finally managed to boot TrueNAS 12.0-U6 with UEFI on an Asrock Q1900-ITX motherboard.

With CSM (Compatibility Support Module) disabled, the installer was booting fine from the USB stick, I installed with UEFI boot, but then TrueNAS would not boot.
The problem was that the installer does not seem to create a EFI boot entry.

So first I created a bootable USB stick to access the EFI shell using this link:
https://kc.mcafee.com/corporate/index?page=content&id=KB90801&locale=en_US

Then I booted from the USB stick and it started TrueNAS.

After from TrueNAS shell I used efibootmgr to create the boot entry:

Code:
mount -t msdosfs /dev/ada0p1 /mnt
efibootmgr -c -l /mnt/efi/boot/BOOTx64.efi -L TrueNAS
efibootmgr -a 0000
efibootmgr -n 0000


Then I unplugged the USB stick and rebooted and it worked!
 

jcassette

Cadet
Joined
Nov 18, 2021
Messages
6
Here is the full log:
Code:
root@truenas[~]# mount -t msdosfs /dev/ada0p1 /mnt
root@truenas[~]# efibootmgr
BootCurrent: 0001
Timeout    : 1 seconds
BootOrder  : 0001, 0002
+Boot0001* UEFI: Generic Flash Disk 8.07
 Boot0002* UEFI: Generic Flash Disk 8.07
root@truenas[~]# efibootmgr -c -l /mnt/efi/boot/BOOTx64.efi -L TrueNAS
BootCurrent: 0001
Timeout    : 1 seconds
BootOrder  : 0000, 0001, 0002
 Boot0000  TrueNAS
+Boot0001* UEFI: Generic Flash Disk 8.07
 Boot0002* UEFI: Generic Flash Disk 8.07
root@truenas[~]# efibootmgr -a 0000
BootCurrent: 0001
Timeout    : 1 seconds
BootOrder  : 0000, 0001, 0002
 Boot0000* TrueNAS
+Boot0001* UEFI: Generic Flash Disk 8.07
 Boot0002* UEFI: Generic Flash Disk 8.07
root@truenas[~]# efibootmgr -n 0000
BootNext : 0000
BootCurrent: 0001
Timeout    : 1 seconds
BootOrder  : 0000, 0001, 0002
 Boot0000* TrueNAS
+Boot0001* UEFI: Generic Flash Disk 8.07
 Boot0002* UEFI: Generic Flash Disk 8.07
 

jcassette

Cadet
Joined
Nov 18, 2021
Messages
6
you saved my day, thanks!
You're welcome ! :smile:

I reinstalled TrueNAS today and it is possible to do the fix right after the install using the installer shell:
Code:
# mount -t tmpfs tmpfs /mnt/
# mkdir /mnt/efi
# mkdir /mnt/root
# mount -t msdos /dev/ada2p1 /mnt/efi/
# mount -t zfs boot-pool/ROOT/default /mnt/root/
# /mnt/root/usr/sbin/efibootmgr -c -l /mnt/efi/efi/boot/BOOTx64.efi -L TrueNAS
Boot to FW : false
BootCurrent: 0004
Timeout    : 1 seconds
BootOrder  : 0000
 Boot0000  TrueNAS
# /mnt/root/usr/sbin/efibootmgr -a -b 0000
Boot to FW : false
BootCurrent: 0004
Timeout    : 1 seconds
BootOrder  : 0000
 Boot0000* TrueNAS
# reboot
 
Top