From owner-freebsd-current@FreeBSD.ORG Mon Mar 30 18:37:54 2009 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 82F181065686; Mon, 30 Mar 2009 18:37:54 +0000 (UTC) (envelope-from rnoland@FreeBSD.org) Received: from gizmo.2hip.net (gizmo.2hip.net [64.74.207.195]) by mx1.freebsd.org (Postfix) with ESMTP id 4F3368FC12; Mon, 30 Mar 2009 18:37:54 +0000 (UTC) (envelope-from rnoland@FreeBSD.org) Received: from [192.168.1.156] (adsl-157-58-177.bna.bellsouth.net [70.157.58.177]) (authenticated bits=0) by gizmo.2hip.net (8.14.3/8.14.3) with ESMTP id n2UIaVqT067978 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 30 Mar 2009 14:36:31 -0400 (EDT) (envelope-from rnoland@FreeBSD.org) From: Robert Noland To: "Paul B. Mahol" In-Reply-To: <3a142e750903301134i40328c88y1e150eb3859c009d@mail.gmail.com> References: <1237804575.1771.7.camel@balrog.2hip.net> <1237884572.1771.28.camel@balrog.2hip.net> <20090330061036.GA83528@citylink.fud.org.nz> <3a142e750903300804r75d6ef81kae69cdfdb618b719@mail.gmail.com> <20090330162553.GA44858@citylink.fud.org.nz> <3a142e750903301003o27369595gaee12b5f8232ac6@mail.gmail.com> <20090330171405.GB44858@citylink.fud.org.nz> <3a142e750903301134i40328c88y1e150eb3859c009d@mail.gmail.com> Content-Type: multipart/signed; micalg="pgp-sha1"; protocol="application/pgp-signature"; boundary="=-MaMPXF7l/lPsV90sDC77" Organization: FreeBSD Date: Mon, 30 Mar 2009 13:37:18 -0500 Message-Id: <1238438238.8491.349.camel@balrog.2hip.net> Mime-Version: 1.0 X-Mailer: Evolution 2.24.5 FreeBSD GNOME Team Port X-Spam-Status: No, score=-2.4 required=5.0 tests=AWL,BAYES_00,RCVD_IN_PBL, RDNS_DYNAMIC autolearn=no version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on gizmo.2hip.net Cc: freebsd-current@freebsd.org, Nenhum_de_Nos , Andrew Thompson Subject: Re: Booting from usb hard disk X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Mar 2009 18:37:57 -0000 --=-MaMPXF7l/lPsV90sDC77 Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On Mon, 2009-03-30 at 19:34 +0100, Paul B. Mahol wrote: > On 3/30/09, Andrew Thompson wrote: > > On Mon, Mar 30, 2009 at 06:03:33PM +0100, Paul B. Mahol wrote: > >> On 3/30/09, Andrew Thompson wrote: > >> > On Mon, Mar 30, 2009 at 04:04:17PM +0100, Paul B. Mahol wrote: > >> >> On 3/30/09, Andrew Thompson wrote: > >> >> > On Tue, Mar 24, 2009 at 03:49:32AM -0500, Robert Noland wrote: > >> >> >> On Mon, 2009-03-23 at 19:40 -0300, Nenhum_de_Nos wrote: > >> >> >> > > >> >> >> > I had problem a while ago with via mini itx hardware, that was > >> >> >> > quite > >> >> >> > close. If I try boot from usb (installed in usb hdd), I get to= the > >> >> >> > point > >> >> >> > of loader not finding my disk. > >> >> >> > > >> >> >> > I then used a small flash disk attached to the ata (44 pin ide= ) > >> >> >> > channel > >> >> >> > and formatted /boot in there. this way I get to the point of m= ount > >> >> >> > root > >> >> >> > you said, and da0 not being alive soon enough to mount root. l= ist > >> >> >> > disks > >> >> >> > also couldn't find da0 though. > >> >> >> > > >> >> >> > I tried current from that time, and no good. > >> >> >> > > >> >> >> > if this is solved, I'll be happy to try whatever patch to curr= ent. > >> >> >> > (as > >> >> >> > long as I can install it from another box/or its ata channel, = as > >> >> >> > it > >> >> >> > can't > >> >> >> > boot vanilla 7.1R) > >> >> >> > >> >> >> So, my solution was to set kern.cam.scsi_delay=3D10000 > >> >> >> in /boot/loader.conf > >> >> > > >> >> > The following patch should work. It creates interleaving root hol= d > >> >> > tokens from the CAM probe to disk_create and geom providor tastin= g. > >> >> > I had to add a malloc type flag as sleeping isnt allowed at the p= oint > >> >> > I > >> >> > added the token alloc in CAM. > >> >> > > >> >> > http://people.freebsd.org/~thompsa/root_wait.diff > >> >> > >> >> Hmm, this is supposed to fix issue when trying to boot from usb dis= k > >> >> with UP kernel? > >> > > >> > This is to address the issue where the usb disk hasnt been attached = by > >> > the time the root filesystem is mounted. ie, you are booting from us= b. > >> > > >> > If your problem is different then please say. > >> > >> On SMP booting from usb works (kern.cam.scsi_delay=3D2000), da0 will a= ppear > >> after user is asked to enter root mount point, and pressing ? will sho= w > >> ufs:da0s1a. On UP it doesnt work, ufs:da0s1a is not available. > >> I thought it may be related to scsi_delay but increasing it was not > >> solution. > > > > Well the patch should (hopefully) fix this and you will no longer need > > to set the scsi delay. Please test! :) >=20 > With 2000 it works for both UP & SMP but setting scsi_delay to 50000 caus= ed > text to scroll forever, waiting for CAM. >=20 > Could scsi_delay get removed? Well, the default value on HEAD is 5000, I just doubled that and it worked for me... robert. >=20 --=20 Robert Noland FreeBSD --=-MaMPXF7l/lPsV90sDC77 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.11 (FreeBSD) iEYEABECAAYFAknREV4ACgkQM4TrQ4qfROPuEACfYzQZ9bCeE8ZwcE9Y2hVDKDRI qMYAnRqPgyLWAtf6E39VeGw2kkMaAFf6 =gUvq -----END PGP SIGNATURE----- --=-MaMPXF7l/lPsV90sDC77--