Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Jun 2018 18:20:43 +0200
From:      "Ronald Klop" <ronald-lists@klop.ws>
To:        freebsd-arm@freebsd.org, "Per olof Ljungmark" <peo@nethead.se>
Subject:   Re: Raspberry Pi 2B and SSD drive
Message-ID:  <op.zkrg0y0pkndu52@joepie>
In-Reply-To: <2f135d3f-8175-aecb-006f-424b876a5bce@nethead.se>
References:  <2f135d3f-8175-aecb-006f-424b876a5bce@nethead.se>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 17 Jun 2018 17:10:15 +0200, Per olof Ljungmark <peo@nethead.se>  
wrote:

> FBSD 11.2-RC1
>
> How can I make good use of a USB SSD drive connected to the Pi?
>
> For instance, can I start from the SD card and then hand over everything
> to the SSD drive? From googling it does look like it is possible.
>
> Thanks!
>
> ...
>
> Yes, but....
>
> The but being that it's still USB attached and won't be nearly as fast
> as you expect.
>
> ...
>
> Subscribed to the list now...
>
> I am not concerned about the performance, it is the wear.
>
> So, how do one load the OS from the SSD? I suppose I could boot the OS
> from the SD card and place most other filesystems on the SSD but would
> prefer to load the OS from the SSD drive.
>
> Have a feeling the mysterious /boot/msdos/config.txt is involved but I
> fail to locate any documentation, if there is one?


It depends on the stage you want the boot to switch to the SSD.

1. load kernel from SD, but rootfs from SSD.
You can set 'rootdev=/dev/da0s1' (device path to your FS on SSD) in  
/boot/loader.conf.
Than the kernel will be loaded from SD, but the root FS will come from the  
SSD.
This works best if you keep /boot as a separate FS on SD. (You can mount  
this FS on /boot in fstab.)

2. load kernel and rootfs from SSD.
If you want to load the kernel from SSD also. You can edit some variables  
in u-boot. Interrupt the boot in the u-boot stage. Type 'showenv', edit  
some stuff and 'saveenv' will make the changes permanent in  
/boot/msdos/uboot.env.

3. load u-boot from SSD?
Recent version of u-boot can also detect usb devices, so it might even be  
possible to boot without SD and only use SSD (So /boot/msdos is also on  
SSD). This is the theory. I did not try this.

NB: I'm not an expert in u-boot. I might have written some mistakes in  
this mail. Good luck and have fun.

Regards,
Ronald.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?op.zkrg0y0pkndu52>