From owner-freebsd-arm@freebsd.org Mon Oct 1 16:36:27 2018 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2C973109E519 for ; Mon, 1 Oct 2018 16:36:27 +0000 (UTC) (envelope-from marklmi@yahoo.com) Received: from sonic310-22.consmr.mail.ne1.yahoo.com (sonic310-22.consmr.mail.ne1.yahoo.com [66.163.186.203]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B74DE80DD0 for ; Mon, 1 Oct 2018 16:36:26 +0000 (UTC) (envelope-from marklmi@yahoo.com) X-YMail-OSG: IbbmJDEVM1kNCuDR477ddnjkC_iGU9e3_SbsQg_e3DI7lJR_YxB3pfUcugsZIP2 HRW.EKEeAMCuwxQP6D5Nw63K_4XCZzpejbCS7qnErErGLCQwC7_ayKOTul2EgSoY_8RTGxxjiKxc xfwexx7H23Q5E0hOFtRUNbRlAUomYw4BUBMHfAooteAJuQn.osY0j9CtfSnGs0O2YQYZZrO_lvbR rVxyYk51.a5BoX.2Ik2MI5UOy1Uql3y4dW5xP3WtWs5VB5Y3aqPbTfnaHxCi_DnTDYPp5m0WCo_d x.NbLsMTGwrJ2NJKZt.bhgz1BXv9mZ8pu_r60ICehFDmbKUCQ43ujZQ6gHkxpT_zskmDk8HH5CnY rNqqwlJP2Cb_hhzlhFhVnq8qkq_GWFnPshqoAlLEmEm6Ra._LkcbQr.NCmyzPaKSr4nA4FM1xTT0 yFR_rhAvZXHq0qMdi0LKZIt8CwuRTqe_8MN2fBrfn04IcKoORPGXLuOtMP4kxEiAhlK.cY9oLK6i 2ounB5Fc1AawgfM9PmHritq04WX13ixaAya6Z9T1kw_HS0F1p_mw5x5eegH7Fgb8sIa3V9zgjmtF 9.jqkh3E0WxeAyCDowWe4ro81ZT7f.E1pJLBzVQaTRdbh6sg31sSzarw_J__x8Y2uDXF6BGkEn1w BXBtHN31Gj8CVcrn4656ZUHc9qjb7sCPZgpJ49kmT0RmTGI274Uaj67O2pkK5Vg5l6mGDEwo51hc lB30UASEAov4YMFiSZcYpZbLd_8X5_y8KyEaAwZTcVLZomFDOYdddALat8JONJ8v8gFKwvG1Hdq1 zunN0O_q39ukNW4omt2HObg90bOvHyNTRLiFqIzZLwssABaFOdxZFLLxKvY0Hjrj5kQ8XyMgXKVJ T0AdTi53Pptwif1ZgaaqVtAuGdnx2Uaj.9CF.hXNS3c4hE_wnVE7S5SbuXbZ8ZolXpYai28uTuw3 9PYFkIdjcyDjPweysRd6.zNhQp4AG2p0QzHxGfMPtSVET4IGsGki7izX9h9lI3O6_yVF99SeaY6Z 3Rx1By.nAA06W_k4- Received: from sonic.gate.mail.ne1.yahoo.com by sonic310.consmr.mail.ne1.yahoo.com with HTTP; Mon, 1 Oct 2018 16:36:20 +0000 Received: from c-76-115-7-162.hsd1.or.comcast.net (EHLO [192.168.1.101]) ([76.115.7.162]) by smtp403.mail.ne1.yahoo.com (Oath Hermes SMTP Server) with ESMTPA ID 8ddafcbb719b3cf857a25f11e43408fb; Mon, 01 Oct 2018 16:36:19 +0000 (UTC) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.1\)) Subject: Re: Booting the raspberry pi 2 from a usb hd From: Mark Millard In-Reply-To: Date: Mon, 1 Oct 2018 09:36:17 -0700 Cc: freebsd-arm@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: References: To: Victor X-Mailer: Apple Mail (2.3445.9.1) X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 01 Oct 2018 16:36:27 -0000 On 2018-Oct-1, at 3:56 AM, Victor wrote: > I'm using a pi 2 card with FreeBSD 11.2-STABLE on the required sd = card. It works like a charm but using it as a postgresql server with = many write operation on it, to be on the safe side, I would like to move = the operating system to an external hard-disk or ssd.=20 > I've been surfing the net to find if it is possible to boot my pi 2 = from an external hard-disk (or SSD) to no avail. > Could you please give me some hint, directions on this subject? The notes below are not rpi2 specific. I've done such on many systems, including an rpi2. One technique is that /etc/fstab on the microsd card media that has the kernel can redirect to another device for where to mount / . (I use one partition for all of world.) I also tend to have /boot/loader.conf copies that contain something like: kern.cam.boot_delay=3D10000 vfs.mountroot.timeout=3D10 to help make sure things are ready for the external storage device to be used. Additional notes: I tend to install a full world on the microsd card slot media with the kernel so that I can boot that if needed, absent the external drive. (This involves the boot prompting for where to boot from.) I tend to keep the extra world's configuration tracking nearly all of the external device's world configuration. That includes /boot/loader.conf . But my configurations are rather simple, with little changed from defaults. But this also means that I might not notice if more than the files /etc/fstab and /boot/loader.conf from the microsd card media are put to use. For /etc/fstab I tend to have comments that point to the microsd card media for quick editing for switching the world device: just switch which lines are commented vs. not. I also tend to install the kernel on the external media, even though it is not booted from. So I end up having 2 installs overall. I tend to use various forms of labels and paths that reference labels instead of directly using device names, path prefixes: /dev/ufs/ /dev/msdosfs/ /dev/gpt/ /dev/label/ =3D=3D=3D Mark Millard marklmi at yahoo.com ( dsl-only.net went away in early 2018-Mar)