Bootloader on USB, FreeNAS on SSD

kabegtr

Cadet
Joined
Jul 20, 2020
Messages
6
The config looks correct to me. But I suspect UEFI is in the mix if your GRUB USB drive can boot WIndows10 as AFAIK a BIOS-mode GRUB cannot boot an EFI-mode boot loader. Surely your microserver needs a BIOS-mode GRUB as I said above. If youl'e got a linux install why aren't you using that to create the USB boot drive you need? It should be straigh forward to do.

I spent 3h looking at tutorials for linux and still didn't manage to do it... If anyone has a normal solution that is tested and i can use it i'll be glad to try it out. :S
 

KrisBee

Wizard
Joined
Mar 20, 2017
Messages
1,288
Tutorials? You mean this sort of thing: https://github.com/ndeineko/grub2-bios-uefi-usb

Hopefully you can pick your way through that leaving out the EFi stuff. Keep it simple, you want a USB stick created with an MBR and single partition ext2 marked as bootable on which you install GRUB and then manually create the correct grub.cfg.

You can either prepare the USB stick from the CLI with fdisk or use the gui app "gparted" on your linux desktop. That ref shows the correct command to install grub on your USB stick in legacy BIOS boot and then create and edit the grub.cfg file under /boot/gurb
 
Last edited:

kabegtr

Cadet
Joined
Jul 20, 2020
Messages
6
Tutorials? You mean this sort of thing: https://github.com/ndeineko/grub2-bios-uefi-usb

Hopefully you can pick your way through that leaving out the EFi stuff. Keep it simple, you want a USB stick created with an MBR and single partition ext2 marked as bootable on which you install GRUB and then manually create the correct grub.cfg.

You can either prepare the USB stick from the CLI with fdisk or use the gui app "gparted" on your linux desktop. That ref shows the correct command to install grub on your USB stick in legacy BIOS boot and then create and edit the grub.cfg file under /boot/gurb

Let me thank you for helping me out first.
I spent the whole day to try things out. I made a legacy BIOS boot drive, same message, i made it with linux, with windows installed in legacy and it didn't work, same prompt. So i think the myth is busted and its not the USB.

I'm thinking about reinstalling FreeNAS on UEFI mode, i don't know if that's gonna do something. I really want to make it work...
 

danb35

Hall of Famer
Joined
Aug 16, 2011
Messages
15,466
...and the wheel turns. I recently bought a Microserver Gen8 to use as a TrueNAS box for my parents, intending to install TrueNAS to, and boot from, a USB SSD. Little did I realize at the time how picky it would be about its boot devices. After posting a new thread on the question, I was sent back here, and this has worked for me.

I ended up installing Grub on a micro SD card, since the Gen8 has an internal socket for such. I installed it there under Ubuntu, generally following the instructions at https://github.com/ndeineko/grub2-bios-uefi-usb, using the grub.cfg @Bytesplit posted four years ago (updating it to say TrueNAS CORE 12), and adding to it the following two lines:
Code:
set default="0"
set timeout=5

Now it will auto-boot into TrueNAS after a five-second delay, to allow some time to interrupt and make changes if needed (and if I can figure out how).

Edit: But, like others up-thread, I'm wondering about how to make Grub recognize the right drive, even if I add drives to the system (right now I only have two spinners in there). The discussion up-thread indicates that there isn't really a way to tell it something like, "use the highest of hd{1..5}" (which would, I think, be the simplest way to do the job), but the Grub docs suggest I should be able to do something like search --no-floppy --set=root --fs-uuid 83bd6b9d-7f41-11dc-be0b-001560b84f0f (though all the examples I see use Linux UUIDs, which are only eight characters long) or search --no-floppy --set=root --label truenas-boot, but neither of these is working for me--Grub can't find the device. In the first case, I'm using the GPTID of partition 1 of the boot SSD; in the second case I've tried giving that partition a label using both gpart and glabel. Grub isn't seeing it with any of these. Somewhat disappointing.
 
Last edited:
Top