From owner-freebsd-questions@FreeBSD.ORG Mon Feb 16 07:37:40 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9D9E3106564A for ; Mon, 16 Feb 2009 07:37:40 +0000 (UTC) (envelope-from LukeD@pobox.com) Received: from sasl.smtp.pobox.com (a-sasl-fastnet.sasl.smtp.pobox.com [207.106.133.19]) by mx1.freebsd.org (Postfix) with ESMTP id 6B9868FC1F for ; Mon, 16 Feb 2009 07:37:40 +0000 (UTC) (envelope-from LukeD@pobox.com) Received: from localhost.localdomain (unknown [127.0.0.1]) by a-sasl-fastnet.sasl.smtp.pobox.com (Postfix) with ESMTP id 9676C9ABD0 for ; Mon, 16 Feb 2009 02:37:38 -0500 (EST) Received: from lukas.is-a-geek.org (unknown [71.113.98.220]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by a-sasl-fastnet.sasl.smtp.pobox.com (Postfix) with ESMTPSA id E2E659ABCF for ; Mon, 16 Feb 2009 02:37:37 -0500 (EST) Date: Sun, 15 Feb 2009 23:37:34 -0800 (PST) From: Luke Dean X-X-Sender: lukas@border.lukas.is-a-geek.org To: freebsd-questions@freebsd.org In-Reply-To: Message-ID: References: User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Pobox-Relay-ID: AF8339A2-FBFC-11DD-8393-0433C92D7133-96347044!a-sasl-fastnet.pobox.com Subject: Re: "boot0cfg: read /dev/ad1: Input/output error" using nanobsd X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Luke Dean List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Feb 2009 07:37:41 -0000 > I'm running FreeBSD 7.0 on a soekris 4801 with an image built by nanobsd. > It's a small piece of headless hardware that boots from a compact flash drive > - no moving parts. > > I wanted to update the operating system to 7.1 and install some more packages > on it, so I built a new image with nanobsd and uploaded it to the second > partition using nanobsd's updatep2 tool. The new image mounts fine, but the > last line of updatep2, "boot0cfg -s 2 -v ${NANO_DRIVE}" fails with the > message I've quoted in the subject line. > > The machine boots fine, but I can't provoke any kind of response from > boot0cfg except for input/output errors. I'd like to make the machine start > booting from the second slice. > > Any ideas? More information... The number of heads that the "diskinfo" reports is different depending on whether the compact flash card is plugged into the soekris box or mounted in a USB card reader/writer. The usb reader/writer reports: da0 512 # sectorsize 2052513792 # mediasize in bytes (1.9G) 4008816 # mediasize in sectors 249 # Cylinders according to firmware. 255 # Heads according to firmware. 63 # Sectors according to firmware. The soekris box reports: ad1 512 # sectorsize 2052513792 # mediasize in bytes (1.9G) 4008816 # mediasize in sectors 3977 # Cylinders according to firmware. 16 # Heads according to firmware. 63 # Sectors according to firmware. This is the same compact flash card. I gave up on boot0cfg and booting from the second partition, so I took the compact flash card out of the soekris box, connected it to my workstation with a USB card reader, and wrote a whole new image to it. Even after doing this, boot0cfg still won't work. I noticed some new messages on the console when I tried "boot0cfg -v ad1": ata0: FAILURE - non aligned DMA transfer attempted ad1: setting up DMA failed boot0cfg: read /dev/ad1: Input/output error ad1 is attached to ata0, per dmesg: ad1: 1957MB at ata0-slave WDMA2 I think this means there is some kind of geometry problem here, but I don't know how to fix it. I'd like to find a solution to this, but it's not critical.