# SuperMicro mainboard not recognizing OS installed on USB drive?



## gralmal (Apr 3, 2018)

I'm currently attempting to install FreeBSD onto a USB drive, using FreeBSD-11.1-RELEASE-amd64-memstick.img which was on a separate USB drive. I went through the installer, and selected the second USB drive and everything seemed to work. When I boot the system now though, it doesn't boot that drive.

When I go into bios, and edit the fixed boot order, I do see "USB Key:Sandisk", which is the USB I installed the OS on. When I remove the Sandisk USB, of course that goes away, and the boot order just says "USB Key" in it's place, so it seeing the USB drive, it just seems unable to boot from it.

When I plug in the Sandisk USB drive to my Windows 10 desktop, I see it has been partitioned into 3 volumes, a 1 MB volume, a 14 GB volume, and a 328 MB volume.

Can anyone offer any insight into what may be going wrong here? Thanks. The motherboard I am using is the SuperMicro X11SSH-F.


----------



## Phishfry (Apr 3, 2018)

Here is the problem:
You install from da0 onto da1. No problem

Now you eject your install medium and da1 is now da0. Doh.
So the only hardlink you need to fix is /etc/fstab

Here is the way I do it. Install like normal. At the end of the install it allows you to do any changes to the install.
Post install shell I think it is called.
So I use that and change /etc/fstab with `ee` so on reboot when I yank the installer all is good.

To fix you can boot up off the installer and go to LiveCD mode and mount the installation and modify /mnt/etc/fstab


----------



## diizzy (Apr 3, 2018)

I've seen a similar issue using FreeNAS however on a Fujitsu server.
I honestly don't recall the exact solution but I remember that I needed to play around with the USB3 (XHCI) detection. In short I think it boils down to that there's too little time for the USB stick to initialize however I might be wrong.


----------



## diizzy (Apr 3, 2018)

Phishfry 
It should still be picked up by BIOS even if your fstab entry is incorrect.


----------



## Phishfry (Apr 3, 2018)

I have always need to modify /etc/fstab on my usb installs. It will fall over at mountroot if not.

If you need extra boot time this is what I used on my usb stick.
/boot/loader.conf

```
kern.cam.boot_delay="10000"
```
Add more time as needed.


----------



## Bobi B. (Apr 3, 2018)

You're better off using labels -- GPT and/or UFS -- instead of device names. Use `gpart show -l` to list GPT labels, for example:

```
# gpart show -l
=>      40  83886000  da0  GPT  (40G)
        40      1024    1  boot  (512K)
      1064  73399256    2  root  (35G)
  73400320  10483712    3  swap  (5.0G)
  83884032      2008       - free -  (1.0M)
```
Use `gpart modify -i 2 -l root ada0` to assign a GPT label to 2nd partition on GPT device da0 via gpart(8).

For UFS give label when creating the filesystem with newfs(8): `newfs -L root da0p2`, or at a later time with tunefs(8): `tunefs -L root da0p2` (filesystem should be read-only or unmounted).

Then in /etc/fstab you write:

```
# Device        Mountpoint  FStype  Options Dump    Pass#
/dev/ufs/root   /           ufs     rw      1       1
```

You can include host name in partition names, as well: root => host01root.


----------



## diizzy (Apr 3, 2018)

Phishfry 
I think you misunderstood, it's during BIOS bootup not FreeBSD.


----------



## SirDice (Apr 3, 2018)

Make sure you selected the correct boot type; UEFI or CSM (traditional BIOS boot). It sounds like the stick is installed with a traditional boot and the machine is trying to UEFI boot (or vice versa).


----------



## gralmal (Apr 3, 2018)

In my bios I have both boot types listed, with the traditional (legacy? csm?) showing as the correct disk. Legacy is first, UEFI is second in the boot order. How do I install such that it will show up as UEFI?


----------



## gralmal (Apr 3, 2018)

On top of all this, I'm a little frustrated with how much time it takes for the keys I press to load the corresponding menus (f2 for setup, f11 for boot menu, etc)


----------



## SirDice (Apr 4, 2018)

gralmal said:


> I'm a little frustrated with how much time it takes for the keys I press to load the corresponding menus (f2 for setup, f11 for boot menu, etc)


That's typical for servers. If you have a server with some addition RAID or HBA cards it can take up to 5 minutes just to get past the POST and get the machine to actually boot.


----------



## gralmal (Apr 4, 2018)

SirDice said:


> That's typical for servers. If you have a server with some addition RAID or HBA cards it can take up to 5 minutes just to get past the POST and get the machine to actually boot.


Well I'm glad I have invested in these lian li backplanes / silverstone capacitor cables then so I can hotswap my drives


----------

