From owner-freebsd-current@FreeBSD.ORG Mon Apr 6 07:57:34 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 78B8D1065673; Mon, 6 Apr 2009 07:57:34 +0000 (UTC) (envelope-from matheusber@gmail.com) Received: from yw-out-2324.google.com (yw-out-2324.google.com [74.125.46.29]) by mx1.freebsd.org (Postfix) with ESMTP id EFF888FC22; Mon, 6 Apr 2009 07:57:33 +0000 (UTC) (envelope-from matheusber@gmail.com) Received: by yw-out-2324.google.com with SMTP id 5so1272329ywh.13 for ; Mon, 06 Apr 2009 00:57:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:received:received :message-id:date:subject:from:to:cc:user-agent:mime-version :content-type:content-transfer-encoding:x-priority:importance; bh=gxcPNbf9TV5vE49lNhrNCQ7glwLdrhX0bRwgy+SKLb8=; b=sp26w6erI8ncWm7kaFh8PYd0Hsp46vkyNNTXudZF0f8dw80lEMZ0vc1p7bXRD55MNW Ao2savWtc17G5O82imD0+ISJYfqCTqq1e3+y3x3jp7e0ddb7S3kUwF97gYnM9KaG/uWb JapmLXX8P4iRuhizGKmBAbUy1leqsMBKCKYWI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:message-id:date:subject:from:to:cc:user-agent:mime-version :content-type:content-transfer-encoding:x-priority:importance; b=QPgHY1Owym5j5pj8Fk99+RO4pQg0eTEW6JzL8eSRyAoMsUyq+HKPAB8D9L4E47N5U2 nBjO7y8+K62INJ/l1tMAfhGobRZXKRBFDx1mMkQw24u5tX/DPQ/53DNXRA8JD3BcSEX6 sEugLmasldQrVpHkGMMGSTt/25oxPEhi5Q898= Received: by 10.101.69.6 with SMTP id w6mr3298482ank.22.1239004653421; Mon, 06 Apr 2009 00:57:33 -0700 (PDT) Received: from cygnus.homeunix.com ([189.71.74.155]) by mx.google.com with ESMTPS id 7sm8147981ywo.57.2009.04.06.00.57.31 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 06 Apr 2009 00:57:32 -0700 (PDT) Sender: Nenhum_de_Nos Received: by cygnus.homeunix.com (Postfix, from userid 80) id 4CF39B8074; Sun, 5 Apr 2009 15:54:35 -0300 (BRT) Received: from 10.1.1.80 (SquirrelMail authenticated user matheus) by 10.1.1.10 with HTTP; Sun, 5 Apr 2009 15:54:35 -0300 (BRT) Message-ID: Date: Sun, 5 Apr 2009 15:54:35 -0300 (BRT) From: "Nenhum_de_Nos" To: "Andrew Thompson" User-Agent: SquirrelMail/1.4.15 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal Cc: freebsd-current@freebsd.org, Robert Noland 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, 06 Apr 2009 07:57:34 -0000 On Mon, March 30, 2009 03:10, 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: >> > On Mon, March 23, 2009 07:36, Robert Noland wrote: >> > > So I have my i386 install on a usb hard disk, which I can only boot >> on >> > > one machine now. The one machine that I can make work has a bios >> option >> > > that reads "BIOS ehci handoff". This used to work with the old usb stack. The machines that it doesn't work on, boot the kernel, but >> fail >> > > to mount root, giving me the forbidding mountroot> prompt, which is immediately followed by the message saying that da0 is attached. >> da0 is >> > > however not listed in the available boot devices list. I tried >> playing >> > > around with the timeout in vfs_mount.c, but that didn't seem to have >> any >> > > impact. It has been suggested that this may be a "geom" timeout, >> but I >> > > don't know anything about the boot system really. >> > >> > 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 mount >> root >> > you said, and da0 not being alive soon enough to mount root. list >> 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 current. (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=10000 >> in /boot/loader.conf > > The following patch should work. It creates interleaving root hold tokens from the CAM probe to disk_create and geom providor tasting. I had to add a malloc type flag as sleeping isnt allowed at the point I added the token alloc in CAM. > > http://people.freebsd.org/~thompsa/root_wait.diff > > It needs review by the various geom/cam ppls. > > > Andrew phoenix# patch < ../root_wait.diff Hmm... Looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: kern/vfs_mount.c |=================================================================== |--- kern/vfs_mount.c (revision 190540) |+++ kern/vfs_mount.c (working copy) -------------------------- Patching file kern/vfs_mount.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 1353. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: cam/cam_xpt.c |=================================================================== |--- cam/cam_xpt.c (revision 190540) |+++ cam/cam_xpt.c (working copy) -------------------------- Patching file cam/cam_xpt.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 5139. Hunk #2 succeeded at 5201. Hunk #3 succeeded at 5232. Hunk #4 succeeded at 5240. Hunk #5 succeeded at 5353. Hunk #6 succeeded at 5372. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: dev/pccbb/pccbb_pci.c |=================================================================== |--- dev/pccbb/pccbb_pci.c (revision 190540) |+++ dev/pccbb/pccbb_pci.c (working copy) -------------------------- Patching file dev/pccbb/pccbb_pci.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 439. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: dev/usb/controller/usb_controller.c |=================================================================== |--- dev/usb/controller/usb_controller.c (revision 190540) |+++ dev/usb/controller/usb_controller.c (working copy) -------------------------- Patching file dev/usb/controller/usb_controller.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 115. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: geom/mirror/g_mirror.c |=================================================================== |--- geom/mirror/g_mirror.c (revision 190540) |+++ geom/mirror/g_mirror.c (working copy) -------------------------- Patching file geom/mirror/g_mirror.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 2907. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: geom/geom_disk.c |=================================================================== |--- geom/geom_disk.c (revision 190540) |+++ geom/geom_disk.c (working copy) -------------------------- Patching file geom/geom_disk.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 381. Hunk #2 succeeded at 467. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: geom/geom_disk.h |=================================================================== |--- geom/geom_disk.h (revision 190540) |+++ geom/geom_disk.h (working copy) -------------------------- Patching file geom/geom_disk.h using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 88. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: geom/raid3/g_raid3.c |=================================================================== |--- geom/raid3/g_raid3.c (revision 190540) |+++ geom/raid3/g_raid3.c (working copy) -------------------------- Patching file geom/raid3/g_raid3.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 3193. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: geom/geom_subr.c |=================================================================== |--- geom/geom_subr.c (revision 190540) |+++ geom/geom_subr.c (working copy) -------------------------- Patching file geom/geom_subr.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 545. Hunk #2 succeeded at 581. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: geom/part/g_part.c |=================================================================== |--- geom/part/g_part.c (revision 190540) |+++ geom/part/g_part.c (working copy) -------------------------- Patching file geom/part/g_part.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 1474. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: geom/journal/g_journal.c |=================================================================== |--- geom/journal/g_journal.c (revision 190540) |+++ geom/journal/g_journal.c (working copy) -------------------------- Patching file geom/journal/g_journal.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 2310. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: geom/geom.h |=================================================================== |--- geom/geom.h (revision 190540) |+++ geom/geom.h (working copy) -------------------------- Patching file geom/geom.h using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 193. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c |=================================================================== |--- cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c (revision 190540) |+++ cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c (working copy) -------------------------- Patching file cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 3087. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |Index: sys/systm.h |=================================================================== |--- sys/systm.h (revision 190540) |+++ sys/systm.h (working copy) -------------------------- Patching file sys/systm.h using Plan A... Reversed (or previously applied) patch detected! Assume -R? [y] Hunk #1 succeeded at 325. done phoenix# done. and then I got to boot. (thanks, three months to get here !) but then more info. I can't boot from usb in here, this itx has a small 32MB flash in ide I use to boot from. I put there /boot and some files from kernel (32MB is can't keep all files). now it can't boot by itself, it fails when mounting root, but da0s1a is there and simple: ufs:da0s1a does the job. dmesg attached. I'll try to find out how to make it boot by itself now :) thanks to all :D matheus phoenix# dmesg Copyright (c) 1992-2009 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD is a registered trademark of The FreeBSD Foundation. FreeBSD 8.0-CURRENT #0: Sun Apr 5 02:39:15 BRT 2009 root@phoenix.apartnet:/usr/obj/usr/src/sys/Phoenix8 Timecounter "i8254" frequency 1193182 Hz quality 0 CPU: Transmeta(tm) Crusoe(tm) Processor TM5700 (798.13-MHz 586-class CPU) Origin = "GenuineTMx86" Id = 0x543 Stepping = 3 Features=0x84893f real memory = 270532608 (258 MB) avail memory = 231632896 (220 MB) kbd1 at kbdmux0 pcib0: pcibus 0 on motherboard pir0: on motherboard pci0: on pcib0 pci0: at device 0.1 (no driver attached) pci0: at device 0.2 (no driver attached) pci0: at device 0.3 (no driver attached) uhci0: port 0xe000-0xe01f irq 15 at device 9.0 on pci0 uhci0: [ITHREAD] uhci0: LegSup = 0x201a usbus0: on uhci0 uhci1: port 0xe100-0xe11f irq 5 at device 9.1 on pci0 uhci1: [ITHREAD] uhci1: LegSup = 0x2010 usbus1: on uhci1 ehci0: mem 0xe8131000-0xe81310ff irq 10 at device 9.2 on pci0 ehci0: [ITHREAD] usbus2: EHCI version 1.0 usbus2: on ehci0 vgapci0: port 0xe200-0xe2ff mem 0xe0000000-0xe7ffffff,0xe8120000-0xe812ffff irq 11 at device 13.0 on pci0 isab0: at device 17.0 on pci0 isa0: on isab0 atapci0: port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0xe300-0xe30f at device 17.1 on pci0 ata0: on atapci0 ata0: [ITHREAD] ata1: on atapci0 ata1: [ITHREAD] pci0: at device 17.4 (no driver attached) vr0: port 0xe600-0xe6ff mem 0xe8130000-0xe81300ff irq 15 at device 18.0 on pci0 vr0: Quirks: 0x0 vr0: Revision: 0x51 miibus0: on vr0 ukphy0: PHY 1 on miibus0 ukphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto vr0: Ethernet address: 00:11:85:e3:2a:17 vr0: [ITHREAD] cpu0 on motherboard pmtimer0 on isa0 atrtc0: at port 0x70-0x71 irq 8 pnpid PNP0b00 on isa0 atkbdc0: at port 0x60,0x64 irq 1 pnpid PNP0303 on isa0 atkbd0: irq 1 on atkbdc0 kbd0 at atkbd0 atkbd0: [GIANT-LOCKED] atkbd0: [ITHREAD] unknown: can't assign resources (memory) orm0: at iomem 0xc0000-0xc8fff,0xcc000-0xd5fff pnpid ORM0000 on isa0 sc0: at flags 0x100 on isa0 sc0: VGA <16 virtual consoles, flags=0x300> vga0: at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0 ppc0: parallel port not found. unknown: can't assign resources (memory) Timecounter "TSC" frequency 798130362 Hz quality 800 Timecounters tick every 1.000 msec usbus0: 12Mbps Full Speed USB v1.0 usbus1: 12Mbps Full Speed USB v1.0 usbus2: 480Mbps High Speed USB v2.0 ugen0.1: at usbus0 uhub0: on usbus0 ugen1.1: at usbus1 uhub1: on usbus1 ugen2.1: at usbus2 uhub2: on usbus2 ad0: 30MB <32MB ATA Flash Disk ADBA217H> at ata0-master PIO4 GEOM_LABEL: Label for provider ad0 is ufsid/49adccdba5f8e304. GEOM_LABEL: Label for provider ad0 is ufs/flash. GEOM_LABEL: Label for provider ad0s1 is ufsid/49adce490693435d. uhub0: 2 ports with 2 removable, self powered Root mount waiting for: usbus2 usbus1 uhub1: 2 ports with 2 removable, self powered Root mount waiting for: usbus2 uhub2: 4 ports with 4 removable, self powered Root mount waiting for: usbus2 ugen2.2: at usbus2 umass0: on usbus2 umass0: SCSI over Bulk-Only; quirks = 0x408c Root mount waiting for: usbus2 umass0:0:0:-1: Attached to scbus0 da0 at umass-sim0 bus 0 target 0 lun 0 da0: Fixed Direct Access SCSI-0 device da0: 40.000MB/s transfers da0: 6149MB (12594960 512 byte sectors: 255H 63S/T 784C) GEOM_LABEL: Label for provider da0s1a is ufsid/49d77edb683149d9. GEOM_LABEL: Label for provider da0s1d is ufsid/49d77eddb6efc899. GEOM_LABEL: Label for provider da0s1e is ufsid/49d77edcee1ceb99. GEOM_LABEL: Label for provider da0s1f is ufsid/49d77edc7a6dba2b. Root mount waiting for: usbus2 ugen2.3: at usbus2 umass1: on usbus2 umass1: 8070i (ATAPI) over Bulk-Only; quirks = 0x008c Root mount waiting for: usbus2 umass1:1:1:-1: Attached to scbus1 (probe0:umass-sim1:1:0:0): TEST UNIT READY. CDB: 0 0 0 0 0 0 (probe0:umass-sim1:1:0:0): CAM Status: SCSI Status Error (probe0:umass-sim1:1:0:0): SCSI Status: Check Condition (probe0:umass-sim1:1:0:0): NOT READY asc:3a,0 (probe0:umass-sim1:1:0:0): Medium not present (probe0:umass-sim1:1:0:0): Unretryable error Manual root filesystem specification: : Mount using cd0 at umass-sim1 bus 1 target 0 lun 0 cd0: Removable CD-ROM SCSI-0 device cd0: 40.000MB/s transfers cd0: Attempt to query device size failed: NOT READY, Medium not present filesystem eg. ufs:da0s1a ? List valid disk boot devices Abort manual input mountroot> ufs:da0s1a Trying to mount root from ufs:da0s1a GEOM_LABEL: Label ufsid/49d77edb683149d9 removed. GEOM_LABEL: Label for provider da0s1a is ufsid/49d77edb683149d9. GEOM_LABEL: Label ufsid/49d77edcee1ceb99 removed. GEOM_LABEL: Label for provider da0s1e is ufsid/49d77edcee1ceb99. GEOM_LABEL: Label ufsid/49d77edc7a6dba2b removed. GEOM_LABEL: Label for provider da0s1f is ufsid/49d77edc7a6dba2b. GEOM_LABEL: Label ufsid/49d77eddb6efc899 removed. GEOM_LABEL: Label for provider da0s1d is ufsid/49d77eddb6efc899. GEOM_LABEL: Label ufsid/49d77edb683149d9 removed. GEOM_LABEL: Label ufsid/49d77edcee1ceb99 removed. GEOM_LABEL: Label ufsid/49d77edc7a6dba2b removed. GEOM_LABEL: Label ufsid/49d77eddb6efc899 removed. -- We will call you cygnus, The God of balance you shall be